All Downloads are FREE. Search and download functionalities are using the official Maven repository.

io.envoyproxy.envoy.api.v2.RouteDiscoveryServiceGrpc Maven / Gradle / Ivy

There is a newer version: 1.0.47
Show newest version
package io.envoyproxy.envoy.api.v2;

import static io.grpc.MethodDescriptor.generateFullMethodName;
import static io.grpc.stub.ClientCalls.asyncBidiStreamingCall;
import static io.grpc.stub.ClientCalls.asyncClientStreamingCall;
import static io.grpc.stub.ClientCalls.asyncServerStreamingCall;
import static io.grpc.stub.ClientCalls.asyncUnaryCall;
import static io.grpc.stub.ClientCalls.blockingServerStreamingCall;
import static io.grpc.stub.ClientCalls.blockingUnaryCall;
import static io.grpc.stub.ClientCalls.futureUnaryCall;
import static io.grpc.stub.ServerCalls.asyncBidiStreamingCall;
import static io.grpc.stub.ServerCalls.asyncClientStreamingCall;
import static io.grpc.stub.ServerCalls.asyncServerStreamingCall;
import static io.grpc.stub.ServerCalls.asyncUnaryCall;
import static io.grpc.stub.ServerCalls.asyncUnimplementedStreamingCall;
import static io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall;

/**
 * 
 * The resource_names field in DiscoveryRequest specifies a route configuration.
 * This allows an Envoy configuration with multiple HTTP listeners (and
 * associated HTTP connection manager filters) to use different route
 * configurations. Each listener will bind its HTTP connection manager filter to
 * a route table via this identifier.
 * 
*/ @javax.annotation.Generated( value = "by gRPC proto compiler (version 1.22.1)", comments = "Source: envoy/api/v2/rds.proto") public final class RouteDiscoveryServiceGrpc { private RouteDiscoveryServiceGrpc() {} public static final String SERVICE_NAME = "envoy.api.v2.RouteDiscoveryService"; // Static method descriptors that strictly reflect the proto. private static volatile io.grpc.MethodDescriptor getStreamRoutesMethod; @io.grpc.stub.annotations.RpcMethod( fullMethodName = SERVICE_NAME + '/' + "StreamRoutes", requestType = io.envoyproxy.envoy.api.v2.DiscoveryRequest.class, responseType = io.envoyproxy.envoy.api.v2.DiscoveryResponse.class, methodType = io.grpc.MethodDescriptor.MethodType.BIDI_STREAMING) public static io.grpc.MethodDescriptor getStreamRoutesMethod() { io.grpc.MethodDescriptor getStreamRoutesMethod; if ((getStreamRoutesMethod = RouteDiscoveryServiceGrpc.getStreamRoutesMethod) == null) { synchronized (RouteDiscoveryServiceGrpc.class) { if ((getStreamRoutesMethod = RouteDiscoveryServiceGrpc.getStreamRoutesMethod) == null) { RouteDiscoveryServiceGrpc.getStreamRoutesMethod = getStreamRoutesMethod = io.grpc.MethodDescriptor.newBuilder() .setType(io.grpc.MethodDescriptor.MethodType.BIDI_STREAMING) .setFullMethodName(generateFullMethodName( "envoy.api.v2.RouteDiscoveryService", "StreamRoutes")) .setSampledToLocalTracing(true) .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( io.envoyproxy.envoy.api.v2.DiscoveryRequest.getDefaultInstance())) .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( io.envoyproxy.envoy.api.v2.DiscoveryResponse.getDefaultInstance())) .setSchemaDescriptor(new RouteDiscoveryServiceMethodDescriptorSupplier("StreamRoutes")) .build(); } } } return getStreamRoutesMethod; } private static volatile io.grpc.MethodDescriptor getDeltaRoutesMethod; @io.grpc.stub.annotations.RpcMethod( fullMethodName = SERVICE_NAME + '/' + "DeltaRoutes", requestType = io.envoyproxy.envoy.api.v2.DeltaDiscoveryRequest.class, responseType = io.envoyproxy.envoy.api.v2.DeltaDiscoveryResponse.class, methodType = io.grpc.MethodDescriptor.MethodType.BIDI_STREAMING) public static io.grpc.MethodDescriptor getDeltaRoutesMethod() { io.grpc.MethodDescriptor getDeltaRoutesMethod; if ((getDeltaRoutesMethod = RouteDiscoveryServiceGrpc.getDeltaRoutesMethod) == null) { synchronized (RouteDiscoveryServiceGrpc.class) { if ((getDeltaRoutesMethod = RouteDiscoveryServiceGrpc.getDeltaRoutesMethod) == null) { RouteDiscoveryServiceGrpc.getDeltaRoutesMethod = getDeltaRoutesMethod = io.grpc.MethodDescriptor.newBuilder() .setType(io.grpc.MethodDescriptor.MethodType.BIDI_STREAMING) .setFullMethodName(generateFullMethodName( "envoy.api.v2.RouteDiscoveryService", "DeltaRoutes")) .setSampledToLocalTracing(true) .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( io.envoyproxy.envoy.api.v2.DeltaDiscoveryRequest.getDefaultInstance())) .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( io.envoyproxy.envoy.api.v2.DeltaDiscoveryResponse.getDefaultInstance())) .setSchemaDescriptor(new RouteDiscoveryServiceMethodDescriptorSupplier("DeltaRoutes")) .build(); } } } return getDeltaRoutesMethod; } private static volatile io.grpc.MethodDescriptor getFetchRoutesMethod; @io.grpc.stub.annotations.RpcMethod( fullMethodName = SERVICE_NAME + '/' + "FetchRoutes", requestType = io.envoyproxy.envoy.api.v2.DiscoveryRequest.class, responseType = io.envoyproxy.envoy.api.v2.DiscoveryResponse.class, methodType = io.grpc.MethodDescriptor.MethodType.UNARY) public static io.grpc.MethodDescriptor getFetchRoutesMethod() { io.grpc.MethodDescriptor getFetchRoutesMethod; if ((getFetchRoutesMethod = RouteDiscoveryServiceGrpc.getFetchRoutesMethod) == null) { synchronized (RouteDiscoveryServiceGrpc.class) { if ((getFetchRoutesMethod = RouteDiscoveryServiceGrpc.getFetchRoutesMethod) == null) { RouteDiscoveryServiceGrpc.getFetchRoutesMethod = getFetchRoutesMethod = io.grpc.MethodDescriptor.newBuilder() .setType(io.grpc.MethodDescriptor.MethodType.UNARY) .setFullMethodName(generateFullMethodName( "envoy.api.v2.RouteDiscoveryService", "FetchRoutes")) .setSampledToLocalTracing(true) .setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( io.envoyproxy.envoy.api.v2.DiscoveryRequest.getDefaultInstance())) .setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller( io.envoyproxy.envoy.api.v2.DiscoveryResponse.getDefaultInstance())) .setSchemaDescriptor(new RouteDiscoveryServiceMethodDescriptorSupplier("FetchRoutes")) .build(); } } } return getFetchRoutesMethod; } /** * Creates a new async stub that supports all call types for the service */ public static RouteDiscoveryServiceStub newStub(io.grpc.Channel channel) { return new RouteDiscoveryServiceStub(channel); } /** * Creates a new blocking-style stub that supports unary and streaming output calls on the service */ public static RouteDiscoveryServiceBlockingStub newBlockingStub( io.grpc.Channel channel) { return new RouteDiscoveryServiceBlockingStub(channel); } /** * Creates a new ListenableFuture-style stub that supports unary calls on the service */ public static RouteDiscoveryServiceFutureStub newFutureStub( io.grpc.Channel channel) { return new RouteDiscoveryServiceFutureStub(channel); } /** *
   * The resource_names field in DiscoveryRequest specifies a route configuration.
   * This allows an Envoy configuration with multiple HTTP listeners (and
   * associated HTTP connection manager filters) to use different route
   * configurations. Each listener will bind its HTTP connection manager filter to
   * a route table via this identifier.
   * 
*/ public static abstract class RouteDiscoveryServiceImplBase implements io.grpc.BindableService { /** */ public io.grpc.stub.StreamObserver streamRoutes( io.grpc.stub.StreamObserver responseObserver) { return asyncUnimplementedStreamingCall(getStreamRoutesMethod(), responseObserver); } /** */ public io.grpc.stub.StreamObserver deltaRoutes( io.grpc.stub.StreamObserver responseObserver) { return asyncUnimplementedStreamingCall(getDeltaRoutesMethod(), responseObserver); } /** */ public void fetchRoutes(io.envoyproxy.envoy.api.v2.DiscoveryRequest request, io.grpc.stub.StreamObserver responseObserver) { asyncUnimplementedUnaryCall(getFetchRoutesMethod(), responseObserver); } @java.lang.Override public final io.grpc.ServerServiceDefinition bindService() { return io.grpc.ServerServiceDefinition.builder(getServiceDescriptor()) .addMethod( getStreamRoutesMethod(), asyncBidiStreamingCall( new MethodHandlers< io.envoyproxy.envoy.api.v2.DiscoveryRequest, io.envoyproxy.envoy.api.v2.DiscoveryResponse>( this, METHODID_STREAM_ROUTES))) .addMethod( getDeltaRoutesMethod(), asyncBidiStreamingCall( new MethodHandlers< io.envoyproxy.envoy.api.v2.DeltaDiscoveryRequest, io.envoyproxy.envoy.api.v2.DeltaDiscoveryResponse>( this, METHODID_DELTA_ROUTES))) .addMethod( getFetchRoutesMethod(), asyncUnaryCall( new MethodHandlers< io.envoyproxy.envoy.api.v2.DiscoveryRequest, io.envoyproxy.envoy.api.v2.DiscoveryResponse>( this, METHODID_FETCH_ROUTES))) .build(); } } /** *
   * The resource_names field in DiscoveryRequest specifies a route configuration.
   * This allows an Envoy configuration with multiple HTTP listeners (and
   * associated HTTP connection manager filters) to use different route
   * configurations. Each listener will bind its HTTP connection manager filter to
   * a route table via this identifier.
   * 
*/ public static final class RouteDiscoveryServiceStub extends io.grpc.stub.AbstractStub { private RouteDiscoveryServiceStub(io.grpc.Channel channel) { super(channel); } private RouteDiscoveryServiceStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { super(channel, callOptions); } @java.lang.Override protected RouteDiscoveryServiceStub build(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { return new RouteDiscoveryServiceStub(channel, callOptions); } /** */ public io.grpc.stub.StreamObserver streamRoutes( io.grpc.stub.StreamObserver responseObserver) { return asyncBidiStreamingCall( getChannel().newCall(getStreamRoutesMethod(), getCallOptions()), responseObserver); } /** */ public io.grpc.stub.StreamObserver deltaRoutes( io.grpc.stub.StreamObserver responseObserver) { return asyncBidiStreamingCall( getChannel().newCall(getDeltaRoutesMethod(), getCallOptions()), responseObserver); } /** */ public void fetchRoutes(io.envoyproxy.envoy.api.v2.DiscoveryRequest request, io.grpc.stub.StreamObserver responseObserver) { asyncUnaryCall( getChannel().newCall(getFetchRoutesMethod(), getCallOptions()), request, responseObserver); } } /** *
   * The resource_names field in DiscoveryRequest specifies a route configuration.
   * This allows an Envoy configuration with multiple HTTP listeners (and
   * associated HTTP connection manager filters) to use different route
   * configurations. Each listener will bind its HTTP connection manager filter to
   * a route table via this identifier.
   * 
*/ public static final class RouteDiscoveryServiceBlockingStub extends io.grpc.stub.AbstractStub { private RouteDiscoveryServiceBlockingStub(io.grpc.Channel channel) { super(channel); } private RouteDiscoveryServiceBlockingStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { super(channel, callOptions); } @java.lang.Override protected RouteDiscoveryServiceBlockingStub build(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { return new RouteDiscoveryServiceBlockingStub(channel, callOptions); } /** */ public io.envoyproxy.envoy.api.v2.DiscoveryResponse fetchRoutes(io.envoyproxy.envoy.api.v2.DiscoveryRequest request) { return blockingUnaryCall( getChannel(), getFetchRoutesMethod(), getCallOptions(), request); } } /** *
   * The resource_names field in DiscoveryRequest specifies a route configuration.
   * This allows an Envoy configuration with multiple HTTP listeners (and
   * associated HTTP connection manager filters) to use different route
   * configurations. Each listener will bind its HTTP connection manager filter to
   * a route table via this identifier.
   * 
*/ public static final class RouteDiscoveryServiceFutureStub extends io.grpc.stub.AbstractStub { private RouteDiscoveryServiceFutureStub(io.grpc.Channel channel) { super(channel); } private RouteDiscoveryServiceFutureStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { super(channel, callOptions); } @java.lang.Override protected RouteDiscoveryServiceFutureStub build(io.grpc.Channel channel, io.grpc.CallOptions callOptions) { return new RouteDiscoveryServiceFutureStub(channel, callOptions); } /** */ public com.google.common.util.concurrent.ListenableFuture fetchRoutes( io.envoyproxy.envoy.api.v2.DiscoveryRequest request) { return futureUnaryCall( getChannel().newCall(getFetchRoutesMethod(), getCallOptions()), request); } } private static final int METHODID_FETCH_ROUTES = 0; private static final int METHODID_STREAM_ROUTES = 1; private static final int METHODID_DELTA_ROUTES = 2; private static final class MethodHandlers implements io.grpc.stub.ServerCalls.UnaryMethod, io.grpc.stub.ServerCalls.ServerStreamingMethod, io.grpc.stub.ServerCalls.ClientStreamingMethod, io.grpc.stub.ServerCalls.BidiStreamingMethod { private final RouteDiscoveryServiceImplBase serviceImpl; private final int methodId; MethodHandlers(RouteDiscoveryServiceImplBase serviceImpl, int methodId) { this.serviceImpl = serviceImpl; this.methodId = methodId; } @java.lang.Override @java.lang.SuppressWarnings("unchecked") public void invoke(Req request, io.grpc.stub.StreamObserver responseObserver) { switch (methodId) { case METHODID_FETCH_ROUTES: serviceImpl.fetchRoutes((io.envoyproxy.envoy.api.v2.DiscoveryRequest) request, (io.grpc.stub.StreamObserver) responseObserver); break; default: throw new AssertionError(); } } @java.lang.Override @java.lang.SuppressWarnings("unchecked") public io.grpc.stub.StreamObserver invoke( io.grpc.stub.StreamObserver responseObserver) { switch (methodId) { case METHODID_STREAM_ROUTES: return (io.grpc.stub.StreamObserver) serviceImpl.streamRoutes( (io.grpc.stub.StreamObserver) responseObserver); case METHODID_DELTA_ROUTES: return (io.grpc.stub.StreamObserver) serviceImpl.deltaRoutes( (io.grpc.stub.StreamObserver) responseObserver); default: throw new AssertionError(); } } } private static abstract class RouteDiscoveryServiceBaseDescriptorSupplier implements io.grpc.protobuf.ProtoFileDescriptorSupplier, io.grpc.protobuf.ProtoServiceDescriptorSupplier { RouteDiscoveryServiceBaseDescriptorSupplier() {} @java.lang.Override public com.google.protobuf.Descriptors.FileDescriptor getFileDescriptor() { return io.envoyproxy.envoy.api.v2.RdsProto.getDescriptor(); } @java.lang.Override public com.google.protobuf.Descriptors.ServiceDescriptor getServiceDescriptor() { return getFileDescriptor().findServiceByName("RouteDiscoveryService"); } } private static final class RouteDiscoveryServiceFileDescriptorSupplier extends RouteDiscoveryServiceBaseDescriptorSupplier { RouteDiscoveryServiceFileDescriptorSupplier() {} } private static final class RouteDiscoveryServiceMethodDescriptorSupplier extends RouteDiscoveryServiceBaseDescriptorSupplier implements io.grpc.protobuf.ProtoMethodDescriptorSupplier { private final String methodName; RouteDiscoveryServiceMethodDescriptorSupplier(String methodName) { this.methodName = methodName; } @java.lang.Override public com.google.protobuf.Descriptors.MethodDescriptor getMethodDescriptor() { return getServiceDescriptor().findMethodByName(methodName); } } private static volatile io.grpc.ServiceDescriptor serviceDescriptor; public static io.grpc.ServiceDescriptor getServiceDescriptor() { io.grpc.ServiceDescriptor result = serviceDescriptor; if (result == null) { synchronized (RouteDiscoveryServiceGrpc.class) { result = serviceDescriptor; if (result == null) { serviceDescriptor = result = io.grpc.ServiceDescriptor.newBuilder(SERVICE_NAME) .setSchemaDescriptor(new RouteDiscoveryServiceFileDescriptorSupplier()) .addMethod(getStreamRoutesMethod()) .addMethod(getDeltaRoutesMethod()) .addMethod(getFetchRoutesMethod()) .build(); } } } return result; } }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy