diff --git a/ni/measurementlink/discovery/v1/discovery_service.proto b/ni/measurementlink/discovery/v1/discovery_service.proto index 966538a..492e291 100644 --- a/ni/measurementlink/discovery/v1/discovery_service.proto +++ b/ni/measurementlink/discovery/v1/discovery_service.proto @@ -50,6 +50,11 @@ service DiscoveryService { // - FAILED_PRECONDITION: More than one service matching the resolve request was found rpc ResolveService(ResolveServiceRequest) returns (ServiceLocation); + // Similar to ResolveService, returns information for the service in addition to the location of the service. + // This is useful if you want to avoid the overhead of having to call EnumerateServices to get this information as part of + // resolution of the service. See ResolveService for additional documentation related to resolving the service. + rpc ResolveServiceWithInformation(ResolveServiceWithInformationRequest) returns (ResolveServiceWithInformationResponse); + // Enumerate all compute nodes that have registered themselves in the current session. // These compute nodes are targets available for execution of services. // A compute node can be used as an argument to the ResolveService method to @@ -160,6 +165,31 @@ message ResolveServiceRequest { string deployment_target = 3; } +message ResolveServiceWithInformationRequest { + // Required. This corresponds to the gRPC Full Name of the service and should match the information + // that was supplied in the RegisterServiceRequest message. + string provided_interface = 1; + + // Optional. The service "class" that should be matched. If the value of this field is not specified and there + // is more than one matching service registered, an error is returned. + string service_class = 2; + + // Optional. Indicates the deployment target from which the service should be resolved. + // The value of this field can be obtained from the results of the EnumerateComputeNodes method. + // If the value of this field is not specified, the service will be resolved from the + // local deployment target. If the service cannot be resolved from the specified deployment + // target, an error is returned. + string deployment_target = 3; +} + +message ResolveServiceWithInformationResponse { + // The canonical location information of the service. + ServiceLocation service_location = 1; + + // The description of the service. + ServiceDescriptor service_descriptor = 2; +} + // Represents a location capable resolving and running a service. message ComputeNodeDescriptor { // The resolvable name of the compute node.