Please wait. This can take some minutes ...
Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance.
Project price only 1 $
You can buy this project and download/modify it how often you want.
io.envoyproxy.envoy.service.cluster.v3.ClusterDiscoveryServiceGrpc Maven / Gradle / Ivy
package io.envoyproxy.envoy.service.cluster.v3;
import static io.grpc.MethodDescriptor.generateFullMethodName;
/**
*
* Return list of all clusters this proxy will load balance to.
*
*/
@javax.annotation.Generated(
value = "by gRPC proto compiler (version 1.48.1)",
comments = "Source: envoy/service/cluster/v3/cds.proto")
@io.grpc.stub.annotations.GrpcGenerated
public final class ClusterDiscoveryServiceGrpc {
private ClusterDiscoveryServiceGrpc() {}
public static final String SERVICE_NAME = "envoy.service.cluster.v3.ClusterDiscoveryService";
// Static method descriptors that strictly reflect the proto.
private static volatile io.grpc.MethodDescriptor getStreamClustersMethod;
@io.grpc.stub.annotations.RpcMethod(
fullMethodName = SERVICE_NAME + '/' + "StreamClusters",
requestType = io.envoyproxy.envoy.service.discovery.v3.DiscoveryRequest.class,
responseType = io.envoyproxy.envoy.service.discovery.v3.DiscoveryResponse.class,
methodType = io.grpc.MethodDescriptor.MethodType.BIDI_STREAMING)
public static io.grpc.MethodDescriptor getStreamClustersMethod() {
io.grpc.MethodDescriptor getStreamClustersMethod;
if ((getStreamClustersMethod = ClusterDiscoveryServiceGrpc.getStreamClustersMethod) == null) {
synchronized (ClusterDiscoveryServiceGrpc.class) {
if ((getStreamClustersMethod = ClusterDiscoveryServiceGrpc.getStreamClustersMethod) == null) {
ClusterDiscoveryServiceGrpc.getStreamClustersMethod = getStreamClustersMethod =
io.grpc.MethodDescriptor.newBuilder()
.setType(io.grpc.MethodDescriptor.MethodType.BIDI_STREAMING)
.setFullMethodName(generateFullMethodName(SERVICE_NAME, "StreamClusters"))
.setSampledToLocalTracing(true)
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
io.envoyproxy.envoy.service.discovery.v3.DiscoveryRequest.getDefaultInstance()))
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
io.envoyproxy.envoy.service.discovery.v3.DiscoveryResponse.getDefaultInstance()))
.setSchemaDescriptor(new ClusterDiscoveryServiceMethodDescriptorSupplier("StreamClusters"))
.build();
}
}
}
return getStreamClustersMethod;
}
private static volatile io.grpc.MethodDescriptor getDeltaClustersMethod;
@io.grpc.stub.annotations.RpcMethod(
fullMethodName = SERVICE_NAME + '/' + "DeltaClusters",
requestType = io.envoyproxy.envoy.service.discovery.v3.DeltaDiscoveryRequest.class,
responseType = io.envoyproxy.envoy.service.discovery.v3.DeltaDiscoveryResponse.class,
methodType = io.grpc.MethodDescriptor.MethodType.BIDI_STREAMING)
public static io.grpc.MethodDescriptor getDeltaClustersMethod() {
io.grpc.MethodDescriptor getDeltaClustersMethod;
if ((getDeltaClustersMethod = ClusterDiscoveryServiceGrpc.getDeltaClustersMethod) == null) {
synchronized (ClusterDiscoveryServiceGrpc.class) {
if ((getDeltaClustersMethod = ClusterDiscoveryServiceGrpc.getDeltaClustersMethod) == null) {
ClusterDiscoveryServiceGrpc.getDeltaClustersMethod = getDeltaClustersMethod =
io.grpc.MethodDescriptor.newBuilder()
.setType(io.grpc.MethodDescriptor.MethodType.BIDI_STREAMING)
.setFullMethodName(generateFullMethodName(SERVICE_NAME, "DeltaClusters"))
.setSampledToLocalTracing(true)
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
io.envoyproxy.envoy.service.discovery.v3.DeltaDiscoveryRequest.getDefaultInstance()))
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
io.envoyproxy.envoy.service.discovery.v3.DeltaDiscoveryResponse.getDefaultInstance()))
.setSchemaDescriptor(new ClusterDiscoveryServiceMethodDescriptorSupplier("DeltaClusters"))
.build();
}
}
}
return getDeltaClustersMethod;
}
private static volatile io.grpc.MethodDescriptor getFetchClustersMethod;
@io.grpc.stub.annotations.RpcMethod(
fullMethodName = SERVICE_NAME + '/' + "FetchClusters",
requestType = io.envoyproxy.envoy.service.discovery.v3.DiscoveryRequest.class,
responseType = io.envoyproxy.envoy.service.discovery.v3.DiscoveryResponse.class,
methodType = io.grpc.MethodDescriptor.MethodType.UNARY)
public static io.grpc.MethodDescriptor getFetchClustersMethod() {
io.grpc.MethodDescriptor getFetchClustersMethod;
if ((getFetchClustersMethod = ClusterDiscoveryServiceGrpc.getFetchClustersMethod) == null) {
synchronized (ClusterDiscoveryServiceGrpc.class) {
if ((getFetchClustersMethod = ClusterDiscoveryServiceGrpc.getFetchClustersMethod) == null) {
ClusterDiscoveryServiceGrpc.getFetchClustersMethod = getFetchClustersMethod =
io.grpc.MethodDescriptor.newBuilder()
.setType(io.grpc.MethodDescriptor.MethodType.UNARY)
.setFullMethodName(generateFullMethodName(SERVICE_NAME, "FetchClusters"))
.setSampledToLocalTracing(true)
.setRequestMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
io.envoyproxy.envoy.service.discovery.v3.DiscoveryRequest.getDefaultInstance()))
.setResponseMarshaller(io.grpc.protobuf.ProtoUtils.marshaller(
io.envoyproxy.envoy.service.discovery.v3.DiscoveryResponse.getDefaultInstance()))
.setSchemaDescriptor(new ClusterDiscoveryServiceMethodDescriptorSupplier("FetchClusters"))
.build();
}
}
}
return getFetchClustersMethod;
}
/**
* Creates a new async stub that supports all call types for the service
*/
public static ClusterDiscoveryServiceStub newStub(io.grpc.Channel channel) {
io.grpc.stub.AbstractStub.StubFactory factory =
new io.grpc.stub.AbstractStub.StubFactory() {
@java.lang.Override
public ClusterDiscoveryServiceStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new ClusterDiscoveryServiceStub(channel, callOptions);
}
};
return ClusterDiscoveryServiceStub.newStub(factory, channel);
}
/**
* Creates a new blocking-style stub that supports unary and streaming output calls on the service
*/
public static ClusterDiscoveryServiceBlockingStub newBlockingStub(
io.grpc.Channel channel) {
io.grpc.stub.AbstractStub.StubFactory factory =
new io.grpc.stub.AbstractStub.StubFactory() {
@java.lang.Override
public ClusterDiscoveryServiceBlockingStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new ClusterDiscoveryServiceBlockingStub(channel, callOptions);
}
};
return ClusterDiscoveryServiceBlockingStub.newStub(factory, channel);
}
/**
* Creates a new ListenableFuture-style stub that supports unary calls on the service
*/
public static ClusterDiscoveryServiceFutureStub newFutureStub(
io.grpc.Channel channel) {
io.grpc.stub.AbstractStub.StubFactory factory =
new io.grpc.stub.AbstractStub.StubFactory() {
@java.lang.Override
public ClusterDiscoveryServiceFutureStub newStub(io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new ClusterDiscoveryServiceFutureStub(channel, callOptions);
}
};
return ClusterDiscoveryServiceFutureStub.newStub(factory, channel);
}
/**
*
* Return list of all clusters this proxy will load balance to.
*
*/
public static abstract class ClusterDiscoveryServiceImplBase implements io.grpc.BindableService {
/**
*/
public io.grpc.stub.StreamObserver streamClusters(
io.grpc.stub.StreamObserver responseObserver) {
return io.grpc.stub.ServerCalls.asyncUnimplementedStreamingCall(getStreamClustersMethod(), responseObserver);
}
/**
*/
public io.grpc.stub.StreamObserver deltaClusters(
io.grpc.stub.StreamObserver responseObserver) {
return io.grpc.stub.ServerCalls.asyncUnimplementedStreamingCall(getDeltaClustersMethod(), responseObserver);
}
/**
*/
public void fetchClusters(io.envoyproxy.envoy.service.discovery.v3.DiscoveryRequest request,
io.grpc.stub.StreamObserver responseObserver) {
io.grpc.stub.ServerCalls.asyncUnimplementedUnaryCall(getFetchClustersMethod(), responseObserver);
}
@java.lang.Override public final io.grpc.ServerServiceDefinition bindService() {
return io.grpc.ServerServiceDefinition.builder(getServiceDescriptor())
.addMethod(
getStreamClustersMethod(),
io.grpc.stub.ServerCalls.asyncBidiStreamingCall(
new MethodHandlers<
io.envoyproxy.envoy.service.discovery.v3.DiscoveryRequest,
io.envoyproxy.envoy.service.discovery.v3.DiscoveryResponse>(
this, METHODID_STREAM_CLUSTERS)))
.addMethod(
getDeltaClustersMethod(),
io.grpc.stub.ServerCalls.asyncBidiStreamingCall(
new MethodHandlers<
io.envoyproxy.envoy.service.discovery.v3.DeltaDiscoveryRequest,
io.envoyproxy.envoy.service.discovery.v3.DeltaDiscoveryResponse>(
this, METHODID_DELTA_CLUSTERS)))
.addMethod(
getFetchClustersMethod(),
io.grpc.stub.ServerCalls.asyncUnaryCall(
new MethodHandlers<
io.envoyproxy.envoy.service.discovery.v3.DiscoveryRequest,
io.envoyproxy.envoy.service.discovery.v3.DiscoveryResponse>(
this, METHODID_FETCH_CLUSTERS)))
.build();
}
}
/**
*
* Return list of all clusters this proxy will load balance to.
*
*/
public static final class ClusterDiscoveryServiceStub extends io.grpc.stub.AbstractAsyncStub {
private ClusterDiscoveryServiceStub(
io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions);
}
@java.lang.Override
protected ClusterDiscoveryServiceStub build(
io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new ClusterDiscoveryServiceStub(channel, callOptions);
}
/**
*/
public io.grpc.stub.StreamObserver streamClusters(
io.grpc.stub.StreamObserver responseObserver) {
return io.grpc.stub.ClientCalls.asyncBidiStreamingCall(
getChannel().newCall(getStreamClustersMethod(), getCallOptions()), responseObserver);
}
/**
*/
public io.grpc.stub.StreamObserver deltaClusters(
io.grpc.stub.StreamObserver responseObserver) {
return io.grpc.stub.ClientCalls.asyncBidiStreamingCall(
getChannel().newCall(getDeltaClustersMethod(), getCallOptions()), responseObserver);
}
/**
*/
public void fetchClusters(io.envoyproxy.envoy.service.discovery.v3.DiscoveryRequest request,
io.grpc.stub.StreamObserver responseObserver) {
io.grpc.stub.ClientCalls.asyncUnaryCall(
getChannel().newCall(getFetchClustersMethod(), getCallOptions()), request, responseObserver);
}
}
/**
*
* Return list of all clusters this proxy will load balance to.
*
*/
public static final class ClusterDiscoveryServiceBlockingStub extends io.grpc.stub.AbstractBlockingStub {
private ClusterDiscoveryServiceBlockingStub(
io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions);
}
@java.lang.Override
protected ClusterDiscoveryServiceBlockingStub build(
io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new ClusterDiscoveryServiceBlockingStub(channel, callOptions);
}
/**
*/
public io.envoyproxy.envoy.service.discovery.v3.DiscoveryResponse fetchClusters(io.envoyproxy.envoy.service.discovery.v3.DiscoveryRequest request) {
return io.grpc.stub.ClientCalls.blockingUnaryCall(
getChannel(), getFetchClustersMethod(), getCallOptions(), request);
}
}
/**
*
* Return list of all clusters this proxy will load balance to.
*
*/
public static final class ClusterDiscoveryServiceFutureStub extends io.grpc.stub.AbstractFutureStub {
private ClusterDiscoveryServiceFutureStub(
io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
super(channel, callOptions);
}
@java.lang.Override
protected ClusterDiscoveryServiceFutureStub build(
io.grpc.Channel channel, io.grpc.CallOptions callOptions) {
return new ClusterDiscoveryServiceFutureStub(channel, callOptions);
}
/**
*/
public com.google.common.util.concurrent.ListenableFuture fetchClusters(
io.envoyproxy.envoy.service.discovery.v3.DiscoveryRequest request) {
return io.grpc.stub.ClientCalls.futureUnaryCall(
getChannel().newCall(getFetchClustersMethod(), getCallOptions()), request);
}
}
private static final int METHODID_FETCH_CLUSTERS = 0;
private static final int METHODID_STREAM_CLUSTERS = 1;
private static final int METHODID_DELTA_CLUSTERS = 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 ClusterDiscoveryServiceImplBase serviceImpl;
private final int methodId;
MethodHandlers(ClusterDiscoveryServiceImplBase 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_CLUSTERS:
serviceImpl.fetchClusters((io.envoyproxy.envoy.service.discovery.v3.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_CLUSTERS:
return (io.grpc.stub.StreamObserver) serviceImpl.streamClusters(
(io.grpc.stub.StreamObserver) responseObserver);
case METHODID_DELTA_CLUSTERS:
return (io.grpc.stub.StreamObserver) serviceImpl.deltaClusters(
(io.grpc.stub.StreamObserver) responseObserver);
default:
throw new AssertionError();
}
}
}
private static abstract class ClusterDiscoveryServiceBaseDescriptorSupplier
implements io.grpc.protobuf.ProtoFileDescriptorSupplier, io.grpc.protobuf.ProtoServiceDescriptorSupplier {
ClusterDiscoveryServiceBaseDescriptorSupplier() {}
@java.lang.Override
public com.google.protobuf.Descriptors.FileDescriptor getFileDescriptor() {
return io.envoyproxy.envoy.service.cluster.v3.CdsProto.getDescriptor();
}
@java.lang.Override
public com.google.protobuf.Descriptors.ServiceDescriptor getServiceDescriptor() {
return getFileDescriptor().findServiceByName("ClusterDiscoveryService");
}
}
private static final class ClusterDiscoveryServiceFileDescriptorSupplier
extends ClusterDiscoveryServiceBaseDescriptorSupplier {
ClusterDiscoveryServiceFileDescriptorSupplier() {}
}
private static final class ClusterDiscoveryServiceMethodDescriptorSupplier
extends ClusterDiscoveryServiceBaseDescriptorSupplier
implements io.grpc.protobuf.ProtoMethodDescriptorSupplier {
private final String methodName;
ClusterDiscoveryServiceMethodDescriptorSupplier(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 (ClusterDiscoveryServiceGrpc.class) {
result = serviceDescriptor;
if (result == null) {
serviceDescriptor = result = io.grpc.ServiceDescriptor.newBuilder(SERVICE_NAME)
.setSchemaDescriptor(new ClusterDiscoveryServiceFileDescriptorSupplier())
.addMethod(getStreamClustersMethod())
.addMethod(getDeltaClustersMethod())
.addMethod(getFetchClustersMethod())
.build();
}
}
}
return result;
}
}