Reference documentation and code samples for the Google Cloud Service Directory V1 Client class ResolveServiceRequest.
The request message for LookupService.ResolveService.
Looks up a service by its name, returns the service and its endpoints.
Generated from protobuf message google.cloud.servicedirectory.v1.ResolveServiceRequest
Namespace
Google \ Cloud \ ServiceDirectory \ V1Methods
__construct
Constructor.
Parameters | |
---|---|
Name | Description |
data |
array
Optional. Data for populating the Message object. |
↳ name |
string
Required. The name of the service to resolve. |
↳ max_endpoints |
int
Optional. The maximum number of endpoints to return. Defaults to 25. Maximum is 100. If a value less than one is specified, the Default is used. If a value greater than the Maximum is specified, the Maximum is used. |
↳ endpoint_filter |
string
Optional. The filter applied to the endpoints of the resolved service. General filter string syntax:
|
getName
Required. The name of the service to resolve.
Returns | |
---|---|
Type | Description |
string |
setName
Required. The name of the service to resolve.
Parameter | |
---|---|
Name | Description |
var |
string
|
Returns | |
---|---|
Type | Description |
$this |
getMaxEndpoints
Optional. The maximum number of endpoints to return. Defaults to 25.
Maximum is 100. If a value less than one is specified, the Default is used. If a value greater than the Maximum is specified, the Maximum is used.
Returns | |
---|---|
Type | Description |
int |
setMaxEndpoints
Optional. The maximum number of endpoints to return. Defaults to 25.
Maximum is 100. If a value less than one is specified, the Default is used. If a value greater than the Maximum is specified, the Maximum is used.
Parameter | |
---|---|
Name | Description |
var |
int
|
Returns | |
---|---|
Type | Description |
$this |
getEndpointFilter
Optional. The filter applied to the endpoints of the resolved service.
General filter string syntax:
- "metadata.owner" returns Endpoints that have a label with the key "owner", this is the same as "metadata:owner"
- "metadata.protocol=gRPC" returns Endpoints that have key/value "protocol=gRPC"
- "metadata.owner!=sd AND metadata.foo=bar" returns Endpoints that have "owner" field in metadata with a value that is not "sd" AND have the key/value foo=bar.
Returns | |
---|---|
Type | Description |
string |
setEndpointFilter
Optional. The filter applied to the endpoints of the resolved service.
General filter string syntax:
- "metadata.owner" returns Endpoints that have a label with the key "owner", this is the same as "metadata:owner"
- "metadata.protocol=gRPC" returns Endpoints that have key/value "protocol=gRPC"
- "metadata.owner!=sd AND metadata.foo=bar" returns Endpoints that have "owner" field in metadata with a value that is not "sd" AND have the key/value foo=bar.
Parameter | |
---|---|
Name | Description |
var |
string
|
Returns | |
---|---|
Type | Description |
$this |