mirror of https://github.com/grpc/grpc-java.git
Synchronize benchmarking protos with grpc/grpc
This commit is contained in:
parent
053a18e209
commit
de7ec3c682
|
|
@ -0,0 +1,222 @@
|
|||
package io.grpc.benchmarks.proto;
|
||||
|
||||
import static io.grpc.stub.ClientCalls.asyncUnaryCall;
|
||||
import static io.grpc.stub.ClientCalls.asyncServerStreamingCall;
|
||||
import static io.grpc.stub.ClientCalls.asyncClientStreamingCall;
|
||||
import static io.grpc.stub.ClientCalls.asyncBidiStreamingCall;
|
||||
import static io.grpc.stub.ClientCalls.blockingUnaryCall;
|
||||
import static io.grpc.stub.ClientCalls.blockingServerStreamingCall;
|
||||
import static io.grpc.stub.ClientCalls.futureUnaryCall;
|
||||
import static io.grpc.MethodDescriptor.generateFullMethodName;
|
||||
import static io.grpc.stub.ServerCalls.asyncUnaryCall;
|
||||
import static io.grpc.stub.ServerCalls.asyncServerStreamingCall;
|
||||
import static io.grpc.stub.ServerCalls.asyncClientStreamingCall;
|
||||
import static io.grpc.stub.ServerCalls.asyncBidiStreamingCall;
|
||||
|
||||
@javax.annotation.Generated(
|
||||
value = "by gRPC proto compiler",
|
||||
comments = "Source: services.proto")
|
||||
public class BenchmarkServiceGrpc {
|
||||
|
||||
private BenchmarkServiceGrpc() {}
|
||||
|
||||
public static final String SERVICE_NAME = "grpc.testing.BenchmarkService";
|
||||
|
||||
// Static method descriptors that strictly reflect the proto.
|
||||
@io.grpc.ExperimentalApi
|
||||
public static final io.grpc.MethodDescriptor<io.grpc.benchmarks.proto.Messages.SimpleRequest,
|
||||
io.grpc.benchmarks.proto.Messages.SimpleResponse> METHOD_UNARY_CALL =
|
||||
io.grpc.MethodDescriptor.create(
|
||||
io.grpc.MethodDescriptor.MethodType.UNARY,
|
||||
generateFullMethodName(
|
||||
"grpc.testing.BenchmarkService", "UnaryCall"),
|
||||
io.grpc.protobuf.ProtoUtils.marshaller(io.grpc.benchmarks.proto.Messages.SimpleRequest.getDefaultInstance()),
|
||||
io.grpc.protobuf.ProtoUtils.marshaller(io.grpc.benchmarks.proto.Messages.SimpleResponse.getDefaultInstance()));
|
||||
@io.grpc.ExperimentalApi
|
||||
public static final io.grpc.MethodDescriptor<io.grpc.benchmarks.proto.Messages.SimpleRequest,
|
||||
io.grpc.benchmarks.proto.Messages.SimpleResponse> METHOD_STREAMING_CALL =
|
||||
io.grpc.MethodDescriptor.create(
|
||||
io.grpc.MethodDescriptor.MethodType.BIDI_STREAMING,
|
||||
generateFullMethodName(
|
||||
"grpc.testing.BenchmarkService", "StreamingCall"),
|
||||
io.grpc.protobuf.ProtoUtils.marshaller(io.grpc.benchmarks.proto.Messages.SimpleRequest.getDefaultInstance()),
|
||||
io.grpc.protobuf.ProtoUtils.marshaller(io.grpc.benchmarks.proto.Messages.SimpleResponse.getDefaultInstance()));
|
||||
|
||||
public static BenchmarkServiceStub newStub(io.grpc.Channel channel) {
|
||||
return new BenchmarkServiceStub(channel);
|
||||
}
|
||||
|
||||
public static BenchmarkServiceBlockingStub newBlockingStub(
|
||||
io.grpc.Channel channel) {
|
||||
return new BenchmarkServiceBlockingStub(channel);
|
||||
}
|
||||
|
||||
public static BenchmarkServiceFutureStub newFutureStub(
|
||||
io.grpc.Channel channel) {
|
||||
return new BenchmarkServiceFutureStub(channel);
|
||||
}
|
||||
|
||||
public static interface BenchmarkService {
|
||||
|
||||
public void unaryCall(io.grpc.benchmarks.proto.Messages.SimpleRequest request,
|
||||
io.grpc.stub.StreamObserver<io.grpc.benchmarks.proto.Messages.SimpleResponse> responseObserver);
|
||||
|
||||
public io.grpc.stub.StreamObserver<io.grpc.benchmarks.proto.Messages.SimpleRequest> streamingCall(
|
||||
io.grpc.stub.StreamObserver<io.grpc.benchmarks.proto.Messages.SimpleResponse> responseObserver);
|
||||
}
|
||||
|
||||
public static interface BenchmarkServiceBlockingClient {
|
||||
|
||||
public io.grpc.benchmarks.proto.Messages.SimpleResponse unaryCall(io.grpc.benchmarks.proto.Messages.SimpleRequest request);
|
||||
}
|
||||
|
||||
public static interface BenchmarkServiceFutureClient {
|
||||
|
||||
public com.google.common.util.concurrent.ListenableFuture<io.grpc.benchmarks.proto.Messages.SimpleResponse> unaryCall(
|
||||
io.grpc.benchmarks.proto.Messages.SimpleRequest request);
|
||||
}
|
||||
|
||||
public static class BenchmarkServiceStub extends io.grpc.stub.AbstractStub<BenchmarkServiceStub>
|
||||
implements BenchmarkService {
|
||||
private BenchmarkServiceStub(io.grpc.Channel channel) {
|
||||
super(channel);
|
||||
}
|
||||
|
||||
private BenchmarkServiceStub(io.grpc.Channel channel,
|
||||
io.grpc.CallOptions callOptions) {
|
||||
super(channel, callOptions);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected BenchmarkServiceStub build(io.grpc.Channel channel,
|
||||
io.grpc.CallOptions callOptions) {
|
||||
return new BenchmarkServiceStub(channel, callOptions);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public void unaryCall(io.grpc.benchmarks.proto.Messages.SimpleRequest request,
|
||||
io.grpc.stub.StreamObserver<io.grpc.benchmarks.proto.Messages.SimpleResponse> responseObserver) {
|
||||
asyncUnaryCall(
|
||||
getChannel().newCall(METHOD_UNARY_CALL, getCallOptions()), request, responseObserver);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public io.grpc.stub.StreamObserver<io.grpc.benchmarks.proto.Messages.SimpleRequest> streamingCall(
|
||||
io.grpc.stub.StreamObserver<io.grpc.benchmarks.proto.Messages.SimpleResponse> responseObserver) {
|
||||
return asyncBidiStreamingCall(
|
||||
getChannel().newCall(METHOD_STREAMING_CALL, getCallOptions()), responseObserver);
|
||||
}
|
||||
}
|
||||
|
||||
public static class BenchmarkServiceBlockingStub extends io.grpc.stub.AbstractStub<BenchmarkServiceBlockingStub>
|
||||
implements BenchmarkServiceBlockingClient {
|
||||
private BenchmarkServiceBlockingStub(io.grpc.Channel channel) {
|
||||
super(channel);
|
||||
}
|
||||
|
||||
private BenchmarkServiceBlockingStub(io.grpc.Channel channel,
|
||||
io.grpc.CallOptions callOptions) {
|
||||
super(channel, callOptions);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected BenchmarkServiceBlockingStub build(io.grpc.Channel channel,
|
||||
io.grpc.CallOptions callOptions) {
|
||||
return new BenchmarkServiceBlockingStub(channel, callOptions);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public io.grpc.benchmarks.proto.Messages.SimpleResponse unaryCall(io.grpc.benchmarks.proto.Messages.SimpleRequest request) {
|
||||
return blockingUnaryCall(
|
||||
getChannel(), METHOD_UNARY_CALL, getCallOptions(), request);
|
||||
}
|
||||
}
|
||||
|
||||
public static class BenchmarkServiceFutureStub extends io.grpc.stub.AbstractStub<BenchmarkServiceFutureStub>
|
||||
implements BenchmarkServiceFutureClient {
|
||||
private BenchmarkServiceFutureStub(io.grpc.Channel channel) {
|
||||
super(channel);
|
||||
}
|
||||
|
||||
private BenchmarkServiceFutureStub(io.grpc.Channel channel,
|
||||
io.grpc.CallOptions callOptions) {
|
||||
super(channel, callOptions);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected BenchmarkServiceFutureStub build(io.grpc.Channel channel,
|
||||
io.grpc.CallOptions callOptions) {
|
||||
return new BenchmarkServiceFutureStub(channel, callOptions);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.common.util.concurrent.ListenableFuture<io.grpc.benchmarks.proto.Messages.SimpleResponse> unaryCall(
|
||||
io.grpc.benchmarks.proto.Messages.SimpleRequest request) {
|
||||
return futureUnaryCall(
|
||||
getChannel().newCall(METHOD_UNARY_CALL, getCallOptions()), request);
|
||||
}
|
||||
}
|
||||
|
||||
private static final int METHODID_UNARY_CALL = 0;
|
||||
private static final int METHODID_STREAMING_CALL = 1;
|
||||
|
||||
private static class MethodHandlers<Req, Resp> implements
|
||||
io.grpc.stub.ServerCalls.UnaryMethod<Req, Resp>,
|
||||
io.grpc.stub.ServerCalls.ServerStreamingMethod<Req, Resp>,
|
||||
io.grpc.stub.ServerCalls.ClientStreamingMethod<Req, Resp>,
|
||||
io.grpc.stub.ServerCalls.BidiStreamingMethod<Req, Resp> {
|
||||
private final BenchmarkService serviceImpl;
|
||||
private final int methodId;
|
||||
|
||||
public MethodHandlers(BenchmarkService 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<Resp> responseObserver) {
|
||||
switch (methodId) {
|
||||
case METHODID_UNARY_CALL:
|
||||
serviceImpl.unaryCall((io.grpc.benchmarks.proto.Messages.SimpleRequest) request,
|
||||
(io.grpc.stub.StreamObserver<io.grpc.benchmarks.proto.Messages.SimpleResponse>) responseObserver);
|
||||
break;
|
||||
default:
|
||||
throw new AssertionError();
|
||||
}
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
@java.lang.SuppressWarnings("unchecked")
|
||||
public io.grpc.stub.StreamObserver<Req> invoke(
|
||||
io.grpc.stub.StreamObserver<Resp> responseObserver) {
|
||||
switch (methodId) {
|
||||
case METHODID_STREAMING_CALL:
|
||||
return (io.grpc.stub.StreamObserver<Req>) serviceImpl.streamingCall(
|
||||
(io.grpc.stub.StreamObserver<io.grpc.benchmarks.proto.Messages.SimpleResponse>) responseObserver);
|
||||
default:
|
||||
throw new AssertionError();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public static io.grpc.ServerServiceDefinition bindService(
|
||||
final BenchmarkService serviceImpl) {
|
||||
return io.grpc.ServerServiceDefinition.builder(SERVICE_NAME)
|
||||
.addMethod(
|
||||
METHOD_UNARY_CALL,
|
||||
asyncUnaryCall(
|
||||
new MethodHandlers<
|
||||
io.grpc.benchmarks.proto.Messages.SimpleRequest,
|
||||
io.grpc.benchmarks.proto.Messages.SimpleResponse>(
|
||||
serviceImpl, METHODID_UNARY_CALL)))
|
||||
.addMethod(
|
||||
METHOD_STREAMING_CALL,
|
||||
asyncBidiStreamingCall(
|
||||
new MethodHandlers<
|
||||
io.grpc.benchmarks.proto.Messages.SimpleRequest,
|
||||
io.grpc.benchmarks.proto.Messages.SimpleResponse>(
|
||||
serviceImpl, METHODID_STREAMING_CALL)))
|
||||
.build();
|
||||
}
|
||||
}
|
||||
|
|
@ -0,0 +1,301 @@
|
|||
package io.grpc.benchmarks.proto;
|
||||
|
||||
import static io.grpc.stub.ClientCalls.asyncUnaryCall;
|
||||
import static io.grpc.stub.ClientCalls.asyncServerStreamingCall;
|
||||
import static io.grpc.stub.ClientCalls.asyncClientStreamingCall;
|
||||
import static io.grpc.stub.ClientCalls.asyncBidiStreamingCall;
|
||||
import static io.grpc.stub.ClientCalls.blockingUnaryCall;
|
||||
import static io.grpc.stub.ClientCalls.blockingServerStreamingCall;
|
||||
import static io.grpc.stub.ClientCalls.futureUnaryCall;
|
||||
import static io.grpc.MethodDescriptor.generateFullMethodName;
|
||||
import static io.grpc.stub.ServerCalls.asyncUnaryCall;
|
||||
import static io.grpc.stub.ServerCalls.asyncServerStreamingCall;
|
||||
import static io.grpc.stub.ServerCalls.asyncClientStreamingCall;
|
||||
import static io.grpc.stub.ServerCalls.asyncBidiStreamingCall;
|
||||
|
||||
@javax.annotation.Generated(
|
||||
value = "by gRPC proto compiler",
|
||||
comments = "Source: services.proto")
|
||||
public class WorkerServiceGrpc {
|
||||
|
||||
private WorkerServiceGrpc() {}
|
||||
|
||||
public static final String SERVICE_NAME = "grpc.testing.WorkerService";
|
||||
|
||||
// Static method descriptors that strictly reflect the proto.
|
||||
@io.grpc.ExperimentalApi
|
||||
public static final io.grpc.MethodDescriptor<io.grpc.benchmarks.proto.Control.ServerArgs,
|
||||
io.grpc.benchmarks.proto.Control.ServerStatus> METHOD_RUN_SERVER =
|
||||
io.grpc.MethodDescriptor.create(
|
||||
io.grpc.MethodDescriptor.MethodType.BIDI_STREAMING,
|
||||
generateFullMethodName(
|
||||
"grpc.testing.WorkerService", "RunServer"),
|
||||
io.grpc.protobuf.ProtoUtils.marshaller(io.grpc.benchmarks.proto.Control.ServerArgs.getDefaultInstance()),
|
||||
io.grpc.protobuf.ProtoUtils.marshaller(io.grpc.benchmarks.proto.Control.ServerStatus.getDefaultInstance()));
|
||||
@io.grpc.ExperimentalApi
|
||||
public static final io.grpc.MethodDescriptor<io.grpc.benchmarks.proto.Control.ClientArgs,
|
||||
io.grpc.benchmarks.proto.Control.ClientStatus> METHOD_RUN_CLIENT =
|
||||
io.grpc.MethodDescriptor.create(
|
||||
io.grpc.MethodDescriptor.MethodType.BIDI_STREAMING,
|
||||
generateFullMethodName(
|
||||
"grpc.testing.WorkerService", "RunClient"),
|
||||
io.grpc.protobuf.ProtoUtils.marshaller(io.grpc.benchmarks.proto.Control.ClientArgs.getDefaultInstance()),
|
||||
io.grpc.protobuf.ProtoUtils.marshaller(io.grpc.benchmarks.proto.Control.ClientStatus.getDefaultInstance()));
|
||||
@io.grpc.ExperimentalApi
|
||||
public static final io.grpc.MethodDescriptor<io.grpc.benchmarks.proto.Control.CoreRequest,
|
||||
io.grpc.benchmarks.proto.Control.CoreResponse> METHOD_CORE_COUNT =
|
||||
io.grpc.MethodDescriptor.create(
|
||||
io.grpc.MethodDescriptor.MethodType.UNARY,
|
||||
generateFullMethodName(
|
||||
"grpc.testing.WorkerService", "CoreCount"),
|
||||
io.grpc.protobuf.ProtoUtils.marshaller(io.grpc.benchmarks.proto.Control.CoreRequest.getDefaultInstance()),
|
||||
io.grpc.protobuf.ProtoUtils.marshaller(io.grpc.benchmarks.proto.Control.CoreResponse.getDefaultInstance()));
|
||||
@io.grpc.ExperimentalApi
|
||||
public static final io.grpc.MethodDescriptor<io.grpc.benchmarks.proto.Control.Void,
|
||||
io.grpc.benchmarks.proto.Control.Void> METHOD_QUIT_WORKER =
|
||||
io.grpc.MethodDescriptor.create(
|
||||
io.grpc.MethodDescriptor.MethodType.UNARY,
|
||||
generateFullMethodName(
|
||||
"grpc.testing.WorkerService", "QuitWorker"),
|
||||
io.grpc.protobuf.ProtoUtils.marshaller(io.grpc.benchmarks.proto.Control.Void.getDefaultInstance()),
|
||||
io.grpc.protobuf.ProtoUtils.marshaller(io.grpc.benchmarks.proto.Control.Void.getDefaultInstance()));
|
||||
|
||||
public static WorkerServiceStub newStub(io.grpc.Channel channel) {
|
||||
return new WorkerServiceStub(channel);
|
||||
}
|
||||
|
||||
public static WorkerServiceBlockingStub newBlockingStub(
|
||||
io.grpc.Channel channel) {
|
||||
return new WorkerServiceBlockingStub(channel);
|
||||
}
|
||||
|
||||
public static WorkerServiceFutureStub newFutureStub(
|
||||
io.grpc.Channel channel) {
|
||||
return new WorkerServiceFutureStub(channel);
|
||||
}
|
||||
|
||||
public static interface WorkerService {
|
||||
|
||||
public io.grpc.stub.StreamObserver<io.grpc.benchmarks.proto.Control.ServerArgs> runServer(
|
||||
io.grpc.stub.StreamObserver<io.grpc.benchmarks.proto.Control.ServerStatus> responseObserver);
|
||||
|
||||
public io.grpc.stub.StreamObserver<io.grpc.benchmarks.proto.Control.ClientArgs> runClient(
|
||||
io.grpc.stub.StreamObserver<io.grpc.benchmarks.proto.Control.ClientStatus> responseObserver);
|
||||
|
||||
public void coreCount(io.grpc.benchmarks.proto.Control.CoreRequest request,
|
||||
io.grpc.stub.StreamObserver<io.grpc.benchmarks.proto.Control.CoreResponse> responseObserver);
|
||||
|
||||
public void quitWorker(io.grpc.benchmarks.proto.Control.Void request,
|
||||
io.grpc.stub.StreamObserver<io.grpc.benchmarks.proto.Control.Void> responseObserver);
|
||||
}
|
||||
|
||||
public static interface WorkerServiceBlockingClient {
|
||||
|
||||
public io.grpc.benchmarks.proto.Control.CoreResponse coreCount(io.grpc.benchmarks.proto.Control.CoreRequest request);
|
||||
|
||||
public io.grpc.benchmarks.proto.Control.Void quitWorker(io.grpc.benchmarks.proto.Control.Void request);
|
||||
}
|
||||
|
||||
public static interface WorkerServiceFutureClient {
|
||||
|
||||
public com.google.common.util.concurrent.ListenableFuture<io.grpc.benchmarks.proto.Control.CoreResponse> coreCount(
|
||||
io.grpc.benchmarks.proto.Control.CoreRequest request);
|
||||
|
||||
public com.google.common.util.concurrent.ListenableFuture<io.grpc.benchmarks.proto.Control.Void> quitWorker(
|
||||
io.grpc.benchmarks.proto.Control.Void request);
|
||||
}
|
||||
|
||||
public static class WorkerServiceStub extends io.grpc.stub.AbstractStub<WorkerServiceStub>
|
||||
implements WorkerService {
|
||||
private WorkerServiceStub(io.grpc.Channel channel) {
|
||||
super(channel);
|
||||
}
|
||||
|
||||
private WorkerServiceStub(io.grpc.Channel channel,
|
||||
io.grpc.CallOptions callOptions) {
|
||||
super(channel, callOptions);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected WorkerServiceStub build(io.grpc.Channel channel,
|
||||
io.grpc.CallOptions callOptions) {
|
||||
return new WorkerServiceStub(channel, callOptions);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public io.grpc.stub.StreamObserver<io.grpc.benchmarks.proto.Control.ServerArgs> runServer(
|
||||
io.grpc.stub.StreamObserver<io.grpc.benchmarks.proto.Control.ServerStatus> responseObserver) {
|
||||
return asyncBidiStreamingCall(
|
||||
getChannel().newCall(METHOD_RUN_SERVER, getCallOptions()), responseObserver);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public io.grpc.stub.StreamObserver<io.grpc.benchmarks.proto.Control.ClientArgs> runClient(
|
||||
io.grpc.stub.StreamObserver<io.grpc.benchmarks.proto.Control.ClientStatus> responseObserver) {
|
||||
return asyncBidiStreamingCall(
|
||||
getChannel().newCall(METHOD_RUN_CLIENT, getCallOptions()), responseObserver);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public void coreCount(io.grpc.benchmarks.proto.Control.CoreRequest request,
|
||||
io.grpc.stub.StreamObserver<io.grpc.benchmarks.proto.Control.CoreResponse> responseObserver) {
|
||||
asyncUnaryCall(
|
||||
getChannel().newCall(METHOD_CORE_COUNT, getCallOptions()), request, responseObserver);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public void quitWorker(io.grpc.benchmarks.proto.Control.Void request,
|
||||
io.grpc.stub.StreamObserver<io.grpc.benchmarks.proto.Control.Void> responseObserver) {
|
||||
asyncUnaryCall(
|
||||
getChannel().newCall(METHOD_QUIT_WORKER, getCallOptions()), request, responseObserver);
|
||||
}
|
||||
}
|
||||
|
||||
public static class WorkerServiceBlockingStub extends io.grpc.stub.AbstractStub<WorkerServiceBlockingStub>
|
||||
implements WorkerServiceBlockingClient {
|
||||
private WorkerServiceBlockingStub(io.grpc.Channel channel) {
|
||||
super(channel);
|
||||
}
|
||||
|
||||
private WorkerServiceBlockingStub(io.grpc.Channel channel,
|
||||
io.grpc.CallOptions callOptions) {
|
||||
super(channel, callOptions);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected WorkerServiceBlockingStub build(io.grpc.Channel channel,
|
||||
io.grpc.CallOptions callOptions) {
|
||||
return new WorkerServiceBlockingStub(channel, callOptions);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public io.grpc.benchmarks.proto.Control.CoreResponse coreCount(io.grpc.benchmarks.proto.Control.CoreRequest request) {
|
||||
return blockingUnaryCall(
|
||||
getChannel(), METHOD_CORE_COUNT, getCallOptions(), request);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public io.grpc.benchmarks.proto.Control.Void quitWorker(io.grpc.benchmarks.proto.Control.Void request) {
|
||||
return blockingUnaryCall(
|
||||
getChannel(), METHOD_QUIT_WORKER, getCallOptions(), request);
|
||||
}
|
||||
}
|
||||
|
||||
public static class WorkerServiceFutureStub extends io.grpc.stub.AbstractStub<WorkerServiceFutureStub>
|
||||
implements WorkerServiceFutureClient {
|
||||
private WorkerServiceFutureStub(io.grpc.Channel channel) {
|
||||
super(channel);
|
||||
}
|
||||
|
||||
private WorkerServiceFutureStub(io.grpc.Channel channel,
|
||||
io.grpc.CallOptions callOptions) {
|
||||
super(channel, callOptions);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected WorkerServiceFutureStub build(io.grpc.Channel channel,
|
||||
io.grpc.CallOptions callOptions) {
|
||||
return new WorkerServiceFutureStub(channel, callOptions);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.common.util.concurrent.ListenableFuture<io.grpc.benchmarks.proto.Control.CoreResponse> coreCount(
|
||||
io.grpc.benchmarks.proto.Control.CoreRequest request) {
|
||||
return futureUnaryCall(
|
||||
getChannel().newCall(METHOD_CORE_COUNT, getCallOptions()), request);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.common.util.concurrent.ListenableFuture<io.grpc.benchmarks.proto.Control.Void> quitWorker(
|
||||
io.grpc.benchmarks.proto.Control.Void request) {
|
||||
return futureUnaryCall(
|
||||
getChannel().newCall(METHOD_QUIT_WORKER, getCallOptions()), request);
|
||||
}
|
||||
}
|
||||
|
||||
private static final int METHODID_CORE_COUNT = 0;
|
||||
private static final int METHODID_QUIT_WORKER = 1;
|
||||
private static final int METHODID_RUN_SERVER = 2;
|
||||
private static final int METHODID_RUN_CLIENT = 3;
|
||||
|
||||
private static class MethodHandlers<Req, Resp> implements
|
||||
io.grpc.stub.ServerCalls.UnaryMethod<Req, Resp>,
|
||||
io.grpc.stub.ServerCalls.ServerStreamingMethod<Req, Resp>,
|
||||
io.grpc.stub.ServerCalls.ClientStreamingMethod<Req, Resp>,
|
||||
io.grpc.stub.ServerCalls.BidiStreamingMethod<Req, Resp> {
|
||||
private final WorkerService serviceImpl;
|
||||
private final int methodId;
|
||||
|
||||
public MethodHandlers(WorkerService 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<Resp> responseObserver) {
|
||||
switch (methodId) {
|
||||
case METHODID_CORE_COUNT:
|
||||
serviceImpl.coreCount((io.grpc.benchmarks.proto.Control.CoreRequest) request,
|
||||
(io.grpc.stub.StreamObserver<io.grpc.benchmarks.proto.Control.CoreResponse>) responseObserver);
|
||||
break;
|
||||
case METHODID_QUIT_WORKER:
|
||||
serviceImpl.quitWorker((io.grpc.benchmarks.proto.Control.Void) request,
|
||||
(io.grpc.stub.StreamObserver<io.grpc.benchmarks.proto.Control.Void>) responseObserver);
|
||||
break;
|
||||
default:
|
||||
throw new AssertionError();
|
||||
}
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
@java.lang.SuppressWarnings("unchecked")
|
||||
public io.grpc.stub.StreamObserver<Req> invoke(
|
||||
io.grpc.stub.StreamObserver<Resp> responseObserver) {
|
||||
switch (methodId) {
|
||||
case METHODID_RUN_SERVER:
|
||||
return (io.grpc.stub.StreamObserver<Req>) serviceImpl.runServer(
|
||||
(io.grpc.stub.StreamObserver<io.grpc.benchmarks.proto.Control.ServerStatus>) responseObserver);
|
||||
case METHODID_RUN_CLIENT:
|
||||
return (io.grpc.stub.StreamObserver<Req>) serviceImpl.runClient(
|
||||
(io.grpc.stub.StreamObserver<io.grpc.benchmarks.proto.Control.ClientStatus>) responseObserver);
|
||||
default:
|
||||
throw new AssertionError();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public static io.grpc.ServerServiceDefinition bindService(
|
||||
final WorkerService serviceImpl) {
|
||||
return io.grpc.ServerServiceDefinition.builder(SERVICE_NAME)
|
||||
.addMethod(
|
||||
METHOD_RUN_SERVER,
|
||||
asyncBidiStreamingCall(
|
||||
new MethodHandlers<
|
||||
io.grpc.benchmarks.proto.Control.ServerArgs,
|
||||
io.grpc.benchmarks.proto.Control.ServerStatus>(
|
||||
serviceImpl, METHODID_RUN_SERVER)))
|
||||
.addMethod(
|
||||
METHOD_RUN_CLIENT,
|
||||
asyncBidiStreamingCall(
|
||||
new MethodHandlers<
|
||||
io.grpc.benchmarks.proto.Control.ClientArgs,
|
||||
io.grpc.benchmarks.proto.Control.ClientStatus>(
|
||||
serviceImpl, METHODID_RUN_CLIENT)))
|
||||
.addMethod(
|
||||
METHOD_CORE_COUNT,
|
||||
asyncUnaryCall(
|
||||
new MethodHandlers<
|
||||
io.grpc.benchmarks.proto.Control.CoreRequest,
|
||||
io.grpc.benchmarks.proto.Control.CoreResponse>(
|
||||
serviceImpl, METHODID_CORE_COUNT)))
|
||||
.addMethod(
|
||||
METHOD_QUIT_WORKER,
|
||||
asyncUnaryCall(
|
||||
new MethodHandlers<
|
||||
io.grpc.benchmarks.proto.Control.Void,
|
||||
io.grpc.benchmarks.proto.Control.Void>(
|
||||
serviceImpl, METHODID_QUIT_WORKER)))
|
||||
.build();
|
||||
}
|
||||
}
|
||||
|
|
@ -1,222 +0,0 @@
|
|||
package io.grpc.testing;
|
||||
|
||||
import static io.grpc.stub.ClientCalls.asyncUnaryCall;
|
||||
import static io.grpc.stub.ClientCalls.asyncServerStreamingCall;
|
||||
import static io.grpc.stub.ClientCalls.asyncClientStreamingCall;
|
||||
import static io.grpc.stub.ClientCalls.asyncBidiStreamingCall;
|
||||
import static io.grpc.stub.ClientCalls.blockingUnaryCall;
|
||||
import static io.grpc.stub.ClientCalls.blockingServerStreamingCall;
|
||||
import static io.grpc.stub.ClientCalls.futureUnaryCall;
|
||||
import static io.grpc.MethodDescriptor.generateFullMethodName;
|
||||
import static io.grpc.stub.ServerCalls.asyncUnaryCall;
|
||||
import static io.grpc.stub.ServerCalls.asyncServerStreamingCall;
|
||||
import static io.grpc.stub.ServerCalls.asyncClientStreamingCall;
|
||||
import static io.grpc.stub.ServerCalls.asyncBidiStreamingCall;
|
||||
|
||||
@javax.annotation.Generated(
|
||||
value = "by gRPC proto compiler",
|
||||
comments = "Source: qpstest.proto")
|
||||
public class TestServiceGrpc {
|
||||
|
||||
private TestServiceGrpc() {}
|
||||
|
||||
public static final String SERVICE_NAME = "grpc.testing.TestService";
|
||||
|
||||
// Static method descriptors that strictly reflect the proto.
|
||||
@io.grpc.ExperimentalApi
|
||||
public static final io.grpc.MethodDescriptor<io.grpc.testing.SimpleRequest,
|
||||
io.grpc.testing.SimpleResponse> METHOD_UNARY_CALL =
|
||||
io.grpc.MethodDescriptor.create(
|
||||
io.grpc.MethodDescriptor.MethodType.UNARY,
|
||||
generateFullMethodName(
|
||||
"grpc.testing.TestService", "UnaryCall"),
|
||||
io.grpc.protobuf.ProtoUtils.marshaller(io.grpc.testing.SimpleRequest.getDefaultInstance()),
|
||||
io.grpc.protobuf.ProtoUtils.marshaller(io.grpc.testing.SimpleResponse.getDefaultInstance()));
|
||||
@io.grpc.ExperimentalApi
|
||||
public static final io.grpc.MethodDescriptor<io.grpc.testing.SimpleRequest,
|
||||
io.grpc.testing.SimpleResponse> METHOD_STREAMING_CALL =
|
||||
io.grpc.MethodDescriptor.create(
|
||||
io.grpc.MethodDescriptor.MethodType.BIDI_STREAMING,
|
||||
generateFullMethodName(
|
||||
"grpc.testing.TestService", "StreamingCall"),
|
||||
io.grpc.protobuf.ProtoUtils.marshaller(io.grpc.testing.SimpleRequest.getDefaultInstance()),
|
||||
io.grpc.protobuf.ProtoUtils.marshaller(io.grpc.testing.SimpleResponse.getDefaultInstance()));
|
||||
|
||||
public static TestServiceStub newStub(io.grpc.Channel channel) {
|
||||
return new TestServiceStub(channel);
|
||||
}
|
||||
|
||||
public static TestServiceBlockingStub newBlockingStub(
|
||||
io.grpc.Channel channel) {
|
||||
return new TestServiceBlockingStub(channel);
|
||||
}
|
||||
|
||||
public static TestServiceFutureStub newFutureStub(
|
||||
io.grpc.Channel channel) {
|
||||
return new TestServiceFutureStub(channel);
|
||||
}
|
||||
|
||||
public static interface TestService {
|
||||
|
||||
public void unaryCall(io.grpc.testing.SimpleRequest request,
|
||||
io.grpc.stub.StreamObserver<io.grpc.testing.SimpleResponse> responseObserver);
|
||||
|
||||
public io.grpc.stub.StreamObserver<io.grpc.testing.SimpleRequest> streamingCall(
|
||||
io.grpc.stub.StreamObserver<io.grpc.testing.SimpleResponse> responseObserver);
|
||||
}
|
||||
|
||||
public static interface TestServiceBlockingClient {
|
||||
|
||||
public io.grpc.testing.SimpleResponse unaryCall(io.grpc.testing.SimpleRequest request);
|
||||
}
|
||||
|
||||
public static interface TestServiceFutureClient {
|
||||
|
||||
public com.google.common.util.concurrent.ListenableFuture<io.grpc.testing.SimpleResponse> unaryCall(
|
||||
io.grpc.testing.SimpleRequest request);
|
||||
}
|
||||
|
||||
public static class TestServiceStub extends io.grpc.stub.AbstractStub<TestServiceStub>
|
||||
implements TestService {
|
||||
private TestServiceStub(io.grpc.Channel channel) {
|
||||
super(channel);
|
||||
}
|
||||
|
||||
private TestServiceStub(io.grpc.Channel channel,
|
||||
io.grpc.CallOptions callOptions) {
|
||||
super(channel, callOptions);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected TestServiceStub build(io.grpc.Channel channel,
|
||||
io.grpc.CallOptions callOptions) {
|
||||
return new TestServiceStub(channel, callOptions);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public void unaryCall(io.grpc.testing.SimpleRequest request,
|
||||
io.grpc.stub.StreamObserver<io.grpc.testing.SimpleResponse> responseObserver) {
|
||||
asyncUnaryCall(
|
||||
getChannel().newCall(METHOD_UNARY_CALL, getCallOptions()), request, responseObserver);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public io.grpc.stub.StreamObserver<io.grpc.testing.SimpleRequest> streamingCall(
|
||||
io.grpc.stub.StreamObserver<io.grpc.testing.SimpleResponse> responseObserver) {
|
||||
return asyncBidiStreamingCall(
|
||||
getChannel().newCall(METHOD_STREAMING_CALL, getCallOptions()), responseObserver);
|
||||
}
|
||||
}
|
||||
|
||||
public static class TestServiceBlockingStub extends io.grpc.stub.AbstractStub<TestServiceBlockingStub>
|
||||
implements TestServiceBlockingClient {
|
||||
private TestServiceBlockingStub(io.grpc.Channel channel) {
|
||||
super(channel);
|
||||
}
|
||||
|
||||
private TestServiceBlockingStub(io.grpc.Channel channel,
|
||||
io.grpc.CallOptions callOptions) {
|
||||
super(channel, callOptions);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected TestServiceBlockingStub build(io.grpc.Channel channel,
|
||||
io.grpc.CallOptions callOptions) {
|
||||
return new TestServiceBlockingStub(channel, callOptions);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public io.grpc.testing.SimpleResponse unaryCall(io.grpc.testing.SimpleRequest request) {
|
||||
return blockingUnaryCall(
|
||||
getChannel(), METHOD_UNARY_CALL, getCallOptions(), request);
|
||||
}
|
||||
}
|
||||
|
||||
public static class TestServiceFutureStub extends io.grpc.stub.AbstractStub<TestServiceFutureStub>
|
||||
implements TestServiceFutureClient {
|
||||
private TestServiceFutureStub(io.grpc.Channel channel) {
|
||||
super(channel);
|
||||
}
|
||||
|
||||
private TestServiceFutureStub(io.grpc.Channel channel,
|
||||
io.grpc.CallOptions callOptions) {
|
||||
super(channel, callOptions);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected TestServiceFutureStub build(io.grpc.Channel channel,
|
||||
io.grpc.CallOptions callOptions) {
|
||||
return new TestServiceFutureStub(channel, callOptions);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.common.util.concurrent.ListenableFuture<io.grpc.testing.SimpleResponse> unaryCall(
|
||||
io.grpc.testing.SimpleRequest request) {
|
||||
return futureUnaryCall(
|
||||
getChannel().newCall(METHOD_UNARY_CALL, getCallOptions()), request);
|
||||
}
|
||||
}
|
||||
|
||||
private static final int METHODID_UNARY_CALL = 0;
|
||||
private static final int METHODID_STREAMING_CALL = 1;
|
||||
|
||||
private static class MethodHandlers<Req, Resp> implements
|
||||
io.grpc.stub.ServerCalls.UnaryMethod<Req, Resp>,
|
||||
io.grpc.stub.ServerCalls.ServerStreamingMethod<Req, Resp>,
|
||||
io.grpc.stub.ServerCalls.ClientStreamingMethod<Req, Resp>,
|
||||
io.grpc.stub.ServerCalls.BidiStreamingMethod<Req, Resp> {
|
||||
private final TestService serviceImpl;
|
||||
private final int methodId;
|
||||
|
||||
public MethodHandlers(TestService 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<Resp> responseObserver) {
|
||||
switch (methodId) {
|
||||
case METHODID_UNARY_CALL:
|
||||
serviceImpl.unaryCall((io.grpc.testing.SimpleRequest) request,
|
||||
(io.grpc.stub.StreamObserver<io.grpc.testing.SimpleResponse>) responseObserver);
|
||||
break;
|
||||
default:
|
||||
throw new AssertionError();
|
||||
}
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
@java.lang.SuppressWarnings("unchecked")
|
||||
public io.grpc.stub.StreamObserver<Req> invoke(
|
||||
io.grpc.stub.StreamObserver<Resp> responseObserver) {
|
||||
switch (methodId) {
|
||||
case METHODID_STREAMING_CALL:
|
||||
return (io.grpc.stub.StreamObserver<Req>) serviceImpl.streamingCall(
|
||||
(io.grpc.stub.StreamObserver<io.grpc.testing.SimpleResponse>) responseObserver);
|
||||
default:
|
||||
throw new AssertionError();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public static io.grpc.ServerServiceDefinition bindService(
|
||||
final TestService serviceImpl) {
|
||||
return io.grpc.ServerServiceDefinition.builder(SERVICE_NAME)
|
||||
.addMethod(
|
||||
METHOD_UNARY_CALL,
|
||||
asyncUnaryCall(
|
||||
new MethodHandlers<
|
||||
io.grpc.testing.SimpleRequest,
|
||||
io.grpc.testing.SimpleResponse>(
|
||||
serviceImpl, METHODID_UNARY_CALL)))
|
||||
.addMethod(
|
||||
METHOD_STREAMING_CALL,
|
||||
asyncBidiStreamingCall(
|
||||
new MethodHandlers<
|
||||
io.grpc.testing.SimpleRequest,
|
||||
io.grpc.testing.SimpleResponse>(
|
||||
serviceImpl, METHODID_STREAMING_CALL)))
|
||||
.build();
|
||||
}
|
||||
}
|
||||
|
|
@ -1,203 +0,0 @@
|
|||
package io.grpc.testing;
|
||||
|
||||
import static io.grpc.stub.ClientCalls.asyncUnaryCall;
|
||||
import static io.grpc.stub.ClientCalls.asyncServerStreamingCall;
|
||||
import static io.grpc.stub.ClientCalls.asyncClientStreamingCall;
|
||||
import static io.grpc.stub.ClientCalls.asyncBidiStreamingCall;
|
||||
import static io.grpc.stub.ClientCalls.blockingUnaryCall;
|
||||
import static io.grpc.stub.ClientCalls.blockingServerStreamingCall;
|
||||
import static io.grpc.stub.ClientCalls.futureUnaryCall;
|
||||
import static io.grpc.MethodDescriptor.generateFullMethodName;
|
||||
import static io.grpc.stub.ServerCalls.asyncUnaryCall;
|
||||
import static io.grpc.stub.ServerCalls.asyncServerStreamingCall;
|
||||
import static io.grpc.stub.ServerCalls.asyncClientStreamingCall;
|
||||
import static io.grpc.stub.ServerCalls.asyncBidiStreamingCall;
|
||||
|
||||
@javax.annotation.Generated(
|
||||
value = "by gRPC proto compiler",
|
||||
comments = "Source: qpstest.proto")
|
||||
public class WorkerGrpc {
|
||||
|
||||
private WorkerGrpc() {}
|
||||
|
||||
public static final String SERVICE_NAME = "grpc.testing.Worker";
|
||||
|
||||
// Static method descriptors that strictly reflect the proto.
|
||||
@io.grpc.ExperimentalApi
|
||||
public static final io.grpc.MethodDescriptor<io.grpc.testing.ClientArgs,
|
||||
io.grpc.testing.ClientStatus> METHOD_RUN_TEST =
|
||||
io.grpc.MethodDescriptor.create(
|
||||
io.grpc.MethodDescriptor.MethodType.BIDI_STREAMING,
|
||||
generateFullMethodName(
|
||||
"grpc.testing.Worker", "RunTest"),
|
||||
io.grpc.protobuf.ProtoUtils.marshaller(io.grpc.testing.ClientArgs.getDefaultInstance()),
|
||||
io.grpc.protobuf.ProtoUtils.marshaller(io.grpc.testing.ClientStatus.getDefaultInstance()));
|
||||
@io.grpc.ExperimentalApi
|
||||
public static final io.grpc.MethodDescriptor<io.grpc.testing.ServerArgs,
|
||||
io.grpc.testing.ServerStatus> METHOD_RUN_SERVER =
|
||||
io.grpc.MethodDescriptor.create(
|
||||
io.grpc.MethodDescriptor.MethodType.BIDI_STREAMING,
|
||||
generateFullMethodName(
|
||||
"grpc.testing.Worker", "RunServer"),
|
||||
io.grpc.protobuf.ProtoUtils.marshaller(io.grpc.testing.ServerArgs.getDefaultInstance()),
|
||||
io.grpc.protobuf.ProtoUtils.marshaller(io.grpc.testing.ServerStatus.getDefaultInstance()));
|
||||
|
||||
public static WorkerStub newStub(io.grpc.Channel channel) {
|
||||
return new WorkerStub(channel);
|
||||
}
|
||||
|
||||
public static WorkerBlockingStub newBlockingStub(
|
||||
io.grpc.Channel channel) {
|
||||
return new WorkerBlockingStub(channel);
|
||||
}
|
||||
|
||||
public static WorkerFutureStub newFutureStub(
|
||||
io.grpc.Channel channel) {
|
||||
return new WorkerFutureStub(channel);
|
||||
}
|
||||
|
||||
public static interface Worker {
|
||||
|
||||
public io.grpc.stub.StreamObserver<io.grpc.testing.ClientArgs> runTest(
|
||||
io.grpc.stub.StreamObserver<io.grpc.testing.ClientStatus> responseObserver);
|
||||
|
||||
public io.grpc.stub.StreamObserver<io.grpc.testing.ServerArgs> runServer(
|
||||
io.grpc.stub.StreamObserver<io.grpc.testing.ServerStatus> responseObserver);
|
||||
}
|
||||
|
||||
public static interface WorkerBlockingClient {
|
||||
}
|
||||
|
||||
public static interface WorkerFutureClient {
|
||||
}
|
||||
|
||||
public static class WorkerStub extends io.grpc.stub.AbstractStub<WorkerStub>
|
||||
implements Worker {
|
||||
private WorkerStub(io.grpc.Channel channel) {
|
||||
super(channel);
|
||||
}
|
||||
|
||||
private WorkerStub(io.grpc.Channel channel,
|
||||
io.grpc.CallOptions callOptions) {
|
||||
super(channel, callOptions);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected WorkerStub build(io.grpc.Channel channel,
|
||||
io.grpc.CallOptions callOptions) {
|
||||
return new WorkerStub(channel, callOptions);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public io.grpc.stub.StreamObserver<io.grpc.testing.ClientArgs> runTest(
|
||||
io.grpc.stub.StreamObserver<io.grpc.testing.ClientStatus> responseObserver) {
|
||||
return asyncBidiStreamingCall(
|
||||
getChannel().newCall(METHOD_RUN_TEST, getCallOptions()), responseObserver);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public io.grpc.stub.StreamObserver<io.grpc.testing.ServerArgs> runServer(
|
||||
io.grpc.stub.StreamObserver<io.grpc.testing.ServerStatus> responseObserver) {
|
||||
return asyncBidiStreamingCall(
|
||||
getChannel().newCall(METHOD_RUN_SERVER, getCallOptions()), responseObserver);
|
||||
}
|
||||
}
|
||||
|
||||
public static class WorkerBlockingStub extends io.grpc.stub.AbstractStub<WorkerBlockingStub>
|
||||
implements WorkerBlockingClient {
|
||||
private WorkerBlockingStub(io.grpc.Channel channel) {
|
||||
super(channel);
|
||||
}
|
||||
|
||||
private WorkerBlockingStub(io.grpc.Channel channel,
|
||||
io.grpc.CallOptions callOptions) {
|
||||
super(channel, callOptions);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected WorkerBlockingStub build(io.grpc.Channel channel,
|
||||
io.grpc.CallOptions callOptions) {
|
||||
return new WorkerBlockingStub(channel, callOptions);
|
||||
}
|
||||
}
|
||||
|
||||
public static class WorkerFutureStub extends io.grpc.stub.AbstractStub<WorkerFutureStub>
|
||||
implements WorkerFutureClient {
|
||||
private WorkerFutureStub(io.grpc.Channel channel) {
|
||||
super(channel);
|
||||
}
|
||||
|
||||
private WorkerFutureStub(io.grpc.Channel channel,
|
||||
io.grpc.CallOptions callOptions) {
|
||||
super(channel, callOptions);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected WorkerFutureStub build(io.grpc.Channel channel,
|
||||
io.grpc.CallOptions callOptions) {
|
||||
return new WorkerFutureStub(channel, callOptions);
|
||||
}
|
||||
}
|
||||
|
||||
private static final int METHODID_RUN_TEST = 0;
|
||||
private static final int METHODID_RUN_SERVER = 1;
|
||||
|
||||
private static class MethodHandlers<Req, Resp> implements
|
||||
io.grpc.stub.ServerCalls.UnaryMethod<Req, Resp>,
|
||||
io.grpc.stub.ServerCalls.ServerStreamingMethod<Req, Resp>,
|
||||
io.grpc.stub.ServerCalls.ClientStreamingMethod<Req, Resp>,
|
||||
io.grpc.stub.ServerCalls.BidiStreamingMethod<Req, Resp> {
|
||||
private final Worker serviceImpl;
|
||||
private final int methodId;
|
||||
|
||||
public MethodHandlers(Worker 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<Resp> responseObserver) {
|
||||
switch (methodId) {
|
||||
default:
|
||||
throw new AssertionError();
|
||||
}
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
@java.lang.SuppressWarnings("unchecked")
|
||||
public io.grpc.stub.StreamObserver<Req> invoke(
|
||||
io.grpc.stub.StreamObserver<Resp> responseObserver) {
|
||||
switch (methodId) {
|
||||
case METHODID_RUN_TEST:
|
||||
return (io.grpc.stub.StreamObserver<Req>) serviceImpl.runTest(
|
||||
(io.grpc.stub.StreamObserver<io.grpc.testing.ClientStatus>) responseObserver);
|
||||
case METHODID_RUN_SERVER:
|
||||
return (io.grpc.stub.StreamObserver<Req>) serviceImpl.runServer(
|
||||
(io.grpc.stub.StreamObserver<io.grpc.testing.ServerStatus>) responseObserver);
|
||||
default:
|
||||
throw new AssertionError();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
public static io.grpc.ServerServiceDefinition bindService(
|
||||
final Worker serviceImpl) {
|
||||
return io.grpc.ServerServiceDefinition.builder(SERVICE_NAME)
|
||||
.addMethod(
|
||||
METHOD_RUN_TEST,
|
||||
asyncBidiStreamingCall(
|
||||
new MethodHandlers<
|
||||
io.grpc.testing.ClientArgs,
|
||||
io.grpc.testing.ClientStatus>(
|
||||
serviceImpl, METHODID_RUN_TEST)))
|
||||
.addMethod(
|
||||
METHOD_RUN_SERVER,
|
||||
asyncBidiStreamingCall(
|
||||
new MethodHandlers<
|
||||
io.grpc.testing.ServerArgs,
|
||||
io.grpc.testing.ServerStatus>(
|
||||
serviceImpl, METHODID_RUN_SERVER)))
|
||||
.build();
|
||||
}
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
|
|
@ -0,0 +1,55 @@
|
|||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: services.proto
|
||||
|
||||
package io.grpc.benchmarks.proto;
|
||||
|
||||
public final class Services {
|
||||
private Services() {}
|
||||
public static void registerAllExtensions(
|
||||
com.google.protobuf.ExtensionRegistry registry) {
|
||||
}
|
||||
|
||||
public static com.google.protobuf.Descriptors.FileDescriptor
|
||||
getDescriptor() {
|
||||
return descriptor;
|
||||
}
|
||||
private static com.google.protobuf.Descriptors.FileDescriptor
|
||||
descriptor;
|
||||
static {
|
||||
java.lang.String[] descriptorData = {
|
||||
"\n\016services.proto\022\014grpc.testing\032\016messages" +
|
||||
".proto\032\rcontrol.proto2\252\001\n\020BenchmarkServi" +
|
||||
"ce\022F\n\tUnaryCall\022\033.grpc.testing.SimpleReq" +
|
||||
"uest\032\034.grpc.testing.SimpleResponse\022N\n\rSt" +
|
||||
"reamingCall\022\033.grpc.testing.SimpleRequest" +
|
||||
"\032\034.grpc.testing.SimpleResponse(\0010\0012\227\002\n\rW" +
|
||||
"orkerService\022E\n\tRunServer\022\030.grpc.testing" +
|
||||
".ServerArgs\032\032.grpc.testing.ServerStatus(" +
|
||||
"\0010\001\022E\n\tRunClient\022\030.grpc.testing.ClientAr" +
|
||||
"gs\032\032.grpc.testing.ClientStatus(\0010\001\022B\n\tCo",
|
||||
"reCount\022\031.grpc.testing.CoreRequest\032\032.grp" +
|
||||
"c.testing.CoreResponse\0224\n\nQuitWorker\022\022.g" +
|
||||
"rpc.testing.Void\032\022.grpc.testing.VoidB$\n\030" +
|
||||
"io.grpc.benchmarks.protoB\010Servicesb\006prot" +
|
||||
"o3"
|
||||
};
|
||||
com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner assigner =
|
||||
new com.google.protobuf.Descriptors.FileDescriptor. InternalDescriptorAssigner() {
|
||||
public com.google.protobuf.ExtensionRegistry assignDescriptors(
|
||||
com.google.protobuf.Descriptors.FileDescriptor root) {
|
||||
descriptor = root;
|
||||
return null;
|
||||
}
|
||||
};
|
||||
com.google.protobuf.Descriptors.FileDescriptor
|
||||
.internalBuildGeneratedFileFrom(descriptorData,
|
||||
new com.google.protobuf.Descriptors.FileDescriptor[] {
|
||||
io.grpc.benchmarks.proto.Messages.getDescriptor(),
|
||||
io.grpc.benchmarks.proto.Control.getDescriptor(),
|
||||
}, assigner);
|
||||
io.grpc.benchmarks.proto.Messages.getDescriptor();
|
||||
io.grpc.benchmarks.proto.Control.getDescriptor();
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(outer_class_scope)
|
||||
}
|
||||
File diff suppressed because it is too large
Load Diff
|
|
@ -1,735 +0,0 @@
|
|||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: qpstest.proto
|
||||
|
||||
package io.grpc.testing;
|
||||
|
||||
/**
|
||||
* Protobuf type {@code grpc.testing.ClientArgs}
|
||||
*/
|
||||
public final class ClientArgs extends
|
||||
com.google.protobuf.GeneratedMessage implements
|
||||
// @@protoc_insertion_point(message_implements:grpc.testing.ClientArgs)
|
||||
ClientArgsOrBuilder {
|
||||
// Use ClientArgs.newBuilder() to construct.
|
||||
private ClientArgs(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
|
||||
super(builder);
|
||||
}
|
||||
private ClientArgs() {
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public final com.google.protobuf.UnknownFieldSet
|
||||
getUnknownFields() {
|
||||
return com.google.protobuf.UnknownFieldSet.getDefaultInstance();
|
||||
}
|
||||
private ClientArgs(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry) {
|
||||
this();
|
||||
int mutable_bitField0_ = 0;
|
||||
try {
|
||||
boolean done = false;
|
||||
while (!done) {
|
||||
int tag = input.readTag();
|
||||
switch (tag) {
|
||||
case 0:
|
||||
done = true;
|
||||
break;
|
||||
default: {
|
||||
if (!input.skipField(tag)) {
|
||||
done = true;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case 10: {
|
||||
io.grpc.testing.ClientConfig.Builder subBuilder = null;
|
||||
if (argtypeCase_ == 1) {
|
||||
subBuilder = ((io.grpc.testing.ClientConfig) argtype_).toBuilder();
|
||||
}
|
||||
argtype_ =
|
||||
input.readMessage(io.grpc.testing.ClientConfig.parser(), extensionRegistry);
|
||||
if (subBuilder != null) {
|
||||
subBuilder.mergeFrom((io.grpc.testing.ClientConfig) argtype_);
|
||||
argtype_ = subBuilder.buildPartial();
|
||||
}
|
||||
argtypeCase_ = 1;
|
||||
break;
|
||||
}
|
||||
case 18: {
|
||||
io.grpc.testing.Mark.Builder subBuilder = null;
|
||||
if (argtypeCase_ == 2) {
|
||||
subBuilder = ((io.grpc.testing.Mark) argtype_).toBuilder();
|
||||
}
|
||||
argtype_ =
|
||||
input.readMessage(io.grpc.testing.Mark.parser(), extensionRegistry);
|
||||
if (subBuilder != null) {
|
||||
subBuilder.mergeFrom((io.grpc.testing.Mark) argtype_);
|
||||
argtype_ = subBuilder.buildPartial();
|
||||
}
|
||||
argtypeCase_ = 2;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
throw new RuntimeException(e.setUnfinishedMessage(this));
|
||||
} catch (java.io.IOException e) {
|
||||
throw new RuntimeException(
|
||||
new com.google.protobuf.InvalidProtocolBufferException(
|
||||
e.getMessage()).setUnfinishedMessage(this));
|
||||
} finally {
|
||||
makeExtensionsImmutable();
|
||||
}
|
||||
}
|
||||
public static final com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptor() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ClientArgs_descriptor;
|
||||
}
|
||||
|
||||
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ClientArgs_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
io.grpc.testing.ClientArgs.class, io.grpc.testing.ClientArgs.Builder.class);
|
||||
}
|
||||
|
||||
private int argtypeCase_ = 0;
|
||||
private java.lang.Object argtype_;
|
||||
public enum ArgtypeCase
|
||||
implements com.google.protobuf.Internal.EnumLite {
|
||||
SETUP(1),
|
||||
MARK(2),
|
||||
ARGTYPE_NOT_SET(0);
|
||||
private int value = 0;
|
||||
private ArgtypeCase(int value) {
|
||||
this.value = value;
|
||||
}
|
||||
public static ArgtypeCase valueOf(int value) {
|
||||
switch (value) {
|
||||
case 1: return SETUP;
|
||||
case 2: return MARK;
|
||||
case 0: return ARGTYPE_NOT_SET;
|
||||
default: throw new java.lang.IllegalArgumentException(
|
||||
"Value is undefined for this oneof enum.");
|
||||
}
|
||||
}
|
||||
public int getNumber() {
|
||||
return this.value;
|
||||
}
|
||||
};
|
||||
|
||||
public ArgtypeCase
|
||||
getArgtypeCase() {
|
||||
return ArgtypeCase.valueOf(
|
||||
argtypeCase_);
|
||||
}
|
||||
|
||||
public static final int SETUP_FIELD_NUMBER = 1;
|
||||
/**
|
||||
* <code>optional .grpc.testing.ClientConfig setup = 1;</code>
|
||||
*/
|
||||
public io.grpc.testing.ClientConfig getSetup() {
|
||||
if (argtypeCase_ == 1) {
|
||||
return (io.grpc.testing.ClientConfig) argtype_;
|
||||
}
|
||||
return io.grpc.testing.ClientConfig.getDefaultInstance();
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ClientConfig setup = 1;</code>
|
||||
*/
|
||||
public io.grpc.testing.ClientConfigOrBuilder getSetupOrBuilder() {
|
||||
if (argtypeCase_ == 1) {
|
||||
return (io.grpc.testing.ClientConfig) argtype_;
|
||||
}
|
||||
return io.grpc.testing.ClientConfig.getDefaultInstance();
|
||||
}
|
||||
|
||||
public static final int MARK_FIELD_NUMBER = 2;
|
||||
/**
|
||||
* <code>optional .grpc.testing.Mark mark = 2;</code>
|
||||
*/
|
||||
public io.grpc.testing.Mark getMark() {
|
||||
if (argtypeCase_ == 2) {
|
||||
return (io.grpc.testing.Mark) argtype_;
|
||||
}
|
||||
return io.grpc.testing.Mark.getDefaultInstance();
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.Mark mark = 2;</code>
|
||||
*/
|
||||
public io.grpc.testing.MarkOrBuilder getMarkOrBuilder() {
|
||||
if (argtypeCase_ == 2) {
|
||||
return (io.grpc.testing.Mark) argtype_;
|
||||
}
|
||||
return io.grpc.testing.Mark.getDefaultInstance();
|
||||
}
|
||||
|
||||
private byte memoizedIsInitialized = -1;
|
||||
public final boolean isInitialized() {
|
||||
byte isInitialized = memoizedIsInitialized;
|
||||
if (isInitialized == 1) return true;
|
||||
if (isInitialized == 0) return false;
|
||||
|
||||
memoizedIsInitialized = 1;
|
||||
return true;
|
||||
}
|
||||
|
||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
||||
throws java.io.IOException {
|
||||
if (argtypeCase_ == 1) {
|
||||
output.writeMessage(1, (io.grpc.testing.ClientConfig) argtype_);
|
||||
}
|
||||
if (argtypeCase_ == 2) {
|
||||
output.writeMessage(2, (io.grpc.testing.Mark) argtype_);
|
||||
}
|
||||
}
|
||||
|
||||
public int getSerializedSize() {
|
||||
int size = memoizedSize;
|
||||
if (size != -1) return size;
|
||||
|
||||
size = 0;
|
||||
if (argtypeCase_ == 1) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeMessageSize(1, (io.grpc.testing.ClientConfig) argtype_);
|
||||
}
|
||||
if (argtypeCase_ == 2) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeMessageSize(2, (io.grpc.testing.Mark) argtype_);
|
||||
}
|
||||
memoizedSize = size;
|
||||
return size;
|
||||
}
|
||||
|
||||
private static final long serialVersionUID = 0L;
|
||||
public static io.grpc.testing.ClientArgs parseFrom(
|
||||
com.google.protobuf.ByteString data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static io.grpc.testing.ClientArgs parseFrom(
|
||||
com.google.protobuf.ByteString data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.ClientArgs parseFrom(byte[] data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static io.grpc.testing.ClientArgs parseFrom(
|
||||
byte[] data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.ClientArgs parseFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.ClientArgs parseFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.ClientArgs parseDelimitedFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseDelimitedFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.ClientArgs parseDelimitedFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseDelimitedFrom(input, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.ClientArgs parseFrom(
|
||||
com.google.protobuf.CodedInputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.ClientArgs parseFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input, extensionRegistry);
|
||||
}
|
||||
|
||||
public Builder newBuilderForType() { return newBuilder(); }
|
||||
public static Builder newBuilder() {
|
||||
return DEFAULT_INSTANCE.toBuilder();
|
||||
}
|
||||
public static Builder newBuilder(io.grpc.testing.ClientArgs prototype) {
|
||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
||||
}
|
||||
public Builder toBuilder() {
|
||||
return this == DEFAULT_INSTANCE
|
||||
? new Builder() : new Builder().mergeFrom(this);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected Builder newBuilderForType(
|
||||
com.google.protobuf.GeneratedMessage.BuilderParent parent) {
|
||||
Builder builder = new Builder(parent);
|
||||
return builder;
|
||||
}
|
||||
/**
|
||||
* Protobuf type {@code grpc.testing.ClientArgs}
|
||||
*/
|
||||
public static final class Builder extends
|
||||
com.google.protobuf.GeneratedMessage.Builder<Builder> implements
|
||||
// @@protoc_insertion_point(builder_implements:grpc.testing.ClientArgs)
|
||||
io.grpc.testing.ClientArgsOrBuilder {
|
||||
public static final com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptor() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ClientArgs_descriptor;
|
||||
}
|
||||
|
||||
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ClientArgs_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
io.grpc.testing.ClientArgs.class, io.grpc.testing.ClientArgs.Builder.class);
|
||||
}
|
||||
|
||||
// Construct using io.grpc.testing.ClientArgs.newBuilder()
|
||||
private Builder() {
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
|
||||
private Builder(
|
||||
com.google.protobuf.GeneratedMessage.BuilderParent parent) {
|
||||
super(parent);
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
private void maybeForceBuilderInitialization() {
|
||||
if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
|
||||
}
|
||||
}
|
||||
public Builder clear() {
|
||||
super.clear();
|
||||
argtypeCase_ = 0;
|
||||
argtype_ = null;
|
||||
return this;
|
||||
}
|
||||
|
||||
public com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptorForType() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ClientArgs_descriptor;
|
||||
}
|
||||
|
||||
public io.grpc.testing.ClientArgs getDefaultInstanceForType() {
|
||||
return io.grpc.testing.ClientArgs.getDefaultInstance();
|
||||
}
|
||||
|
||||
public io.grpc.testing.ClientArgs build() {
|
||||
io.grpc.testing.ClientArgs result = buildPartial();
|
||||
if (!result.isInitialized()) {
|
||||
throw newUninitializedMessageException(result);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
public io.grpc.testing.ClientArgs buildPartial() {
|
||||
io.grpc.testing.ClientArgs result = new io.grpc.testing.ClientArgs(this);
|
||||
if (argtypeCase_ == 1) {
|
||||
if (setupBuilder_ == null) {
|
||||
result.argtype_ = argtype_;
|
||||
} else {
|
||||
result.argtype_ = setupBuilder_.build();
|
||||
}
|
||||
}
|
||||
if (argtypeCase_ == 2) {
|
||||
if (markBuilder_ == null) {
|
||||
result.argtype_ = argtype_;
|
||||
} else {
|
||||
result.argtype_ = markBuilder_.build();
|
||||
}
|
||||
}
|
||||
result.argtypeCase_ = argtypeCase_;
|
||||
onBuilt();
|
||||
return result;
|
||||
}
|
||||
|
||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
||||
if (other instanceof io.grpc.testing.ClientArgs) {
|
||||
return mergeFrom((io.grpc.testing.ClientArgs)other);
|
||||
} else {
|
||||
super.mergeFrom(other);
|
||||
return this;
|
||||
}
|
||||
}
|
||||
|
||||
public Builder mergeFrom(io.grpc.testing.ClientArgs other) {
|
||||
if (other == io.grpc.testing.ClientArgs.getDefaultInstance()) return this;
|
||||
switch (other.getArgtypeCase()) {
|
||||
case SETUP: {
|
||||
mergeSetup(other.getSetup());
|
||||
break;
|
||||
}
|
||||
case MARK: {
|
||||
mergeMark(other.getMark());
|
||||
break;
|
||||
}
|
||||
case ARGTYPE_NOT_SET: {
|
||||
break;
|
||||
}
|
||||
}
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
public final boolean isInitialized() {
|
||||
return true;
|
||||
}
|
||||
|
||||
public Builder mergeFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
io.grpc.testing.ClientArgs parsedMessage = null;
|
||||
try {
|
||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
parsedMessage = (io.grpc.testing.ClientArgs) e.getUnfinishedMessage();
|
||||
throw e;
|
||||
} finally {
|
||||
if (parsedMessage != null) {
|
||||
mergeFrom(parsedMessage);
|
||||
}
|
||||
}
|
||||
return this;
|
||||
}
|
||||
private int argtypeCase_ = 0;
|
||||
private java.lang.Object argtype_;
|
||||
public ArgtypeCase
|
||||
getArgtypeCase() {
|
||||
return ArgtypeCase.valueOf(
|
||||
argtypeCase_);
|
||||
}
|
||||
|
||||
public Builder clearArgtype() {
|
||||
argtypeCase_ = 0;
|
||||
argtype_ = null;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
|
||||
private com.google.protobuf.SingleFieldBuilder<
|
||||
io.grpc.testing.ClientConfig, io.grpc.testing.ClientConfig.Builder, io.grpc.testing.ClientConfigOrBuilder> setupBuilder_;
|
||||
/**
|
||||
* <code>optional .grpc.testing.ClientConfig setup = 1;</code>
|
||||
*/
|
||||
public io.grpc.testing.ClientConfig getSetup() {
|
||||
if (setupBuilder_ == null) {
|
||||
if (argtypeCase_ == 1) {
|
||||
return (io.grpc.testing.ClientConfig) argtype_;
|
||||
}
|
||||
return io.grpc.testing.ClientConfig.getDefaultInstance();
|
||||
} else {
|
||||
if (argtypeCase_ == 1) {
|
||||
return setupBuilder_.getMessage();
|
||||
}
|
||||
return io.grpc.testing.ClientConfig.getDefaultInstance();
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ClientConfig setup = 1;</code>
|
||||
*/
|
||||
public Builder setSetup(io.grpc.testing.ClientConfig value) {
|
||||
if (setupBuilder_ == null) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
argtype_ = value;
|
||||
onChanged();
|
||||
} else {
|
||||
setupBuilder_.setMessage(value);
|
||||
}
|
||||
argtypeCase_ = 1;
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ClientConfig setup = 1;</code>
|
||||
*/
|
||||
public Builder setSetup(
|
||||
io.grpc.testing.ClientConfig.Builder builderForValue) {
|
||||
if (setupBuilder_ == null) {
|
||||
argtype_ = builderForValue.build();
|
||||
onChanged();
|
||||
} else {
|
||||
setupBuilder_.setMessage(builderForValue.build());
|
||||
}
|
||||
argtypeCase_ = 1;
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ClientConfig setup = 1;</code>
|
||||
*/
|
||||
public Builder mergeSetup(io.grpc.testing.ClientConfig value) {
|
||||
if (setupBuilder_ == null) {
|
||||
if (argtypeCase_ == 1 &&
|
||||
argtype_ != io.grpc.testing.ClientConfig.getDefaultInstance()) {
|
||||
argtype_ = io.grpc.testing.ClientConfig.newBuilder((io.grpc.testing.ClientConfig) argtype_)
|
||||
.mergeFrom(value).buildPartial();
|
||||
} else {
|
||||
argtype_ = value;
|
||||
}
|
||||
onChanged();
|
||||
} else {
|
||||
if (argtypeCase_ == 1) {
|
||||
setupBuilder_.mergeFrom(value);
|
||||
}
|
||||
setupBuilder_.setMessage(value);
|
||||
}
|
||||
argtypeCase_ = 1;
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ClientConfig setup = 1;</code>
|
||||
*/
|
||||
public Builder clearSetup() {
|
||||
if (setupBuilder_ == null) {
|
||||
if (argtypeCase_ == 1) {
|
||||
argtypeCase_ = 0;
|
||||
argtype_ = null;
|
||||
onChanged();
|
||||
}
|
||||
} else {
|
||||
if (argtypeCase_ == 1) {
|
||||
argtypeCase_ = 0;
|
||||
argtype_ = null;
|
||||
}
|
||||
setupBuilder_.clear();
|
||||
}
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ClientConfig setup = 1;</code>
|
||||
*/
|
||||
public io.grpc.testing.ClientConfig.Builder getSetupBuilder() {
|
||||
return getSetupFieldBuilder().getBuilder();
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ClientConfig setup = 1;</code>
|
||||
*/
|
||||
public io.grpc.testing.ClientConfigOrBuilder getSetupOrBuilder() {
|
||||
if ((argtypeCase_ == 1) && (setupBuilder_ != null)) {
|
||||
return setupBuilder_.getMessageOrBuilder();
|
||||
} else {
|
||||
if (argtypeCase_ == 1) {
|
||||
return (io.grpc.testing.ClientConfig) argtype_;
|
||||
}
|
||||
return io.grpc.testing.ClientConfig.getDefaultInstance();
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ClientConfig setup = 1;</code>
|
||||
*/
|
||||
private com.google.protobuf.SingleFieldBuilder<
|
||||
io.grpc.testing.ClientConfig, io.grpc.testing.ClientConfig.Builder, io.grpc.testing.ClientConfigOrBuilder>
|
||||
getSetupFieldBuilder() {
|
||||
if (setupBuilder_ == null) {
|
||||
if (!(argtypeCase_ == 1)) {
|
||||
argtype_ = io.grpc.testing.ClientConfig.getDefaultInstance();
|
||||
}
|
||||
setupBuilder_ = new com.google.protobuf.SingleFieldBuilder<
|
||||
io.grpc.testing.ClientConfig, io.grpc.testing.ClientConfig.Builder, io.grpc.testing.ClientConfigOrBuilder>(
|
||||
(io.grpc.testing.ClientConfig) argtype_,
|
||||
getParentForChildren(),
|
||||
isClean());
|
||||
argtype_ = null;
|
||||
}
|
||||
argtypeCase_ = 1;
|
||||
onChanged();;
|
||||
return setupBuilder_;
|
||||
}
|
||||
|
||||
private com.google.protobuf.SingleFieldBuilder<
|
||||
io.grpc.testing.Mark, io.grpc.testing.Mark.Builder, io.grpc.testing.MarkOrBuilder> markBuilder_;
|
||||
/**
|
||||
* <code>optional .grpc.testing.Mark mark = 2;</code>
|
||||
*/
|
||||
public io.grpc.testing.Mark getMark() {
|
||||
if (markBuilder_ == null) {
|
||||
if (argtypeCase_ == 2) {
|
||||
return (io.grpc.testing.Mark) argtype_;
|
||||
}
|
||||
return io.grpc.testing.Mark.getDefaultInstance();
|
||||
} else {
|
||||
if (argtypeCase_ == 2) {
|
||||
return markBuilder_.getMessage();
|
||||
}
|
||||
return io.grpc.testing.Mark.getDefaultInstance();
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.Mark mark = 2;</code>
|
||||
*/
|
||||
public Builder setMark(io.grpc.testing.Mark value) {
|
||||
if (markBuilder_ == null) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
argtype_ = value;
|
||||
onChanged();
|
||||
} else {
|
||||
markBuilder_.setMessage(value);
|
||||
}
|
||||
argtypeCase_ = 2;
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.Mark mark = 2;</code>
|
||||
*/
|
||||
public Builder setMark(
|
||||
io.grpc.testing.Mark.Builder builderForValue) {
|
||||
if (markBuilder_ == null) {
|
||||
argtype_ = builderForValue.build();
|
||||
onChanged();
|
||||
} else {
|
||||
markBuilder_.setMessage(builderForValue.build());
|
||||
}
|
||||
argtypeCase_ = 2;
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.Mark mark = 2;</code>
|
||||
*/
|
||||
public Builder mergeMark(io.grpc.testing.Mark value) {
|
||||
if (markBuilder_ == null) {
|
||||
if (argtypeCase_ == 2 &&
|
||||
argtype_ != io.grpc.testing.Mark.getDefaultInstance()) {
|
||||
argtype_ = io.grpc.testing.Mark.newBuilder((io.grpc.testing.Mark) argtype_)
|
||||
.mergeFrom(value).buildPartial();
|
||||
} else {
|
||||
argtype_ = value;
|
||||
}
|
||||
onChanged();
|
||||
} else {
|
||||
if (argtypeCase_ == 2) {
|
||||
markBuilder_.mergeFrom(value);
|
||||
}
|
||||
markBuilder_.setMessage(value);
|
||||
}
|
||||
argtypeCase_ = 2;
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.Mark mark = 2;</code>
|
||||
*/
|
||||
public Builder clearMark() {
|
||||
if (markBuilder_ == null) {
|
||||
if (argtypeCase_ == 2) {
|
||||
argtypeCase_ = 0;
|
||||
argtype_ = null;
|
||||
onChanged();
|
||||
}
|
||||
} else {
|
||||
if (argtypeCase_ == 2) {
|
||||
argtypeCase_ = 0;
|
||||
argtype_ = null;
|
||||
}
|
||||
markBuilder_.clear();
|
||||
}
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.Mark mark = 2;</code>
|
||||
*/
|
||||
public io.grpc.testing.Mark.Builder getMarkBuilder() {
|
||||
return getMarkFieldBuilder().getBuilder();
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.Mark mark = 2;</code>
|
||||
*/
|
||||
public io.grpc.testing.MarkOrBuilder getMarkOrBuilder() {
|
||||
if ((argtypeCase_ == 2) && (markBuilder_ != null)) {
|
||||
return markBuilder_.getMessageOrBuilder();
|
||||
} else {
|
||||
if (argtypeCase_ == 2) {
|
||||
return (io.grpc.testing.Mark) argtype_;
|
||||
}
|
||||
return io.grpc.testing.Mark.getDefaultInstance();
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.Mark mark = 2;</code>
|
||||
*/
|
||||
private com.google.protobuf.SingleFieldBuilder<
|
||||
io.grpc.testing.Mark, io.grpc.testing.Mark.Builder, io.grpc.testing.MarkOrBuilder>
|
||||
getMarkFieldBuilder() {
|
||||
if (markBuilder_ == null) {
|
||||
if (!(argtypeCase_ == 2)) {
|
||||
argtype_ = io.grpc.testing.Mark.getDefaultInstance();
|
||||
}
|
||||
markBuilder_ = new com.google.protobuf.SingleFieldBuilder<
|
||||
io.grpc.testing.Mark, io.grpc.testing.Mark.Builder, io.grpc.testing.MarkOrBuilder>(
|
||||
(io.grpc.testing.Mark) argtype_,
|
||||
getParentForChildren(),
|
||||
isClean());
|
||||
argtype_ = null;
|
||||
}
|
||||
argtypeCase_ = 2;
|
||||
onChanged();;
|
||||
return markBuilder_;
|
||||
}
|
||||
public final Builder setUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return this;
|
||||
}
|
||||
|
||||
public final Builder mergeUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return this;
|
||||
}
|
||||
|
||||
|
||||
// @@protoc_insertion_point(builder_scope:grpc.testing.ClientArgs)
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(class_scope:grpc.testing.ClientArgs)
|
||||
private static final io.grpc.testing.ClientArgs DEFAULT_INSTANCE;
|
||||
static {
|
||||
DEFAULT_INSTANCE = new io.grpc.testing.ClientArgs();
|
||||
}
|
||||
|
||||
public static io.grpc.testing.ClientArgs getDefaultInstance() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
private static final com.google.protobuf.Parser<ClientArgs>
|
||||
PARSER = new com.google.protobuf.AbstractParser<ClientArgs>() {
|
||||
public ClientArgs parsePartialFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
try {
|
||||
return new ClientArgs(input, extensionRegistry);
|
||||
} catch (RuntimeException e) {
|
||||
if (e.getCause() instanceof
|
||||
com.google.protobuf.InvalidProtocolBufferException) {
|
||||
throw (com.google.protobuf.InvalidProtocolBufferException)
|
||||
e.getCause();
|
||||
}
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
public static com.google.protobuf.Parser<ClientArgs> parser() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.Parser<ClientArgs> getParserForType() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
public io.grpc.testing.ClientArgs getDefaultInstanceForType() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
|
@ -1,29 +0,0 @@
|
|||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: qpstest.proto
|
||||
|
||||
package io.grpc.testing;
|
||||
|
||||
public interface ClientArgsOrBuilder extends
|
||||
// @@protoc_insertion_point(interface_extends:grpc.testing.ClientArgs)
|
||||
com.google.protobuf.MessageOrBuilder {
|
||||
|
||||
/**
|
||||
* <code>optional .grpc.testing.ClientConfig setup = 1;</code>
|
||||
*/
|
||||
io.grpc.testing.ClientConfig getSetup();
|
||||
/**
|
||||
* <code>optional .grpc.testing.ClientConfig setup = 1;</code>
|
||||
*/
|
||||
io.grpc.testing.ClientConfigOrBuilder getSetupOrBuilder();
|
||||
|
||||
/**
|
||||
* <code>optional .grpc.testing.Mark mark = 2;</code>
|
||||
*/
|
||||
io.grpc.testing.Mark getMark();
|
||||
/**
|
||||
* <code>optional .grpc.testing.Mark mark = 2;</code>
|
||||
*/
|
||||
io.grpc.testing.MarkOrBuilder getMarkOrBuilder();
|
||||
|
||||
public io.grpc.testing.ClientArgs.ArgtypeCase getArgtypeCase();
|
||||
}
|
||||
|
|
@ -1,932 +0,0 @@
|
|||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: qpstest.proto
|
||||
|
||||
package io.grpc.testing;
|
||||
|
||||
/**
|
||||
* Protobuf type {@code grpc.testing.ClientConfig}
|
||||
*/
|
||||
public final class ClientConfig extends
|
||||
com.google.protobuf.GeneratedMessage implements
|
||||
// @@protoc_insertion_point(message_implements:grpc.testing.ClientConfig)
|
||||
ClientConfigOrBuilder {
|
||||
// Use ClientConfig.newBuilder() to construct.
|
||||
private ClientConfig(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
|
||||
super(builder);
|
||||
}
|
||||
private ClientConfig() {
|
||||
serverTargets_ = com.google.protobuf.LazyStringArrayList.EMPTY;
|
||||
clientType_ = 0;
|
||||
enableSsl_ = false;
|
||||
outstandingRpcsPerChannel_ = 0;
|
||||
clientChannels_ = 0;
|
||||
payloadSize_ = 0;
|
||||
asyncClientThreads_ = 0;
|
||||
rpcType_ = 0;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public final com.google.protobuf.UnknownFieldSet
|
||||
getUnknownFields() {
|
||||
return com.google.protobuf.UnknownFieldSet.getDefaultInstance();
|
||||
}
|
||||
private ClientConfig(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry) {
|
||||
this();
|
||||
int mutable_bitField0_ = 0;
|
||||
try {
|
||||
boolean done = false;
|
||||
while (!done) {
|
||||
int tag = input.readTag();
|
||||
switch (tag) {
|
||||
case 0:
|
||||
done = true;
|
||||
break;
|
||||
default: {
|
||||
if (!input.skipField(tag)) {
|
||||
done = true;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case 10: {
|
||||
java.lang.String s = input.readStringRequireUtf8();
|
||||
if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) {
|
||||
serverTargets_ = new com.google.protobuf.LazyStringArrayList();
|
||||
mutable_bitField0_ |= 0x00000001;
|
||||
}
|
||||
serverTargets_.add(s);
|
||||
break;
|
||||
}
|
||||
case 16: {
|
||||
int rawValue = input.readEnum();
|
||||
|
||||
clientType_ = rawValue;
|
||||
break;
|
||||
}
|
||||
case 24: {
|
||||
|
||||
enableSsl_ = input.readBool();
|
||||
break;
|
||||
}
|
||||
case 32: {
|
||||
|
||||
outstandingRpcsPerChannel_ = input.readInt32();
|
||||
break;
|
||||
}
|
||||
case 40: {
|
||||
|
||||
clientChannels_ = input.readInt32();
|
||||
break;
|
||||
}
|
||||
case 48: {
|
||||
|
||||
payloadSize_ = input.readInt32();
|
||||
break;
|
||||
}
|
||||
case 56: {
|
||||
|
||||
asyncClientThreads_ = input.readInt32();
|
||||
break;
|
||||
}
|
||||
case 64: {
|
||||
int rawValue = input.readEnum();
|
||||
|
||||
rpcType_ = rawValue;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
throw new RuntimeException(e.setUnfinishedMessage(this));
|
||||
} catch (java.io.IOException e) {
|
||||
throw new RuntimeException(
|
||||
new com.google.protobuf.InvalidProtocolBufferException(
|
||||
e.getMessage()).setUnfinishedMessage(this));
|
||||
} finally {
|
||||
if (((mutable_bitField0_ & 0x00000001) == 0x00000001)) {
|
||||
serverTargets_ = serverTargets_.getUnmodifiableView();
|
||||
}
|
||||
makeExtensionsImmutable();
|
||||
}
|
||||
}
|
||||
public static final com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptor() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ClientConfig_descriptor;
|
||||
}
|
||||
|
||||
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ClientConfig_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
io.grpc.testing.ClientConfig.class, io.grpc.testing.ClientConfig.Builder.class);
|
||||
}
|
||||
|
||||
private int bitField0_;
|
||||
public static final int SERVER_TARGETS_FIELD_NUMBER = 1;
|
||||
private com.google.protobuf.LazyStringList serverTargets_;
|
||||
/**
|
||||
* <code>repeated string server_targets = 1;</code>
|
||||
*/
|
||||
public com.google.protobuf.ProtocolStringList
|
||||
getServerTargetsList() {
|
||||
return serverTargets_;
|
||||
}
|
||||
/**
|
||||
* <code>repeated string server_targets = 1;</code>
|
||||
*/
|
||||
public int getServerTargetsCount() {
|
||||
return serverTargets_.size();
|
||||
}
|
||||
/**
|
||||
* <code>repeated string server_targets = 1;</code>
|
||||
*/
|
||||
public java.lang.String getServerTargets(int index) {
|
||||
return serverTargets_.get(index);
|
||||
}
|
||||
/**
|
||||
* <code>repeated string server_targets = 1;</code>
|
||||
*/
|
||||
public com.google.protobuf.ByteString
|
||||
getServerTargetsBytes(int index) {
|
||||
return serverTargets_.getByteString(index);
|
||||
}
|
||||
|
||||
public static final int CLIENT_TYPE_FIELD_NUMBER = 2;
|
||||
private int clientType_;
|
||||
/**
|
||||
* <code>optional .grpc.testing.ClientType client_type = 2;</code>
|
||||
*/
|
||||
public int getClientTypeValue() {
|
||||
return clientType_;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ClientType client_type = 2;</code>
|
||||
*/
|
||||
public io.grpc.testing.ClientType getClientType() {
|
||||
io.grpc.testing.ClientType result = io.grpc.testing.ClientType.valueOf(clientType_);
|
||||
return result == null ? io.grpc.testing.ClientType.UNRECOGNIZED : result;
|
||||
}
|
||||
|
||||
public static final int ENABLE_SSL_FIELD_NUMBER = 3;
|
||||
private boolean enableSsl_;
|
||||
/**
|
||||
* <code>optional bool enable_ssl = 3;</code>
|
||||
*/
|
||||
public boolean getEnableSsl() {
|
||||
return enableSsl_;
|
||||
}
|
||||
|
||||
public static final int OUTSTANDING_RPCS_PER_CHANNEL_FIELD_NUMBER = 4;
|
||||
private int outstandingRpcsPerChannel_;
|
||||
/**
|
||||
* <code>optional int32 outstanding_rpcs_per_channel = 4;</code>
|
||||
*/
|
||||
public int getOutstandingRpcsPerChannel() {
|
||||
return outstandingRpcsPerChannel_;
|
||||
}
|
||||
|
||||
public static final int CLIENT_CHANNELS_FIELD_NUMBER = 5;
|
||||
private int clientChannels_;
|
||||
/**
|
||||
* <code>optional int32 client_channels = 5;</code>
|
||||
*/
|
||||
public int getClientChannels() {
|
||||
return clientChannels_;
|
||||
}
|
||||
|
||||
public static final int PAYLOAD_SIZE_FIELD_NUMBER = 6;
|
||||
private int payloadSize_;
|
||||
/**
|
||||
* <code>optional int32 payload_size = 6;</code>
|
||||
*/
|
||||
public int getPayloadSize() {
|
||||
return payloadSize_;
|
||||
}
|
||||
|
||||
public static final int ASYNC_CLIENT_THREADS_FIELD_NUMBER = 7;
|
||||
private int asyncClientThreads_;
|
||||
/**
|
||||
* <code>optional int32 async_client_threads = 7;</code>
|
||||
*
|
||||
* <pre>
|
||||
* only for async client:
|
||||
* </pre>
|
||||
*/
|
||||
public int getAsyncClientThreads() {
|
||||
return asyncClientThreads_;
|
||||
}
|
||||
|
||||
public static final int RPC_TYPE_FIELD_NUMBER = 8;
|
||||
private int rpcType_;
|
||||
/**
|
||||
* <code>optional .grpc.testing.RpcType rpc_type = 8;</code>
|
||||
*/
|
||||
public int getRpcTypeValue() {
|
||||
return rpcType_;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.RpcType rpc_type = 8;</code>
|
||||
*/
|
||||
public io.grpc.testing.RpcType getRpcType() {
|
||||
io.grpc.testing.RpcType result = io.grpc.testing.RpcType.valueOf(rpcType_);
|
||||
return result == null ? io.grpc.testing.RpcType.UNRECOGNIZED : result;
|
||||
}
|
||||
|
||||
private byte memoizedIsInitialized = -1;
|
||||
public final boolean isInitialized() {
|
||||
byte isInitialized = memoizedIsInitialized;
|
||||
if (isInitialized == 1) return true;
|
||||
if (isInitialized == 0) return false;
|
||||
|
||||
memoizedIsInitialized = 1;
|
||||
return true;
|
||||
}
|
||||
|
||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
||||
throws java.io.IOException {
|
||||
for (int i = 0; i < serverTargets_.size(); i++) {
|
||||
com.google.protobuf.GeneratedMessage.writeString(output, 1, serverTargets_.getRaw(i));
|
||||
}
|
||||
if (clientType_ != io.grpc.testing.ClientType.SYNCHRONOUS_CLIENT.getNumber()) {
|
||||
output.writeEnum(2, clientType_);
|
||||
}
|
||||
if (enableSsl_ != false) {
|
||||
output.writeBool(3, enableSsl_);
|
||||
}
|
||||
if (outstandingRpcsPerChannel_ != 0) {
|
||||
output.writeInt32(4, outstandingRpcsPerChannel_);
|
||||
}
|
||||
if (clientChannels_ != 0) {
|
||||
output.writeInt32(5, clientChannels_);
|
||||
}
|
||||
if (payloadSize_ != 0) {
|
||||
output.writeInt32(6, payloadSize_);
|
||||
}
|
||||
if (asyncClientThreads_ != 0) {
|
||||
output.writeInt32(7, asyncClientThreads_);
|
||||
}
|
||||
if (rpcType_ != io.grpc.testing.RpcType.UNARY.getNumber()) {
|
||||
output.writeEnum(8, rpcType_);
|
||||
}
|
||||
}
|
||||
|
||||
public int getSerializedSize() {
|
||||
int size = memoizedSize;
|
||||
if (size != -1) return size;
|
||||
|
||||
size = 0;
|
||||
{
|
||||
int dataSize = 0;
|
||||
for (int i = 0; i < serverTargets_.size(); i++) {
|
||||
dataSize += computeStringSizeNoTag(serverTargets_.getRaw(i));
|
||||
}
|
||||
size += dataSize;
|
||||
size += 1 * getServerTargetsList().size();
|
||||
}
|
||||
if (clientType_ != io.grpc.testing.ClientType.SYNCHRONOUS_CLIENT.getNumber()) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeEnumSize(2, clientType_);
|
||||
}
|
||||
if (enableSsl_ != false) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeBoolSize(3, enableSsl_);
|
||||
}
|
||||
if (outstandingRpcsPerChannel_ != 0) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeInt32Size(4, outstandingRpcsPerChannel_);
|
||||
}
|
||||
if (clientChannels_ != 0) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeInt32Size(5, clientChannels_);
|
||||
}
|
||||
if (payloadSize_ != 0) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeInt32Size(6, payloadSize_);
|
||||
}
|
||||
if (asyncClientThreads_ != 0) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeInt32Size(7, asyncClientThreads_);
|
||||
}
|
||||
if (rpcType_ != io.grpc.testing.RpcType.UNARY.getNumber()) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeEnumSize(8, rpcType_);
|
||||
}
|
||||
memoizedSize = size;
|
||||
return size;
|
||||
}
|
||||
|
||||
private static final long serialVersionUID = 0L;
|
||||
public static io.grpc.testing.ClientConfig parseFrom(
|
||||
com.google.protobuf.ByteString data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static io.grpc.testing.ClientConfig parseFrom(
|
||||
com.google.protobuf.ByteString data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.ClientConfig parseFrom(byte[] data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static io.grpc.testing.ClientConfig parseFrom(
|
||||
byte[] data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.ClientConfig parseFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.ClientConfig parseFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.ClientConfig parseDelimitedFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseDelimitedFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.ClientConfig parseDelimitedFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseDelimitedFrom(input, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.ClientConfig parseFrom(
|
||||
com.google.protobuf.CodedInputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.ClientConfig parseFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input, extensionRegistry);
|
||||
}
|
||||
|
||||
public Builder newBuilderForType() { return newBuilder(); }
|
||||
public static Builder newBuilder() {
|
||||
return DEFAULT_INSTANCE.toBuilder();
|
||||
}
|
||||
public static Builder newBuilder(io.grpc.testing.ClientConfig prototype) {
|
||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
||||
}
|
||||
public Builder toBuilder() {
|
||||
return this == DEFAULT_INSTANCE
|
||||
? new Builder() : new Builder().mergeFrom(this);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected Builder newBuilderForType(
|
||||
com.google.protobuf.GeneratedMessage.BuilderParent parent) {
|
||||
Builder builder = new Builder(parent);
|
||||
return builder;
|
||||
}
|
||||
/**
|
||||
* Protobuf type {@code grpc.testing.ClientConfig}
|
||||
*/
|
||||
public static final class Builder extends
|
||||
com.google.protobuf.GeneratedMessage.Builder<Builder> implements
|
||||
// @@protoc_insertion_point(builder_implements:grpc.testing.ClientConfig)
|
||||
io.grpc.testing.ClientConfigOrBuilder {
|
||||
public static final com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptor() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ClientConfig_descriptor;
|
||||
}
|
||||
|
||||
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ClientConfig_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
io.grpc.testing.ClientConfig.class, io.grpc.testing.ClientConfig.Builder.class);
|
||||
}
|
||||
|
||||
// Construct using io.grpc.testing.ClientConfig.newBuilder()
|
||||
private Builder() {
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
|
||||
private Builder(
|
||||
com.google.protobuf.GeneratedMessage.BuilderParent parent) {
|
||||
super(parent);
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
private void maybeForceBuilderInitialization() {
|
||||
if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
|
||||
}
|
||||
}
|
||||
public Builder clear() {
|
||||
super.clear();
|
||||
serverTargets_ = com.google.protobuf.LazyStringArrayList.EMPTY;
|
||||
bitField0_ = (bitField0_ & ~0x00000001);
|
||||
clientType_ = 0;
|
||||
|
||||
enableSsl_ = false;
|
||||
|
||||
outstandingRpcsPerChannel_ = 0;
|
||||
|
||||
clientChannels_ = 0;
|
||||
|
||||
payloadSize_ = 0;
|
||||
|
||||
asyncClientThreads_ = 0;
|
||||
|
||||
rpcType_ = 0;
|
||||
|
||||
return this;
|
||||
}
|
||||
|
||||
public com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptorForType() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ClientConfig_descriptor;
|
||||
}
|
||||
|
||||
public io.grpc.testing.ClientConfig getDefaultInstanceForType() {
|
||||
return io.grpc.testing.ClientConfig.getDefaultInstance();
|
||||
}
|
||||
|
||||
public io.grpc.testing.ClientConfig build() {
|
||||
io.grpc.testing.ClientConfig result = buildPartial();
|
||||
if (!result.isInitialized()) {
|
||||
throw newUninitializedMessageException(result);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
public io.grpc.testing.ClientConfig buildPartial() {
|
||||
io.grpc.testing.ClientConfig result = new io.grpc.testing.ClientConfig(this);
|
||||
int from_bitField0_ = bitField0_;
|
||||
int to_bitField0_ = 0;
|
||||
if (((bitField0_ & 0x00000001) == 0x00000001)) {
|
||||
serverTargets_ = serverTargets_.getUnmodifiableView();
|
||||
bitField0_ = (bitField0_ & ~0x00000001);
|
||||
}
|
||||
result.serverTargets_ = serverTargets_;
|
||||
result.clientType_ = clientType_;
|
||||
result.enableSsl_ = enableSsl_;
|
||||
result.outstandingRpcsPerChannel_ = outstandingRpcsPerChannel_;
|
||||
result.clientChannels_ = clientChannels_;
|
||||
result.payloadSize_ = payloadSize_;
|
||||
result.asyncClientThreads_ = asyncClientThreads_;
|
||||
result.rpcType_ = rpcType_;
|
||||
result.bitField0_ = to_bitField0_;
|
||||
onBuilt();
|
||||
return result;
|
||||
}
|
||||
|
||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
||||
if (other instanceof io.grpc.testing.ClientConfig) {
|
||||
return mergeFrom((io.grpc.testing.ClientConfig)other);
|
||||
} else {
|
||||
super.mergeFrom(other);
|
||||
return this;
|
||||
}
|
||||
}
|
||||
|
||||
public Builder mergeFrom(io.grpc.testing.ClientConfig other) {
|
||||
if (other == io.grpc.testing.ClientConfig.getDefaultInstance()) return this;
|
||||
if (!other.serverTargets_.isEmpty()) {
|
||||
if (serverTargets_.isEmpty()) {
|
||||
serverTargets_ = other.serverTargets_;
|
||||
bitField0_ = (bitField0_ & ~0x00000001);
|
||||
} else {
|
||||
ensureServerTargetsIsMutable();
|
||||
serverTargets_.addAll(other.serverTargets_);
|
||||
}
|
||||
onChanged();
|
||||
}
|
||||
if (other.clientType_ != 0) {
|
||||
setClientTypeValue(other.getClientTypeValue());
|
||||
}
|
||||
if (other.getEnableSsl() != false) {
|
||||
setEnableSsl(other.getEnableSsl());
|
||||
}
|
||||
if (other.getOutstandingRpcsPerChannel() != 0) {
|
||||
setOutstandingRpcsPerChannel(other.getOutstandingRpcsPerChannel());
|
||||
}
|
||||
if (other.getClientChannels() != 0) {
|
||||
setClientChannels(other.getClientChannels());
|
||||
}
|
||||
if (other.getPayloadSize() != 0) {
|
||||
setPayloadSize(other.getPayloadSize());
|
||||
}
|
||||
if (other.getAsyncClientThreads() != 0) {
|
||||
setAsyncClientThreads(other.getAsyncClientThreads());
|
||||
}
|
||||
if (other.rpcType_ != 0) {
|
||||
setRpcTypeValue(other.getRpcTypeValue());
|
||||
}
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
public final boolean isInitialized() {
|
||||
return true;
|
||||
}
|
||||
|
||||
public Builder mergeFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
io.grpc.testing.ClientConfig parsedMessage = null;
|
||||
try {
|
||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
parsedMessage = (io.grpc.testing.ClientConfig) e.getUnfinishedMessage();
|
||||
throw e;
|
||||
} finally {
|
||||
if (parsedMessage != null) {
|
||||
mergeFrom(parsedMessage);
|
||||
}
|
||||
}
|
||||
return this;
|
||||
}
|
||||
private int bitField0_;
|
||||
|
||||
private com.google.protobuf.LazyStringList serverTargets_ = com.google.protobuf.LazyStringArrayList.EMPTY;
|
||||
private void ensureServerTargetsIsMutable() {
|
||||
if (!((bitField0_ & 0x00000001) == 0x00000001)) {
|
||||
serverTargets_ = new com.google.protobuf.LazyStringArrayList(serverTargets_);
|
||||
bitField0_ |= 0x00000001;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <code>repeated string server_targets = 1;</code>
|
||||
*/
|
||||
public com.google.protobuf.ProtocolStringList
|
||||
getServerTargetsList() {
|
||||
return serverTargets_.getUnmodifiableView();
|
||||
}
|
||||
/**
|
||||
* <code>repeated string server_targets = 1;</code>
|
||||
*/
|
||||
public int getServerTargetsCount() {
|
||||
return serverTargets_.size();
|
||||
}
|
||||
/**
|
||||
* <code>repeated string server_targets = 1;</code>
|
||||
*/
|
||||
public java.lang.String getServerTargets(int index) {
|
||||
return serverTargets_.get(index);
|
||||
}
|
||||
/**
|
||||
* <code>repeated string server_targets = 1;</code>
|
||||
*/
|
||||
public com.google.protobuf.ByteString
|
||||
getServerTargetsBytes(int index) {
|
||||
return serverTargets_.getByteString(index);
|
||||
}
|
||||
/**
|
||||
* <code>repeated string server_targets = 1;</code>
|
||||
*/
|
||||
public Builder setServerTargets(
|
||||
int index, java.lang.String value) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
ensureServerTargetsIsMutable();
|
||||
serverTargets_.set(index, value);
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>repeated string server_targets = 1;</code>
|
||||
*/
|
||||
public Builder addServerTargets(
|
||||
java.lang.String value) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
ensureServerTargetsIsMutable();
|
||||
serverTargets_.add(value);
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>repeated string server_targets = 1;</code>
|
||||
*/
|
||||
public Builder addAllServerTargets(
|
||||
java.lang.Iterable<java.lang.String> values) {
|
||||
ensureServerTargetsIsMutable();
|
||||
com.google.protobuf.AbstractMessageLite.Builder.addAll(
|
||||
values, serverTargets_);
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>repeated string server_targets = 1;</code>
|
||||
*/
|
||||
public Builder clearServerTargets() {
|
||||
serverTargets_ = com.google.protobuf.LazyStringArrayList.EMPTY;
|
||||
bitField0_ = (bitField0_ & ~0x00000001);
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>repeated string server_targets = 1;</code>
|
||||
*/
|
||||
public Builder addServerTargetsBytes(
|
||||
com.google.protobuf.ByteString value) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
checkByteStringIsUtf8(value);
|
||||
ensureServerTargetsIsMutable();
|
||||
serverTargets_.add(value);
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
private int clientType_ = 0;
|
||||
/**
|
||||
* <code>optional .grpc.testing.ClientType client_type = 2;</code>
|
||||
*/
|
||||
public int getClientTypeValue() {
|
||||
return clientType_;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ClientType client_type = 2;</code>
|
||||
*/
|
||||
public Builder setClientTypeValue(int value) {
|
||||
clientType_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ClientType client_type = 2;</code>
|
||||
*/
|
||||
public io.grpc.testing.ClientType getClientType() {
|
||||
io.grpc.testing.ClientType result = io.grpc.testing.ClientType.valueOf(clientType_);
|
||||
return result == null ? io.grpc.testing.ClientType.UNRECOGNIZED : result;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ClientType client_type = 2;</code>
|
||||
*/
|
||||
public Builder setClientType(io.grpc.testing.ClientType value) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
|
||||
clientType_ = value.getNumber();
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ClientType client_type = 2;</code>
|
||||
*/
|
||||
public Builder clearClientType() {
|
||||
|
||||
clientType_ = 0;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
private boolean enableSsl_ ;
|
||||
/**
|
||||
* <code>optional bool enable_ssl = 3;</code>
|
||||
*/
|
||||
public boolean getEnableSsl() {
|
||||
return enableSsl_;
|
||||
}
|
||||
/**
|
||||
* <code>optional bool enable_ssl = 3;</code>
|
||||
*/
|
||||
public Builder setEnableSsl(boolean value) {
|
||||
|
||||
enableSsl_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional bool enable_ssl = 3;</code>
|
||||
*/
|
||||
public Builder clearEnableSsl() {
|
||||
|
||||
enableSsl_ = false;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
private int outstandingRpcsPerChannel_ ;
|
||||
/**
|
||||
* <code>optional int32 outstanding_rpcs_per_channel = 4;</code>
|
||||
*/
|
||||
public int getOutstandingRpcsPerChannel() {
|
||||
return outstandingRpcsPerChannel_;
|
||||
}
|
||||
/**
|
||||
* <code>optional int32 outstanding_rpcs_per_channel = 4;</code>
|
||||
*/
|
||||
public Builder setOutstandingRpcsPerChannel(int value) {
|
||||
|
||||
outstandingRpcsPerChannel_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional int32 outstanding_rpcs_per_channel = 4;</code>
|
||||
*/
|
||||
public Builder clearOutstandingRpcsPerChannel() {
|
||||
|
||||
outstandingRpcsPerChannel_ = 0;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
private int clientChannels_ ;
|
||||
/**
|
||||
* <code>optional int32 client_channels = 5;</code>
|
||||
*/
|
||||
public int getClientChannels() {
|
||||
return clientChannels_;
|
||||
}
|
||||
/**
|
||||
* <code>optional int32 client_channels = 5;</code>
|
||||
*/
|
||||
public Builder setClientChannels(int value) {
|
||||
|
||||
clientChannels_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional int32 client_channels = 5;</code>
|
||||
*/
|
||||
public Builder clearClientChannels() {
|
||||
|
||||
clientChannels_ = 0;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
private int payloadSize_ ;
|
||||
/**
|
||||
* <code>optional int32 payload_size = 6;</code>
|
||||
*/
|
||||
public int getPayloadSize() {
|
||||
return payloadSize_;
|
||||
}
|
||||
/**
|
||||
* <code>optional int32 payload_size = 6;</code>
|
||||
*/
|
||||
public Builder setPayloadSize(int value) {
|
||||
|
||||
payloadSize_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional int32 payload_size = 6;</code>
|
||||
*/
|
||||
public Builder clearPayloadSize() {
|
||||
|
||||
payloadSize_ = 0;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
private int asyncClientThreads_ ;
|
||||
/**
|
||||
* <code>optional int32 async_client_threads = 7;</code>
|
||||
*
|
||||
* <pre>
|
||||
* only for async client:
|
||||
* </pre>
|
||||
*/
|
||||
public int getAsyncClientThreads() {
|
||||
return asyncClientThreads_;
|
||||
}
|
||||
/**
|
||||
* <code>optional int32 async_client_threads = 7;</code>
|
||||
*
|
||||
* <pre>
|
||||
* only for async client:
|
||||
* </pre>
|
||||
*/
|
||||
public Builder setAsyncClientThreads(int value) {
|
||||
|
||||
asyncClientThreads_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional int32 async_client_threads = 7;</code>
|
||||
*
|
||||
* <pre>
|
||||
* only for async client:
|
||||
* </pre>
|
||||
*/
|
||||
public Builder clearAsyncClientThreads() {
|
||||
|
||||
asyncClientThreads_ = 0;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
private int rpcType_ = 0;
|
||||
/**
|
||||
* <code>optional .grpc.testing.RpcType rpc_type = 8;</code>
|
||||
*/
|
||||
public int getRpcTypeValue() {
|
||||
return rpcType_;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.RpcType rpc_type = 8;</code>
|
||||
*/
|
||||
public Builder setRpcTypeValue(int value) {
|
||||
rpcType_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.RpcType rpc_type = 8;</code>
|
||||
*/
|
||||
public io.grpc.testing.RpcType getRpcType() {
|
||||
io.grpc.testing.RpcType result = io.grpc.testing.RpcType.valueOf(rpcType_);
|
||||
return result == null ? io.grpc.testing.RpcType.UNRECOGNIZED : result;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.RpcType rpc_type = 8;</code>
|
||||
*/
|
||||
public Builder setRpcType(io.grpc.testing.RpcType value) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
|
||||
rpcType_ = value.getNumber();
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.RpcType rpc_type = 8;</code>
|
||||
*/
|
||||
public Builder clearRpcType() {
|
||||
|
||||
rpcType_ = 0;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
public final Builder setUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return this;
|
||||
}
|
||||
|
||||
public final Builder mergeUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return this;
|
||||
}
|
||||
|
||||
|
||||
// @@protoc_insertion_point(builder_scope:grpc.testing.ClientConfig)
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(class_scope:grpc.testing.ClientConfig)
|
||||
private static final io.grpc.testing.ClientConfig DEFAULT_INSTANCE;
|
||||
static {
|
||||
DEFAULT_INSTANCE = new io.grpc.testing.ClientConfig();
|
||||
}
|
||||
|
||||
public static io.grpc.testing.ClientConfig getDefaultInstance() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
private static final com.google.protobuf.Parser<ClientConfig>
|
||||
PARSER = new com.google.protobuf.AbstractParser<ClientConfig>() {
|
||||
public ClientConfig parsePartialFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
try {
|
||||
return new ClientConfig(input, extensionRegistry);
|
||||
} catch (RuntimeException e) {
|
||||
if (e.getCause() instanceof
|
||||
com.google.protobuf.InvalidProtocolBufferException) {
|
||||
throw (com.google.protobuf.InvalidProtocolBufferException)
|
||||
e.getCause();
|
||||
}
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
public static com.google.protobuf.Parser<ClientConfig> parser() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.Parser<ClientConfig> getParserForType() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
public io.grpc.testing.ClientConfig getDefaultInstanceForType() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
|
@ -1,75 +0,0 @@
|
|||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: qpstest.proto
|
||||
|
||||
package io.grpc.testing;
|
||||
|
||||
public interface ClientConfigOrBuilder extends
|
||||
// @@protoc_insertion_point(interface_extends:grpc.testing.ClientConfig)
|
||||
com.google.protobuf.MessageOrBuilder {
|
||||
|
||||
/**
|
||||
* <code>repeated string server_targets = 1;</code>
|
||||
*/
|
||||
com.google.protobuf.ProtocolStringList
|
||||
getServerTargetsList();
|
||||
/**
|
||||
* <code>repeated string server_targets = 1;</code>
|
||||
*/
|
||||
int getServerTargetsCount();
|
||||
/**
|
||||
* <code>repeated string server_targets = 1;</code>
|
||||
*/
|
||||
java.lang.String getServerTargets(int index);
|
||||
/**
|
||||
* <code>repeated string server_targets = 1;</code>
|
||||
*/
|
||||
com.google.protobuf.ByteString
|
||||
getServerTargetsBytes(int index);
|
||||
|
||||
/**
|
||||
* <code>optional .grpc.testing.ClientType client_type = 2;</code>
|
||||
*/
|
||||
int getClientTypeValue();
|
||||
/**
|
||||
* <code>optional .grpc.testing.ClientType client_type = 2;</code>
|
||||
*/
|
||||
io.grpc.testing.ClientType getClientType();
|
||||
|
||||
/**
|
||||
* <code>optional bool enable_ssl = 3;</code>
|
||||
*/
|
||||
boolean getEnableSsl();
|
||||
|
||||
/**
|
||||
* <code>optional int32 outstanding_rpcs_per_channel = 4;</code>
|
||||
*/
|
||||
int getOutstandingRpcsPerChannel();
|
||||
|
||||
/**
|
||||
* <code>optional int32 client_channels = 5;</code>
|
||||
*/
|
||||
int getClientChannels();
|
||||
|
||||
/**
|
||||
* <code>optional int32 payload_size = 6;</code>
|
||||
*/
|
||||
int getPayloadSize();
|
||||
|
||||
/**
|
||||
* <code>optional int32 async_client_threads = 7;</code>
|
||||
*
|
||||
* <pre>
|
||||
* only for async client:
|
||||
* </pre>
|
||||
*/
|
||||
int getAsyncClientThreads();
|
||||
|
||||
/**
|
||||
* <code>optional .grpc.testing.RpcType rpc_type = 8;</code>
|
||||
*/
|
||||
int getRpcTypeValue();
|
||||
/**
|
||||
* <code>optional .grpc.testing.RpcType rpc_type = 8;</code>
|
||||
*/
|
||||
io.grpc.testing.RpcType getRpcType();
|
||||
}
|
||||
|
|
@ -1,651 +0,0 @@
|
|||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: qpstest.proto
|
||||
|
||||
package io.grpc.testing;
|
||||
|
||||
/**
|
||||
* Protobuf type {@code grpc.testing.ClientStats}
|
||||
*/
|
||||
public final class ClientStats extends
|
||||
com.google.protobuf.GeneratedMessage implements
|
||||
// @@protoc_insertion_point(message_implements:grpc.testing.ClientStats)
|
||||
ClientStatsOrBuilder {
|
||||
// Use ClientStats.newBuilder() to construct.
|
||||
private ClientStats(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
|
||||
super(builder);
|
||||
}
|
||||
private ClientStats() {
|
||||
timeElapsed_ = 0D;
|
||||
timeUser_ = 0D;
|
||||
timeSystem_ = 0D;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public final com.google.protobuf.UnknownFieldSet
|
||||
getUnknownFields() {
|
||||
return com.google.protobuf.UnknownFieldSet.getDefaultInstance();
|
||||
}
|
||||
private ClientStats(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry) {
|
||||
this();
|
||||
int mutable_bitField0_ = 0;
|
||||
try {
|
||||
boolean done = false;
|
||||
while (!done) {
|
||||
int tag = input.readTag();
|
||||
switch (tag) {
|
||||
case 0:
|
||||
done = true;
|
||||
break;
|
||||
default: {
|
||||
if (!input.skipField(tag)) {
|
||||
done = true;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case 10: {
|
||||
io.grpc.testing.HistogramData.Builder subBuilder = null;
|
||||
if (latencies_ != null) {
|
||||
subBuilder = latencies_.toBuilder();
|
||||
}
|
||||
latencies_ = input.readMessage(io.grpc.testing.HistogramData.parser(), extensionRegistry);
|
||||
if (subBuilder != null) {
|
||||
subBuilder.mergeFrom(latencies_);
|
||||
latencies_ = subBuilder.buildPartial();
|
||||
}
|
||||
|
||||
break;
|
||||
}
|
||||
case 25: {
|
||||
|
||||
timeElapsed_ = input.readDouble();
|
||||
break;
|
||||
}
|
||||
case 33: {
|
||||
|
||||
timeUser_ = input.readDouble();
|
||||
break;
|
||||
}
|
||||
case 41: {
|
||||
|
||||
timeSystem_ = input.readDouble();
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
throw new RuntimeException(e.setUnfinishedMessage(this));
|
||||
} catch (java.io.IOException e) {
|
||||
throw new RuntimeException(
|
||||
new com.google.protobuf.InvalidProtocolBufferException(
|
||||
e.getMessage()).setUnfinishedMessage(this));
|
||||
} finally {
|
||||
makeExtensionsImmutable();
|
||||
}
|
||||
}
|
||||
public static final com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptor() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ClientStats_descriptor;
|
||||
}
|
||||
|
||||
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ClientStats_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
io.grpc.testing.ClientStats.class, io.grpc.testing.ClientStats.Builder.class);
|
||||
}
|
||||
|
||||
public static final int LATENCIES_FIELD_NUMBER = 1;
|
||||
private io.grpc.testing.HistogramData latencies_;
|
||||
/**
|
||||
* <code>optional .grpc.testing.HistogramData latencies = 1;</code>
|
||||
*/
|
||||
public boolean hasLatencies() {
|
||||
return latencies_ != null;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.HistogramData latencies = 1;</code>
|
||||
*/
|
||||
public io.grpc.testing.HistogramData getLatencies() {
|
||||
return latencies_ == null ? io.grpc.testing.HistogramData.getDefaultInstance() : latencies_;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.HistogramData latencies = 1;</code>
|
||||
*/
|
||||
public io.grpc.testing.HistogramDataOrBuilder getLatenciesOrBuilder() {
|
||||
return getLatencies();
|
||||
}
|
||||
|
||||
public static final int TIME_ELAPSED_FIELD_NUMBER = 3;
|
||||
private double timeElapsed_;
|
||||
/**
|
||||
* <code>optional double time_elapsed = 3;</code>
|
||||
*/
|
||||
public double getTimeElapsed() {
|
||||
return timeElapsed_;
|
||||
}
|
||||
|
||||
public static final int TIME_USER_FIELD_NUMBER = 4;
|
||||
private double timeUser_;
|
||||
/**
|
||||
* <code>optional double time_user = 4;</code>
|
||||
*/
|
||||
public double getTimeUser() {
|
||||
return timeUser_;
|
||||
}
|
||||
|
||||
public static final int TIME_SYSTEM_FIELD_NUMBER = 5;
|
||||
private double timeSystem_;
|
||||
/**
|
||||
* <code>optional double time_system = 5;</code>
|
||||
*/
|
||||
public double getTimeSystem() {
|
||||
return timeSystem_;
|
||||
}
|
||||
|
||||
private byte memoizedIsInitialized = -1;
|
||||
public final boolean isInitialized() {
|
||||
byte isInitialized = memoizedIsInitialized;
|
||||
if (isInitialized == 1) return true;
|
||||
if (isInitialized == 0) return false;
|
||||
|
||||
memoizedIsInitialized = 1;
|
||||
return true;
|
||||
}
|
||||
|
||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
||||
throws java.io.IOException {
|
||||
if (latencies_ != null) {
|
||||
output.writeMessage(1, getLatencies());
|
||||
}
|
||||
if (timeElapsed_ != 0D) {
|
||||
output.writeDouble(3, timeElapsed_);
|
||||
}
|
||||
if (timeUser_ != 0D) {
|
||||
output.writeDouble(4, timeUser_);
|
||||
}
|
||||
if (timeSystem_ != 0D) {
|
||||
output.writeDouble(5, timeSystem_);
|
||||
}
|
||||
}
|
||||
|
||||
public int getSerializedSize() {
|
||||
int size = memoizedSize;
|
||||
if (size != -1) return size;
|
||||
|
||||
size = 0;
|
||||
if (latencies_ != null) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeMessageSize(1, getLatencies());
|
||||
}
|
||||
if (timeElapsed_ != 0D) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeDoubleSize(3, timeElapsed_);
|
||||
}
|
||||
if (timeUser_ != 0D) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeDoubleSize(4, timeUser_);
|
||||
}
|
||||
if (timeSystem_ != 0D) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeDoubleSize(5, timeSystem_);
|
||||
}
|
||||
memoizedSize = size;
|
||||
return size;
|
||||
}
|
||||
|
||||
private static final long serialVersionUID = 0L;
|
||||
public static io.grpc.testing.ClientStats parseFrom(
|
||||
com.google.protobuf.ByteString data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static io.grpc.testing.ClientStats parseFrom(
|
||||
com.google.protobuf.ByteString data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.ClientStats parseFrom(byte[] data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static io.grpc.testing.ClientStats parseFrom(
|
||||
byte[] data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.ClientStats parseFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.ClientStats parseFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.ClientStats parseDelimitedFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseDelimitedFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.ClientStats parseDelimitedFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseDelimitedFrom(input, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.ClientStats parseFrom(
|
||||
com.google.protobuf.CodedInputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.ClientStats parseFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input, extensionRegistry);
|
||||
}
|
||||
|
||||
public Builder newBuilderForType() { return newBuilder(); }
|
||||
public static Builder newBuilder() {
|
||||
return DEFAULT_INSTANCE.toBuilder();
|
||||
}
|
||||
public static Builder newBuilder(io.grpc.testing.ClientStats prototype) {
|
||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
||||
}
|
||||
public Builder toBuilder() {
|
||||
return this == DEFAULT_INSTANCE
|
||||
? new Builder() : new Builder().mergeFrom(this);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected Builder newBuilderForType(
|
||||
com.google.protobuf.GeneratedMessage.BuilderParent parent) {
|
||||
Builder builder = new Builder(parent);
|
||||
return builder;
|
||||
}
|
||||
/**
|
||||
* Protobuf type {@code grpc.testing.ClientStats}
|
||||
*/
|
||||
public static final class Builder extends
|
||||
com.google.protobuf.GeneratedMessage.Builder<Builder> implements
|
||||
// @@protoc_insertion_point(builder_implements:grpc.testing.ClientStats)
|
||||
io.grpc.testing.ClientStatsOrBuilder {
|
||||
public static final com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptor() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ClientStats_descriptor;
|
||||
}
|
||||
|
||||
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ClientStats_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
io.grpc.testing.ClientStats.class, io.grpc.testing.ClientStats.Builder.class);
|
||||
}
|
||||
|
||||
// Construct using io.grpc.testing.ClientStats.newBuilder()
|
||||
private Builder() {
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
|
||||
private Builder(
|
||||
com.google.protobuf.GeneratedMessage.BuilderParent parent) {
|
||||
super(parent);
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
private void maybeForceBuilderInitialization() {
|
||||
if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
|
||||
}
|
||||
}
|
||||
public Builder clear() {
|
||||
super.clear();
|
||||
if (latenciesBuilder_ == null) {
|
||||
latencies_ = null;
|
||||
} else {
|
||||
latencies_ = null;
|
||||
latenciesBuilder_ = null;
|
||||
}
|
||||
timeElapsed_ = 0D;
|
||||
|
||||
timeUser_ = 0D;
|
||||
|
||||
timeSystem_ = 0D;
|
||||
|
||||
return this;
|
||||
}
|
||||
|
||||
public com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptorForType() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ClientStats_descriptor;
|
||||
}
|
||||
|
||||
public io.grpc.testing.ClientStats getDefaultInstanceForType() {
|
||||
return io.grpc.testing.ClientStats.getDefaultInstance();
|
||||
}
|
||||
|
||||
public io.grpc.testing.ClientStats build() {
|
||||
io.grpc.testing.ClientStats result = buildPartial();
|
||||
if (!result.isInitialized()) {
|
||||
throw newUninitializedMessageException(result);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
public io.grpc.testing.ClientStats buildPartial() {
|
||||
io.grpc.testing.ClientStats result = new io.grpc.testing.ClientStats(this);
|
||||
if (latenciesBuilder_ == null) {
|
||||
result.latencies_ = latencies_;
|
||||
} else {
|
||||
result.latencies_ = latenciesBuilder_.build();
|
||||
}
|
||||
result.timeElapsed_ = timeElapsed_;
|
||||
result.timeUser_ = timeUser_;
|
||||
result.timeSystem_ = timeSystem_;
|
||||
onBuilt();
|
||||
return result;
|
||||
}
|
||||
|
||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
||||
if (other instanceof io.grpc.testing.ClientStats) {
|
||||
return mergeFrom((io.grpc.testing.ClientStats)other);
|
||||
} else {
|
||||
super.mergeFrom(other);
|
||||
return this;
|
||||
}
|
||||
}
|
||||
|
||||
public Builder mergeFrom(io.grpc.testing.ClientStats other) {
|
||||
if (other == io.grpc.testing.ClientStats.getDefaultInstance()) return this;
|
||||
if (other.hasLatencies()) {
|
||||
mergeLatencies(other.getLatencies());
|
||||
}
|
||||
if (other.getTimeElapsed() != 0D) {
|
||||
setTimeElapsed(other.getTimeElapsed());
|
||||
}
|
||||
if (other.getTimeUser() != 0D) {
|
||||
setTimeUser(other.getTimeUser());
|
||||
}
|
||||
if (other.getTimeSystem() != 0D) {
|
||||
setTimeSystem(other.getTimeSystem());
|
||||
}
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
public final boolean isInitialized() {
|
||||
return true;
|
||||
}
|
||||
|
||||
public Builder mergeFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
io.grpc.testing.ClientStats parsedMessage = null;
|
||||
try {
|
||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
parsedMessage = (io.grpc.testing.ClientStats) e.getUnfinishedMessage();
|
||||
throw e;
|
||||
} finally {
|
||||
if (parsedMessage != null) {
|
||||
mergeFrom(parsedMessage);
|
||||
}
|
||||
}
|
||||
return this;
|
||||
}
|
||||
|
||||
private io.grpc.testing.HistogramData latencies_ = null;
|
||||
private com.google.protobuf.SingleFieldBuilder<
|
||||
io.grpc.testing.HistogramData, io.grpc.testing.HistogramData.Builder, io.grpc.testing.HistogramDataOrBuilder> latenciesBuilder_;
|
||||
/**
|
||||
* <code>optional .grpc.testing.HistogramData latencies = 1;</code>
|
||||
*/
|
||||
public boolean hasLatencies() {
|
||||
return latenciesBuilder_ != null || latencies_ != null;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.HistogramData latencies = 1;</code>
|
||||
*/
|
||||
public io.grpc.testing.HistogramData getLatencies() {
|
||||
if (latenciesBuilder_ == null) {
|
||||
return latencies_ == null ? io.grpc.testing.HistogramData.getDefaultInstance() : latencies_;
|
||||
} else {
|
||||
return latenciesBuilder_.getMessage();
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.HistogramData latencies = 1;</code>
|
||||
*/
|
||||
public Builder setLatencies(io.grpc.testing.HistogramData value) {
|
||||
if (latenciesBuilder_ == null) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
latencies_ = value;
|
||||
onChanged();
|
||||
} else {
|
||||
latenciesBuilder_.setMessage(value);
|
||||
}
|
||||
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.HistogramData latencies = 1;</code>
|
||||
*/
|
||||
public Builder setLatencies(
|
||||
io.grpc.testing.HistogramData.Builder builderForValue) {
|
||||
if (latenciesBuilder_ == null) {
|
||||
latencies_ = builderForValue.build();
|
||||
onChanged();
|
||||
} else {
|
||||
latenciesBuilder_.setMessage(builderForValue.build());
|
||||
}
|
||||
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.HistogramData latencies = 1;</code>
|
||||
*/
|
||||
public Builder mergeLatencies(io.grpc.testing.HistogramData value) {
|
||||
if (latenciesBuilder_ == null) {
|
||||
if (latencies_ != null) {
|
||||
latencies_ =
|
||||
io.grpc.testing.HistogramData.newBuilder(latencies_).mergeFrom(value).buildPartial();
|
||||
} else {
|
||||
latencies_ = value;
|
||||
}
|
||||
onChanged();
|
||||
} else {
|
||||
latenciesBuilder_.mergeFrom(value);
|
||||
}
|
||||
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.HistogramData latencies = 1;</code>
|
||||
*/
|
||||
public Builder clearLatencies() {
|
||||
if (latenciesBuilder_ == null) {
|
||||
latencies_ = null;
|
||||
onChanged();
|
||||
} else {
|
||||
latencies_ = null;
|
||||
latenciesBuilder_ = null;
|
||||
}
|
||||
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.HistogramData latencies = 1;</code>
|
||||
*/
|
||||
public io.grpc.testing.HistogramData.Builder getLatenciesBuilder() {
|
||||
|
||||
onChanged();
|
||||
return getLatenciesFieldBuilder().getBuilder();
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.HistogramData latencies = 1;</code>
|
||||
*/
|
||||
public io.grpc.testing.HistogramDataOrBuilder getLatenciesOrBuilder() {
|
||||
if (latenciesBuilder_ != null) {
|
||||
return latenciesBuilder_.getMessageOrBuilder();
|
||||
} else {
|
||||
return latencies_ == null ?
|
||||
io.grpc.testing.HistogramData.getDefaultInstance() : latencies_;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.HistogramData latencies = 1;</code>
|
||||
*/
|
||||
private com.google.protobuf.SingleFieldBuilder<
|
||||
io.grpc.testing.HistogramData, io.grpc.testing.HistogramData.Builder, io.grpc.testing.HistogramDataOrBuilder>
|
||||
getLatenciesFieldBuilder() {
|
||||
if (latenciesBuilder_ == null) {
|
||||
latenciesBuilder_ = new com.google.protobuf.SingleFieldBuilder<
|
||||
io.grpc.testing.HistogramData, io.grpc.testing.HistogramData.Builder, io.grpc.testing.HistogramDataOrBuilder>(
|
||||
getLatencies(),
|
||||
getParentForChildren(),
|
||||
isClean());
|
||||
latencies_ = null;
|
||||
}
|
||||
return latenciesBuilder_;
|
||||
}
|
||||
|
||||
private double timeElapsed_ ;
|
||||
/**
|
||||
* <code>optional double time_elapsed = 3;</code>
|
||||
*/
|
||||
public double getTimeElapsed() {
|
||||
return timeElapsed_;
|
||||
}
|
||||
/**
|
||||
* <code>optional double time_elapsed = 3;</code>
|
||||
*/
|
||||
public Builder setTimeElapsed(double value) {
|
||||
|
||||
timeElapsed_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional double time_elapsed = 3;</code>
|
||||
*/
|
||||
public Builder clearTimeElapsed() {
|
||||
|
||||
timeElapsed_ = 0D;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
private double timeUser_ ;
|
||||
/**
|
||||
* <code>optional double time_user = 4;</code>
|
||||
*/
|
||||
public double getTimeUser() {
|
||||
return timeUser_;
|
||||
}
|
||||
/**
|
||||
* <code>optional double time_user = 4;</code>
|
||||
*/
|
||||
public Builder setTimeUser(double value) {
|
||||
|
||||
timeUser_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional double time_user = 4;</code>
|
||||
*/
|
||||
public Builder clearTimeUser() {
|
||||
|
||||
timeUser_ = 0D;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
private double timeSystem_ ;
|
||||
/**
|
||||
* <code>optional double time_system = 5;</code>
|
||||
*/
|
||||
public double getTimeSystem() {
|
||||
return timeSystem_;
|
||||
}
|
||||
/**
|
||||
* <code>optional double time_system = 5;</code>
|
||||
*/
|
||||
public Builder setTimeSystem(double value) {
|
||||
|
||||
timeSystem_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional double time_system = 5;</code>
|
||||
*/
|
||||
public Builder clearTimeSystem() {
|
||||
|
||||
timeSystem_ = 0D;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
public final Builder setUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return this;
|
||||
}
|
||||
|
||||
public final Builder mergeUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return this;
|
||||
}
|
||||
|
||||
|
||||
// @@protoc_insertion_point(builder_scope:grpc.testing.ClientStats)
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(class_scope:grpc.testing.ClientStats)
|
||||
private static final io.grpc.testing.ClientStats DEFAULT_INSTANCE;
|
||||
static {
|
||||
DEFAULT_INSTANCE = new io.grpc.testing.ClientStats();
|
||||
}
|
||||
|
||||
public static io.grpc.testing.ClientStats getDefaultInstance() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
private static final com.google.protobuf.Parser<ClientStats>
|
||||
PARSER = new com.google.protobuf.AbstractParser<ClientStats>() {
|
||||
public ClientStats parsePartialFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
try {
|
||||
return new ClientStats(input, extensionRegistry);
|
||||
} catch (RuntimeException e) {
|
||||
if (e.getCause() instanceof
|
||||
com.google.protobuf.InvalidProtocolBufferException) {
|
||||
throw (com.google.protobuf.InvalidProtocolBufferException)
|
||||
e.getCause();
|
||||
}
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
public static com.google.protobuf.Parser<ClientStats> parser() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.Parser<ClientStats> getParserForType() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
public io.grpc.testing.ClientStats getDefaultInstanceForType() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
|
@ -1,37 +0,0 @@
|
|||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: qpstest.proto
|
||||
|
||||
package io.grpc.testing;
|
||||
|
||||
public interface ClientStatsOrBuilder extends
|
||||
// @@protoc_insertion_point(interface_extends:grpc.testing.ClientStats)
|
||||
com.google.protobuf.MessageOrBuilder {
|
||||
|
||||
/**
|
||||
* <code>optional .grpc.testing.HistogramData latencies = 1;</code>
|
||||
*/
|
||||
boolean hasLatencies();
|
||||
/**
|
||||
* <code>optional .grpc.testing.HistogramData latencies = 1;</code>
|
||||
*/
|
||||
io.grpc.testing.HistogramData getLatencies();
|
||||
/**
|
||||
* <code>optional .grpc.testing.HistogramData latencies = 1;</code>
|
||||
*/
|
||||
io.grpc.testing.HistogramDataOrBuilder getLatenciesOrBuilder();
|
||||
|
||||
/**
|
||||
* <code>optional double time_elapsed = 3;</code>
|
||||
*/
|
||||
double getTimeElapsed();
|
||||
|
||||
/**
|
||||
* <code>optional double time_user = 4;</code>
|
||||
*/
|
||||
double getTimeUser();
|
||||
|
||||
/**
|
||||
* <code>optional double time_system = 5;</code>
|
||||
*/
|
||||
double getTimeSystem();
|
||||
}
|
||||
|
|
@ -1,489 +0,0 @@
|
|||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: qpstest.proto
|
||||
|
||||
package io.grpc.testing;
|
||||
|
||||
/**
|
||||
* Protobuf type {@code grpc.testing.ClientStatus}
|
||||
*/
|
||||
public final class ClientStatus extends
|
||||
com.google.protobuf.GeneratedMessage implements
|
||||
// @@protoc_insertion_point(message_implements:grpc.testing.ClientStatus)
|
||||
ClientStatusOrBuilder {
|
||||
// Use ClientStatus.newBuilder() to construct.
|
||||
private ClientStatus(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
|
||||
super(builder);
|
||||
}
|
||||
private ClientStatus() {
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public final com.google.protobuf.UnknownFieldSet
|
||||
getUnknownFields() {
|
||||
return com.google.protobuf.UnknownFieldSet.getDefaultInstance();
|
||||
}
|
||||
private ClientStatus(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry) {
|
||||
this();
|
||||
int mutable_bitField0_ = 0;
|
||||
try {
|
||||
boolean done = false;
|
||||
while (!done) {
|
||||
int tag = input.readTag();
|
||||
switch (tag) {
|
||||
case 0:
|
||||
done = true;
|
||||
break;
|
||||
default: {
|
||||
if (!input.skipField(tag)) {
|
||||
done = true;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case 10: {
|
||||
io.grpc.testing.ClientStats.Builder subBuilder = null;
|
||||
if (stats_ != null) {
|
||||
subBuilder = stats_.toBuilder();
|
||||
}
|
||||
stats_ = input.readMessage(io.grpc.testing.ClientStats.parser(), extensionRegistry);
|
||||
if (subBuilder != null) {
|
||||
subBuilder.mergeFrom(stats_);
|
||||
stats_ = subBuilder.buildPartial();
|
||||
}
|
||||
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
throw new RuntimeException(e.setUnfinishedMessage(this));
|
||||
} catch (java.io.IOException e) {
|
||||
throw new RuntimeException(
|
||||
new com.google.protobuf.InvalidProtocolBufferException(
|
||||
e.getMessage()).setUnfinishedMessage(this));
|
||||
} finally {
|
||||
makeExtensionsImmutable();
|
||||
}
|
||||
}
|
||||
public static final com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptor() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ClientStatus_descriptor;
|
||||
}
|
||||
|
||||
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ClientStatus_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
io.grpc.testing.ClientStatus.class, io.grpc.testing.ClientStatus.Builder.class);
|
||||
}
|
||||
|
||||
public static final int STATS_FIELD_NUMBER = 1;
|
||||
private io.grpc.testing.ClientStats stats_;
|
||||
/**
|
||||
* <code>optional .grpc.testing.ClientStats stats = 1;</code>
|
||||
*/
|
||||
public boolean hasStats() {
|
||||
return stats_ != null;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ClientStats stats = 1;</code>
|
||||
*/
|
||||
public io.grpc.testing.ClientStats getStats() {
|
||||
return stats_ == null ? io.grpc.testing.ClientStats.getDefaultInstance() : stats_;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ClientStats stats = 1;</code>
|
||||
*/
|
||||
public io.grpc.testing.ClientStatsOrBuilder getStatsOrBuilder() {
|
||||
return getStats();
|
||||
}
|
||||
|
||||
private byte memoizedIsInitialized = -1;
|
||||
public final boolean isInitialized() {
|
||||
byte isInitialized = memoizedIsInitialized;
|
||||
if (isInitialized == 1) return true;
|
||||
if (isInitialized == 0) return false;
|
||||
|
||||
memoizedIsInitialized = 1;
|
||||
return true;
|
||||
}
|
||||
|
||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
||||
throws java.io.IOException {
|
||||
if (stats_ != null) {
|
||||
output.writeMessage(1, getStats());
|
||||
}
|
||||
}
|
||||
|
||||
public int getSerializedSize() {
|
||||
int size = memoizedSize;
|
||||
if (size != -1) return size;
|
||||
|
||||
size = 0;
|
||||
if (stats_ != null) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeMessageSize(1, getStats());
|
||||
}
|
||||
memoizedSize = size;
|
||||
return size;
|
||||
}
|
||||
|
||||
private static final long serialVersionUID = 0L;
|
||||
public static io.grpc.testing.ClientStatus parseFrom(
|
||||
com.google.protobuf.ByteString data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static io.grpc.testing.ClientStatus parseFrom(
|
||||
com.google.protobuf.ByteString data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.ClientStatus parseFrom(byte[] data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static io.grpc.testing.ClientStatus parseFrom(
|
||||
byte[] data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.ClientStatus parseFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.ClientStatus parseFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.ClientStatus parseDelimitedFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseDelimitedFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.ClientStatus parseDelimitedFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseDelimitedFrom(input, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.ClientStatus parseFrom(
|
||||
com.google.protobuf.CodedInputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.ClientStatus parseFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input, extensionRegistry);
|
||||
}
|
||||
|
||||
public Builder newBuilderForType() { return newBuilder(); }
|
||||
public static Builder newBuilder() {
|
||||
return DEFAULT_INSTANCE.toBuilder();
|
||||
}
|
||||
public static Builder newBuilder(io.grpc.testing.ClientStatus prototype) {
|
||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
||||
}
|
||||
public Builder toBuilder() {
|
||||
return this == DEFAULT_INSTANCE
|
||||
? new Builder() : new Builder().mergeFrom(this);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected Builder newBuilderForType(
|
||||
com.google.protobuf.GeneratedMessage.BuilderParent parent) {
|
||||
Builder builder = new Builder(parent);
|
||||
return builder;
|
||||
}
|
||||
/**
|
||||
* Protobuf type {@code grpc.testing.ClientStatus}
|
||||
*/
|
||||
public static final class Builder extends
|
||||
com.google.protobuf.GeneratedMessage.Builder<Builder> implements
|
||||
// @@protoc_insertion_point(builder_implements:grpc.testing.ClientStatus)
|
||||
io.grpc.testing.ClientStatusOrBuilder {
|
||||
public static final com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptor() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ClientStatus_descriptor;
|
||||
}
|
||||
|
||||
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ClientStatus_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
io.grpc.testing.ClientStatus.class, io.grpc.testing.ClientStatus.Builder.class);
|
||||
}
|
||||
|
||||
// Construct using io.grpc.testing.ClientStatus.newBuilder()
|
||||
private Builder() {
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
|
||||
private Builder(
|
||||
com.google.protobuf.GeneratedMessage.BuilderParent parent) {
|
||||
super(parent);
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
private void maybeForceBuilderInitialization() {
|
||||
if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
|
||||
}
|
||||
}
|
||||
public Builder clear() {
|
||||
super.clear();
|
||||
if (statsBuilder_ == null) {
|
||||
stats_ = null;
|
||||
} else {
|
||||
stats_ = null;
|
||||
statsBuilder_ = null;
|
||||
}
|
||||
return this;
|
||||
}
|
||||
|
||||
public com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptorForType() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ClientStatus_descriptor;
|
||||
}
|
||||
|
||||
public io.grpc.testing.ClientStatus getDefaultInstanceForType() {
|
||||
return io.grpc.testing.ClientStatus.getDefaultInstance();
|
||||
}
|
||||
|
||||
public io.grpc.testing.ClientStatus build() {
|
||||
io.grpc.testing.ClientStatus result = buildPartial();
|
||||
if (!result.isInitialized()) {
|
||||
throw newUninitializedMessageException(result);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
public io.grpc.testing.ClientStatus buildPartial() {
|
||||
io.grpc.testing.ClientStatus result = new io.grpc.testing.ClientStatus(this);
|
||||
if (statsBuilder_ == null) {
|
||||
result.stats_ = stats_;
|
||||
} else {
|
||||
result.stats_ = statsBuilder_.build();
|
||||
}
|
||||
onBuilt();
|
||||
return result;
|
||||
}
|
||||
|
||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
||||
if (other instanceof io.grpc.testing.ClientStatus) {
|
||||
return mergeFrom((io.grpc.testing.ClientStatus)other);
|
||||
} else {
|
||||
super.mergeFrom(other);
|
||||
return this;
|
||||
}
|
||||
}
|
||||
|
||||
public Builder mergeFrom(io.grpc.testing.ClientStatus other) {
|
||||
if (other == io.grpc.testing.ClientStatus.getDefaultInstance()) return this;
|
||||
if (other.hasStats()) {
|
||||
mergeStats(other.getStats());
|
||||
}
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
public final boolean isInitialized() {
|
||||
return true;
|
||||
}
|
||||
|
||||
public Builder mergeFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
io.grpc.testing.ClientStatus parsedMessage = null;
|
||||
try {
|
||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
parsedMessage = (io.grpc.testing.ClientStatus) e.getUnfinishedMessage();
|
||||
throw e;
|
||||
} finally {
|
||||
if (parsedMessage != null) {
|
||||
mergeFrom(parsedMessage);
|
||||
}
|
||||
}
|
||||
return this;
|
||||
}
|
||||
|
||||
private io.grpc.testing.ClientStats stats_ = null;
|
||||
private com.google.protobuf.SingleFieldBuilder<
|
||||
io.grpc.testing.ClientStats, io.grpc.testing.ClientStats.Builder, io.grpc.testing.ClientStatsOrBuilder> statsBuilder_;
|
||||
/**
|
||||
* <code>optional .grpc.testing.ClientStats stats = 1;</code>
|
||||
*/
|
||||
public boolean hasStats() {
|
||||
return statsBuilder_ != null || stats_ != null;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ClientStats stats = 1;</code>
|
||||
*/
|
||||
public io.grpc.testing.ClientStats getStats() {
|
||||
if (statsBuilder_ == null) {
|
||||
return stats_ == null ? io.grpc.testing.ClientStats.getDefaultInstance() : stats_;
|
||||
} else {
|
||||
return statsBuilder_.getMessage();
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ClientStats stats = 1;</code>
|
||||
*/
|
||||
public Builder setStats(io.grpc.testing.ClientStats value) {
|
||||
if (statsBuilder_ == null) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
stats_ = value;
|
||||
onChanged();
|
||||
} else {
|
||||
statsBuilder_.setMessage(value);
|
||||
}
|
||||
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ClientStats stats = 1;</code>
|
||||
*/
|
||||
public Builder setStats(
|
||||
io.grpc.testing.ClientStats.Builder builderForValue) {
|
||||
if (statsBuilder_ == null) {
|
||||
stats_ = builderForValue.build();
|
||||
onChanged();
|
||||
} else {
|
||||
statsBuilder_.setMessage(builderForValue.build());
|
||||
}
|
||||
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ClientStats stats = 1;</code>
|
||||
*/
|
||||
public Builder mergeStats(io.grpc.testing.ClientStats value) {
|
||||
if (statsBuilder_ == null) {
|
||||
if (stats_ != null) {
|
||||
stats_ =
|
||||
io.grpc.testing.ClientStats.newBuilder(stats_).mergeFrom(value).buildPartial();
|
||||
} else {
|
||||
stats_ = value;
|
||||
}
|
||||
onChanged();
|
||||
} else {
|
||||
statsBuilder_.mergeFrom(value);
|
||||
}
|
||||
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ClientStats stats = 1;</code>
|
||||
*/
|
||||
public Builder clearStats() {
|
||||
if (statsBuilder_ == null) {
|
||||
stats_ = null;
|
||||
onChanged();
|
||||
} else {
|
||||
stats_ = null;
|
||||
statsBuilder_ = null;
|
||||
}
|
||||
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ClientStats stats = 1;</code>
|
||||
*/
|
||||
public io.grpc.testing.ClientStats.Builder getStatsBuilder() {
|
||||
|
||||
onChanged();
|
||||
return getStatsFieldBuilder().getBuilder();
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ClientStats stats = 1;</code>
|
||||
*/
|
||||
public io.grpc.testing.ClientStatsOrBuilder getStatsOrBuilder() {
|
||||
if (statsBuilder_ != null) {
|
||||
return statsBuilder_.getMessageOrBuilder();
|
||||
} else {
|
||||
return stats_ == null ?
|
||||
io.grpc.testing.ClientStats.getDefaultInstance() : stats_;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ClientStats stats = 1;</code>
|
||||
*/
|
||||
private com.google.protobuf.SingleFieldBuilder<
|
||||
io.grpc.testing.ClientStats, io.grpc.testing.ClientStats.Builder, io.grpc.testing.ClientStatsOrBuilder>
|
||||
getStatsFieldBuilder() {
|
||||
if (statsBuilder_ == null) {
|
||||
statsBuilder_ = new com.google.protobuf.SingleFieldBuilder<
|
||||
io.grpc.testing.ClientStats, io.grpc.testing.ClientStats.Builder, io.grpc.testing.ClientStatsOrBuilder>(
|
||||
getStats(),
|
||||
getParentForChildren(),
|
||||
isClean());
|
||||
stats_ = null;
|
||||
}
|
||||
return statsBuilder_;
|
||||
}
|
||||
public final Builder setUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return this;
|
||||
}
|
||||
|
||||
public final Builder mergeUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return this;
|
||||
}
|
||||
|
||||
|
||||
// @@protoc_insertion_point(builder_scope:grpc.testing.ClientStatus)
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(class_scope:grpc.testing.ClientStatus)
|
||||
private static final io.grpc.testing.ClientStatus DEFAULT_INSTANCE;
|
||||
static {
|
||||
DEFAULT_INSTANCE = new io.grpc.testing.ClientStatus();
|
||||
}
|
||||
|
||||
public static io.grpc.testing.ClientStatus getDefaultInstance() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
private static final com.google.protobuf.Parser<ClientStatus>
|
||||
PARSER = new com.google.protobuf.AbstractParser<ClientStatus>() {
|
||||
public ClientStatus parsePartialFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
try {
|
||||
return new ClientStatus(input, extensionRegistry);
|
||||
} catch (RuntimeException e) {
|
||||
if (e.getCause() instanceof
|
||||
com.google.protobuf.InvalidProtocolBufferException) {
|
||||
throw (com.google.protobuf.InvalidProtocolBufferException)
|
||||
e.getCause();
|
||||
}
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
public static com.google.protobuf.Parser<ClientStatus> parser() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.Parser<ClientStatus> getParserForType() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
public io.grpc.testing.ClientStatus getDefaultInstanceForType() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
|
@ -1,22 +0,0 @@
|
|||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: qpstest.proto
|
||||
|
||||
package io.grpc.testing;
|
||||
|
||||
public interface ClientStatusOrBuilder extends
|
||||
// @@protoc_insertion_point(interface_extends:grpc.testing.ClientStatus)
|
||||
com.google.protobuf.MessageOrBuilder {
|
||||
|
||||
/**
|
||||
* <code>optional .grpc.testing.ClientStats stats = 1;</code>
|
||||
*/
|
||||
boolean hasStats();
|
||||
/**
|
||||
* <code>optional .grpc.testing.ClientStats stats = 1;</code>
|
||||
*/
|
||||
io.grpc.testing.ClientStats getStats();
|
||||
/**
|
||||
* <code>optional .grpc.testing.ClientStats stats = 1;</code>
|
||||
*/
|
||||
io.grpc.testing.ClientStatsOrBuilder getStatsOrBuilder();
|
||||
}
|
||||
|
|
@ -1,98 +0,0 @@
|
|||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: qpstest.proto
|
||||
|
||||
package io.grpc.testing;
|
||||
|
||||
/**
|
||||
* Protobuf enum {@code grpc.testing.ClientType}
|
||||
*/
|
||||
public enum ClientType
|
||||
implements com.google.protobuf.ProtocolMessageEnum {
|
||||
/**
|
||||
* <code>SYNCHRONOUS_CLIENT = 0;</code>
|
||||
*/
|
||||
SYNCHRONOUS_CLIENT(0, 0),
|
||||
/**
|
||||
* <code>ASYNC_CLIENT = 1;</code>
|
||||
*/
|
||||
ASYNC_CLIENT(1, 1),
|
||||
UNRECOGNIZED(-1, -1),
|
||||
;
|
||||
|
||||
/**
|
||||
* <code>SYNCHRONOUS_CLIENT = 0;</code>
|
||||
*/
|
||||
public static final int SYNCHRONOUS_CLIENT_VALUE = 0;
|
||||
/**
|
||||
* <code>ASYNC_CLIENT = 1;</code>
|
||||
*/
|
||||
public static final int ASYNC_CLIENT_VALUE = 1;
|
||||
|
||||
|
||||
public final int getNumber() {
|
||||
if (index == -1) {
|
||||
throw new java.lang.IllegalArgumentException(
|
||||
"Can't get the number of an unknown enum value.");
|
||||
}
|
||||
return value;
|
||||
}
|
||||
|
||||
public static ClientType valueOf(int value) {
|
||||
switch (value) {
|
||||
case 0: return SYNCHRONOUS_CLIENT;
|
||||
case 1: return ASYNC_CLIENT;
|
||||
default: return null;
|
||||
}
|
||||
}
|
||||
|
||||
public static com.google.protobuf.Internal.EnumLiteMap<ClientType>
|
||||
internalGetValueMap() {
|
||||
return internalValueMap;
|
||||
}
|
||||
private static final com.google.protobuf.Internal.EnumLiteMap<
|
||||
ClientType> internalValueMap =
|
||||
new com.google.protobuf.Internal.EnumLiteMap<ClientType>() {
|
||||
public ClientType findValueByNumber(int number) {
|
||||
return ClientType.valueOf(number);
|
||||
}
|
||||
};
|
||||
|
||||
public final com.google.protobuf.Descriptors.EnumValueDescriptor
|
||||
getValueDescriptor() {
|
||||
return getDescriptor().getValues().get(index);
|
||||
}
|
||||
public final com.google.protobuf.Descriptors.EnumDescriptor
|
||||
getDescriptorForType() {
|
||||
return getDescriptor();
|
||||
}
|
||||
public static final com.google.protobuf.Descriptors.EnumDescriptor
|
||||
getDescriptor() {
|
||||
return io.grpc.testing.QpsTestProto.getDescriptor()
|
||||
.getEnumTypes().get(1);
|
||||
}
|
||||
|
||||
private static final ClientType[] VALUES = values();
|
||||
|
||||
public static ClientType valueOf(
|
||||
com.google.protobuf.Descriptors.EnumValueDescriptor desc) {
|
||||
if (desc.getType() != getDescriptor()) {
|
||||
throw new java.lang.IllegalArgumentException(
|
||||
"EnumValueDescriptor is not for this type.");
|
||||
}
|
||||
if (desc.getIndex() == -1) {
|
||||
return UNRECOGNIZED;
|
||||
}
|
||||
return VALUES[desc.getIndex()];
|
||||
}
|
||||
|
||||
private final int index;
|
||||
private final int value;
|
||||
|
||||
private ClientType(int index, int value) {
|
||||
this.index = index;
|
||||
this.value = value;
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(enum_scope:grpc.testing.ClientType)
|
||||
}
|
||||
|
||||
|
|
@ -1,745 +0,0 @@
|
|||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: qpstest.proto
|
||||
|
||||
package io.grpc.testing;
|
||||
|
||||
/**
|
||||
* Protobuf type {@code grpc.testing.HistogramData}
|
||||
*/
|
||||
public final class HistogramData extends
|
||||
com.google.protobuf.GeneratedMessage implements
|
||||
// @@protoc_insertion_point(message_implements:grpc.testing.HistogramData)
|
||||
HistogramDataOrBuilder {
|
||||
// Use HistogramData.newBuilder() to construct.
|
||||
private HistogramData(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
|
||||
super(builder);
|
||||
}
|
||||
private HistogramData() {
|
||||
bucket_ = java.util.Collections.emptyList();
|
||||
minSeen_ = 0D;
|
||||
maxSeen_ = 0D;
|
||||
sum_ = 0D;
|
||||
sumOfSquares_ = 0D;
|
||||
count_ = 0D;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public final com.google.protobuf.UnknownFieldSet
|
||||
getUnknownFields() {
|
||||
return com.google.protobuf.UnknownFieldSet.getDefaultInstance();
|
||||
}
|
||||
private HistogramData(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry) {
|
||||
this();
|
||||
int mutable_bitField0_ = 0;
|
||||
try {
|
||||
boolean done = false;
|
||||
while (!done) {
|
||||
int tag = input.readTag();
|
||||
switch (tag) {
|
||||
case 0:
|
||||
done = true;
|
||||
break;
|
||||
default: {
|
||||
if (!input.skipField(tag)) {
|
||||
done = true;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case 8: {
|
||||
if (!((mutable_bitField0_ & 0x00000001) == 0x00000001)) {
|
||||
bucket_ = new java.util.ArrayList<java.lang.Integer>();
|
||||
mutable_bitField0_ |= 0x00000001;
|
||||
}
|
||||
bucket_.add(input.readUInt32());
|
||||
break;
|
||||
}
|
||||
case 10: {
|
||||
int length = input.readRawVarint32();
|
||||
int limit = input.pushLimit(length);
|
||||
if (!((mutable_bitField0_ & 0x00000001) == 0x00000001) && input.getBytesUntilLimit() > 0) {
|
||||
bucket_ = new java.util.ArrayList<java.lang.Integer>();
|
||||
mutable_bitField0_ |= 0x00000001;
|
||||
}
|
||||
while (input.getBytesUntilLimit() > 0) {
|
||||
bucket_.add(input.readUInt32());
|
||||
}
|
||||
input.popLimit(limit);
|
||||
break;
|
||||
}
|
||||
case 17: {
|
||||
|
||||
minSeen_ = input.readDouble();
|
||||
break;
|
||||
}
|
||||
case 25: {
|
||||
|
||||
maxSeen_ = input.readDouble();
|
||||
break;
|
||||
}
|
||||
case 33: {
|
||||
|
||||
sum_ = input.readDouble();
|
||||
break;
|
||||
}
|
||||
case 41: {
|
||||
|
||||
sumOfSquares_ = input.readDouble();
|
||||
break;
|
||||
}
|
||||
case 49: {
|
||||
|
||||
count_ = input.readDouble();
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
throw new RuntimeException(e.setUnfinishedMessage(this));
|
||||
} catch (java.io.IOException e) {
|
||||
throw new RuntimeException(
|
||||
new com.google.protobuf.InvalidProtocolBufferException(
|
||||
e.getMessage()).setUnfinishedMessage(this));
|
||||
} finally {
|
||||
if (((mutable_bitField0_ & 0x00000001) == 0x00000001)) {
|
||||
bucket_ = java.util.Collections.unmodifiableList(bucket_);
|
||||
}
|
||||
makeExtensionsImmutable();
|
||||
}
|
||||
}
|
||||
public static final com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptor() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_HistogramData_descriptor;
|
||||
}
|
||||
|
||||
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_HistogramData_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
io.grpc.testing.HistogramData.class, io.grpc.testing.HistogramData.Builder.class);
|
||||
}
|
||||
|
||||
private int bitField0_;
|
||||
public static final int BUCKET_FIELD_NUMBER = 1;
|
||||
private java.util.List<java.lang.Integer> bucket_;
|
||||
/**
|
||||
* <code>repeated uint32 bucket = 1;</code>
|
||||
*/
|
||||
public java.util.List<java.lang.Integer>
|
||||
getBucketList() {
|
||||
return bucket_;
|
||||
}
|
||||
/**
|
||||
* <code>repeated uint32 bucket = 1;</code>
|
||||
*/
|
||||
public int getBucketCount() {
|
||||
return bucket_.size();
|
||||
}
|
||||
/**
|
||||
* <code>repeated uint32 bucket = 1;</code>
|
||||
*/
|
||||
public int getBucket(int index) {
|
||||
return bucket_.get(index);
|
||||
}
|
||||
private int bucketMemoizedSerializedSize = -1;
|
||||
|
||||
public static final int MIN_SEEN_FIELD_NUMBER = 2;
|
||||
private double minSeen_;
|
||||
/**
|
||||
* <code>optional double min_seen = 2;</code>
|
||||
*/
|
||||
public double getMinSeen() {
|
||||
return minSeen_;
|
||||
}
|
||||
|
||||
public static final int MAX_SEEN_FIELD_NUMBER = 3;
|
||||
private double maxSeen_;
|
||||
/**
|
||||
* <code>optional double max_seen = 3;</code>
|
||||
*/
|
||||
public double getMaxSeen() {
|
||||
return maxSeen_;
|
||||
}
|
||||
|
||||
public static final int SUM_FIELD_NUMBER = 4;
|
||||
private double sum_;
|
||||
/**
|
||||
* <code>optional double sum = 4;</code>
|
||||
*/
|
||||
public double getSum() {
|
||||
return sum_;
|
||||
}
|
||||
|
||||
public static final int SUM_OF_SQUARES_FIELD_NUMBER = 5;
|
||||
private double sumOfSquares_;
|
||||
/**
|
||||
* <code>optional double sum_of_squares = 5;</code>
|
||||
*/
|
||||
public double getSumOfSquares() {
|
||||
return sumOfSquares_;
|
||||
}
|
||||
|
||||
public static final int COUNT_FIELD_NUMBER = 6;
|
||||
private double count_;
|
||||
/**
|
||||
* <code>optional double count = 6;</code>
|
||||
*/
|
||||
public double getCount() {
|
||||
return count_;
|
||||
}
|
||||
|
||||
private byte memoizedIsInitialized = -1;
|
||||
public final boolean isInitialized() {
|
||||
byte isInitialized = memoizedIsInitialized;
|
||||
if (isInitialized == 1) return true;
|
||||
if (isInitialized == 0) return false;
|
||||
|
||||
memoizedIsInitialized = 1;
|
||||
return true;
|
||||
}
|
||||
|
||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
||||
throws java.io.IOException {
|
||||
getSerializedSize();
|
||||
if (getBucketList().size() > 0) {
|
||||
output.writeRawVarint32(10);
|
||||
output.writeRawVarint32(bucketMemoizedSerializedSize);
|
||||
}
|
||||
for (int i = 0; i < bucket_.size(); i++) {
|
||||
output.writeUInt32NoTag(bucket_.get(i));
|
||||
}
|
||||
if (minSeen_ != 0D) {
|
||||
output.writeDouble(2, minSeen_);
|
||||
}
|
||||
if (maxSeen_ != 0D) {
|
||||
output.writeDouble(3, maxSeen_);
|
||||
}
|
||||
if (sum_ != 0D) {
|
||||
output.writeDouble(4, sum_);
|
||||
}
|
||||
if (sumOfSquares_ != 0D) {
|
||||
output.writeDouble(5, sumOfSquares_);
|
||||
}
|
||||
if (count_ != 0D) {
|
||||
output.writeDouble(6, count_);
|
||||
}
|
||||
}
|
||||
|
||||
public int getSerializedSize() {
|
||||
int size = memoizedSize;
|
||||
if (size != -1) return size;
|
||||
|
||||
size = 0;
|
||||
{
|
||||
int dataSize = 0;
|
||||
for (int i = 0; i < bucket_.size(); i++) {
|
||||
dataSize += com.google.protobuf.CodedOutputStream
|
||||
.computeUInt32SizeNoTag(bucket_.get(i));
|
||||
}
|
||||
size += dataSize;
|
||||
if (!getBucketList().isEmpty()) {
|
||||
size += 1;
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeInt32SizeNoTag(dataSize);
|
||||
}
|
||||
bucketMemoizedSerializedSize = dataSize;
|
||||
}
|
||||
if (minSeen_ != 0D) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeDoubleSize(2, minSeen_);
|
||||
}
|
||||
if (maxSeen_ != 0D) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeDoubleSize(3, maxSeen_);
|
||||
}
|
||||
if (sum_ != 0D) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeDoubleSize(4, sum_);
|
||||
}
|
||||
if (sumOfSquares_ != 0D) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeDoubleSize(5, sumOfSquares_);
|
||||
}
|
||||
if (count_ != 0D) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeDoubleSize(6, count_);
|
||||
}
|
||||
memoizedSize = size;
|
||||
return size;
|
||||
}
|
||||
|
||||
private static final long serialVersionUID = 0L;
|
||||
public static io.grpc.testing.HistogramData parseFrom(
|
||||
com.google.protobuf.ByteString data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static io.grpc.testing.HistogramData parseFrom(
|
||||
com.google.protobuf.ByteString data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.HistogramData parseFrom(byte[] data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static io.grpc.testing.HistogramData parseFrom(
|
||||
byte[] data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.HistogramData parseFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.HistogramData parseFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.HistogramData parseDelimitedFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseDelimitedFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.HistogramData parseDelimitedFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseDelimitedFrom(input, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.HistogramData parseFrom(
|
||||
com.google.protobuf.CodedInputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.HistogramData parseFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input, extensionRegistry);
|
||||
}
|
||||
|
||||
public Builder newBuilderForType() { return newBuilder(); }
|
||||
public static Builder newBuilder() {
|
||||
return DEFAULT_INSTANCE.toBuilder();
|
||||
}
|
||||
public static Builder newBuilder(io.grpc.testing.HistogramData prototype) {
|
||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
||||
}
|
||||
public Builder toBuilder() {
|
||||
return this == DEFAULT_INSTANCE
|
||||
? new Builder() : new Builder().mergeFrom(this);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected Builder newBuilderForType(
|
||||
com.google.protobuf.GeneratedMessage.BuilderParent parent) {
|
||||
Builder builder = new Builder(parent);
|
||||
return builder;
|
||||
}
|
||||
/**
|
||||
* Protobuf type {@code grpc.testing.HistogramData}
|
||||
*/
|
||||
public static final class Builder extends
|
||||
com.google.protobuf.GeneratedMessage.Builder<Builder> implements
|
||||
// @@protoc_insertion_point(builder_implements:grpc.testing.HistogramData)
|
||||
io.grpc.testing.HistogramDataOrBuilder {
|
||||
public static final com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptor() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_HistogramData_descriptor;
|
||||
}
|
||||
|
||||
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_HistogramData_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
io.grpc.testing.HistogramData.class, io.grpc.testing.HistogramData.Builder.class);
|
||||
}
|
||||
|
||||
// Construct using io.grpc.testing.HistogramData.newBuilder()
|
||||
private Builder() {
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
|
||||
private Builder(
|
||||
com.google.protobuf.GeneratedMessage.BuilderParent parent) {
|
||||
super(parent);
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
private void maybeForceBuilderInitialization() {
|
||||
if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
|
||||
}
|
||||
}
|
||||
public Builder clear() {
|
||||
super.clear();
|
||||
bucket_ = java.util.Collections.emptyList();
|
||||
bitField0_ = (bitField0_ & ~0x00000001);
|
||||
minSeen_ = 0D;
|
||||
|
||||
maxSeen_ = 0D;
|
||||
|
||||
sum_ = 0D;
|
||||
|
||||
sumOfSquares_ = 0D;
|
||||
|
||||
count_ = 0D;
|
||||
|
||||
return this;
|
||||
}
|
||||
|
||||
public com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptorForType() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_HistogramData_descriptor;
|
||||
}
|
||||
|
||||
public io.grpc.testing.HistogramData getDefaultInstanceForType() {
|
||||
return io.grpc.testing.HistogramData.getDefaultInstance();
|
||||
}
|
||||
|
||||
public io.grpc.testing.HistogramData build() {
|
||||
io.grpc.testing.HistogramData result = buildPartial();
|
||||
if (!result.isInitialized()) {
|
||||
throw newUninitializedMessageException(result);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
public io.grpc.testing.HistogramData buildPartial() {
|
||||
io.grpc.testing.HistogramData result = new io.grpc.testing.HistogramData(this);
|
||||
int from_bitField0_ = bitField0_;
|
||||
int to_bitField0_ = 0;
|
||||
if (((bitField0_ & 0x00000001) == 0x00000001)) {
|
||||
bucket_ = java.util.Collections.unmodifiableList(bucket_);
|
||||
bitField0_ = (bitField0_ & ~0x00000001);
|
||||
}
|
||||
result.bucket_ = bucket_;
|
||||
result.minSeen_ = minSeen_;
|
||||
result.maxSeen_ = maxSeen_;
|
||||
result.sum_ = sum_;
|
||||
result.sumOfSquares_ = sumOfSquares_;
|
||||
result.count_ = count_;
|
||||
result.bitField0_ = to_bitField0_;
|
||||
onBuilt();
|
||||
return result;
|
||||
}
|
||||
|
||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
||||
if (other instanceof io.grpc.testing.HistogramData) {
|
||||
return mergeFrom((io.grpc.testing.HistogramData)other);
|
||||
} else {
|
||||
super.mergeFrom(other);
|
||||
return this;
|
||||
}
|
||||
}
|
||||
|
||||
public Builder mergeFrom(io.grpc.testing.HistogramData other) {
|
||||
if (other == io.grpc.testing.HistogramData.getDefaultInstance()) return this;
|
||||
if (!other.bucket_.isEmpty()) {
|
||||
if (bucket_.isEmpty()) {
|
||||
bucket_ = other.bucket_;
|
||||
bitField0_ = (bitField0_ & ~0x00000001);
|
||||
} else {
|
||||
ensureBucketIsMutable();
|
||||
bucket_.addAll(other.bucket_);
|
||||
}
|
||||
onChanged();
|
||||
}
|
||||
if (other.getMinSeen() != 0D) {
|
||||
setMinSeen(other.getMinSeen());
|
||||
}
|
||||
if (other.getMaxSeen() != 0D) {
|
||||
setMaxSeen(other.getMaxSeen());
|
||||
}
|
||||
if (other.getSum() != 0D) {
|
||||
setSum(other.getSum());
|
||||
}
|
||||
if (other.getSumOfSquares() != 0D) {
|
||||
setSumOfSquares(other.getSumOfSquares());
|
||||
}
|
||||
if (other.getCount() != 0D) {
|
||||
setCount(other.getCount());
|
||||
}
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
public final boolean isInitialized() {
|
||||
return true;
|
||||
}
|
||||
|
||||
public Builder mergeFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
io.grpc.testing.HistogramData parsedMessage = null;
|
||||
try {
|
||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
parsedMessage = (io.grpc.testing.HistogramData) e.getUnfinishedMessage();
|
||||
throw e;
|
||||
} finally {
|
||||
if (parsedMessage != null) {
|
||||
mergeFrom(parsedMessage);
|
||||
}
|
||||
}
|
||||
return this;
|
||||
}
|
||||
private int bitField0_;
|
||||
|
||||
private java.util.List<java.lang.Integer> bucket_ = java.util.Collections.emptyList();
|
||||
private void ensureBucketIsMutable() {
|
||||
if (!((bitField0_ & 0x00000001) == 0x00000001)) {
|
||||
bucket_ = new java.util.ArrayList<java.lang.Integer>(bucket_);
|
||||
bitField0_ |= 0x00000001;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <code>repeated uint32 bucket = 1;</code>
|
||||
*/
|
||||
public java.util.List<java.lang.Integer>
|
||||
getBucketList() {
|
||||
return java.util.Collections.unmodifiableList(bucket_);
|
||||
}
|
||||
/**
|
||||
* <code>repeated uint32 bucket = 1;</code>
|
||||
*/
|
||||
public int getBucketCount() {
|
||||
return bucket_.size();
|
||||
}
|
||||
/**
|
||||
* <code>repeated uint32 bucket = 1;</code>
|
||||
*/
|
||||
public int getBucket(int index) {
|
||||
return bucket_.get(index);
|
||||
}
|
||||
/**
|
||||
* <code>repeated uint32 bucket = 1;</code>
|
||||
*/
|
||||
public Builder setBucket(
|
||||
int index, int value) {
|
||||
ensureBucketIsMutable();
|
||||
bucket_.set(index, value);
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>repeated uint32 bucket = 1;</code>
|
||||
*/
|
||||
public Builder addBucket(int value) {
|
||||
ensureBucketIsMutable();
|
||||
bucket_.add(value);
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>repeated uint32 bucket = 1;</code>
|
||||
*/
|
||||
public Builder addAllBucket(
|
||||
java.lang.Iterable<? extends java.lang.Integer> values) {
|
||||
ensureBucketIsMutable();
|
||||
com.google.protobuf.AbstractMessageLite.Builder.addAll(
|
||||
values, bucket_);
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>repeated uint32 bucket = 1;</code>
|
||||
*/
|
||||
public Builder clearBucket() {
|
||||
bucket_ = java.util.Collections.emptyList();
|
||||
bitField0_ = (bitField0_ & ~0x00000001);
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
private double minSeen_ ;
|
||||
/**
|
||||
* <code>optional double min_seen = 2;</code>
|
||||
*/
|
||||
public double getMinSeen() {
|
||||
return minSeen_;
|
||||
}
|
||||
/**
|
||||
* <code>optional double min_seen = 2;</code>
|
||||
*/
|
||||
public Builder setMinSeen(double value) {
|
||||
|
||||
minSeen_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional double min_seen = 2;</code>
|
||||
*/
|
||||
public Builder clearMinSeen() {
|
||||
|
||||
minSeen_ = 0D;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
private double maxSeen_ ;
|
||||
/**
|
||||
* <code>optional double max_seen = 3;</code>
|
||||
*/
|
||||
public double getMaxSeen() {
|
||||
return maxSeen_;
|
||||
}
|
||||
/**
|
||||
* <code>optional double max_seen = 3;</code>
|
||||
*/
|
||||
public Builder setMaxSeen(double value) {
|
||||
|
||||
maxSeen_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional double max_seen = 3;</code>
|
||||
*/
|
||||
public Builder clearMaxSeen() {
|
||||
|
||||
maxSeen_ = 0D;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
private double sum_ ;
|
||||
/**
|
||||
* <code>optional double sum = 4;</code>
|
||||
*/
|
||||
public double getSum() {
|
||||
return sum_;
|
||||
}
|
||||
/**
|
||||
* <code>optional double sum = 4;</code>
|
||||
*/
|
||||
public Builder setSum(double value) {
|
||||
|
||||
sum_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional double sum = 4;</code>
|
||||
*/
|
||||
public Builder clearSum() {
|
||||
|
||||
sum_ = 0D;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
private double sumOfSquares_ ;
|
||||
/**
|
||||
* <code>optional double sum_of_squares = 5;</code>
|
||||
*/
|
||||
public double getSumOfSquares() {
|
||||
return sumOfSquares_;
|
||||
}
|
||||
/**
|
||||
* <code>optional double sum_of_squares = 5;</code>
|
||||
*/
|
||||
public Builder setSumOfSquares(double value) {
|
||||
|
||||
sumOfSquares_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional double sum_of_squares = 5;</code>
|
||||
*/
|
||||
public Builder clearSumOfSquares() {
|
||||
|
||||
sumOfSquares_ = 0D;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
private double count_ ;
|
||||
/**
|
||||
* <code>optional double count = 6;</code>
|
||||
*/
|
||||
public double getCount() {
|
||||
return count_;
|
||||
}
|
||||
/**
|
||||
* <code>optional double count = 6;</code>
|
||||
*/
|
||||
public Builder setCount(double value) {
|
||||
|
||||
count_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional double count = 6;</code>
|
||||
*/
|
||||
public Builder clearCount() {
|
||||
|
||||
count_ = 0D;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
public final Builder setUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return this;
|
||||
}
|
||||
|
||||
public final Builder mergeUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return this;
|
||||
}
|
||||
|
||||
|
||||
// @@protoc_insertion_point(builder_scope:grpc.testing.HistogramData)
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(class_scope:grpc.testing.HistogramData)
|
||||
private static final io.grpc.testing.HistogramData DEFAULT_INSTANCE;
|
||||
static {
|
||||
DEFAULT_INSTANCE = new io.grpc.testing.HistogramData();
|
||||
}
|
||||
|
||||
public static io.grpc.testing.HistogramData getDefaultInstance() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
private static final com.google.protobuf.Parser<HistogramData>
|
||||
PARSER = new com.google.protobuf.AbstractParser<HistogramData>() {
|
||||
public HistogramData parsePartialFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
try {
|
||||
return new HistogramData(input, extensionRegistry);
|
||||
} catch (RuntimeException e) {
|
||||
if (e.getCause() instanceof
|
||||
com.google.protobuf.InvalidProtocolBufferException) {
|
||||
throw (com.google.protobuf.InvalidProtocolBufferException)
|
||||
e.getCause();
|
||||
}
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
public static com.google.protobuf.Parser<HistogramData> parser() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.Parser<HistogramData> getParserForType() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
public io.grpc.testing.HistogramData getDefaultInstanceForType() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
|
@ -1,47 +0,0 @@
|
|||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: qpstest.proto
|
||||
|
||||
package io.grpc.testing;
|
||||
|
||||
public interface HistogramDataOrBuilder extends
|
||||
// @@protoc_insertion_point(interface_extends:grpc.testing.HistogramData)
|
||||
com.google.protobuf.MessageOrBuilder {
|
||||
|
||||
/**
|
||||
* <code>repeated uint32 bucket = 1;</code>
|
||||
*/
|
||||
java.util.List<java.lang.Integer> getBucketList();
|
||||
/**
|
||||
* <code>repeated uint32 bucket = 1;</code>
|
||||
*/
|
||||
int getBucketCount();
|
||||
/**
|
||||
* <code>repeated uint32 bucket = 1;</code>
|
||||
*/
|
||||
int getBucket(int index);
|
||||
|
||||
/**
|
||||
* <code>optional double min_seen = 2;</code>
|
||||
*/
|
||||
double getMinSeen();
|
||||
|
||||
/**
|
||||
* <code>optional double max_seen = 3;</code>
|
||||
*/
|
||||
double getMaxSeen();
|
||||
|
||||
/**
|
||||
* <code>optional double sum = 4;</code>
|
||||
*/
|
||||
double getSum();
|
||||
|
||||
/**
|
||||
* <code>optional double sum_of_squares = 5;</code>
|
||||
*/
|
||||
double getSumOfSquares();
|
||||
|
||||
/**
|
||||
* <code>optional double count = 6;</code>
|
||||
*/
|
||||
double getCount();
|
||||
}
|
||||
|
|
@ -1,324 +0,0 @@
|
|||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: qpstest.proto
|
||||
|
||||
package io.grpc.testing;
|
||||
|
||||
/**
|
||||
* Protobuf type {@code grpc.testing.Mark}
|
||||
*
|
||||
* <pre>
|
||||
* Request current stats
|
||||
* </pre>
|
||||
*/
|
||||
public final class Mark extends
|
||||
com.google.protobuf.GeneratedMessage implements
|
||||
// @@protoc_insertion_point(message_implements:grpc.testing.Mark)
|
||||
MarkOrBuilder {
|
||||
// Use Mark.newBuilder() to construct.
|
||||
private Mark(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
|
||||
super(builder);
|
||||
}
|
||||
private Mark() {
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public final com.google.protobuf.UnknownFieldSet
|
||||
getUnknownFields() {
|
||||
return com.google.protobuf.UnknownFieldSet.getDefaultInstance();
|
||||
}
|
||||
private Mark(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry) {
|
||||
this();
|
||||
try {
|
||||
boolean done = false;
|
||||
while (!done) {
|
||||
int tag = input.readTag();
|
||||
switch (tag) {
|
||||
case 0:
|
||||
done = true;
|
||||
break;
|
||||
default: {
|
||||
if (!input.skipField(tag)) {
|
||||
done = true;
|
||||
}
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
throw new RuntimeException(e.setUnfinishedMessage(this));
|
||||
} catch (java.io.IOException e) {
|
||||
throw new RuntimeException(
|
||||
new com.google.protobuf.InvalidProtocolBufferException(
|
||||
e.getMessage()).setUnfinishedMessage(this));
|
||||
} finally {
|
||||
makeExtensionsImmutable();
|
||||
}
|
||||
}
|
||||
public static final com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptor() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_Mark_descriptor;
|
||||
}
|
||||
|
||||
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_Mark_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
io.grpc.testing.Mark.class, io.grpc.testing.Mark.Builder.class);
|
||||
}
|
||||
|
||||
private byte memoizedIsInitialized = -1;
|
||||
public final boolean isInitialized() {
|
||||
byte isInitialized = memoizedIsInitialized;
|
||||
if (isInitialized == 1) return true;
|
||||
if (isInitialized == 0) return false;
|
||||
|
||||
memoizedIsInitialized = 1;
|
||||
return true;
|
||||
}
|
||||
|
||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
||||
throws java.io.IOException {
|
||||
}
|
||||
|
||||
public int getSerializedSize() {
|
||||
int size = memoizedSize;
|
||||
if (size != -1) return size;
|
||||
|
||||
size = 0;
|
||||
memoizedSize = size;
|
||||
return size;
|
||||
}
|
||||
|
||||
private static final long serialVersionUID = 0L;
|
||||
public static io.grpc.testing.Mark parseFrom(
|
||||
com.google.protobuf.ByteString data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static io.grpc.testing.Mark parseFrom(
|
||||
com.google.protobuf.ByteString data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.Mark parseFrom(byte[] data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static io.grpc.testing.Mark parseFrom(
|
||||
byte[] data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.Mark parseFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.Mark parseFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.Mark parseDelimitedFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseDelimitedFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.Mark parseDelimitedFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseDelimitedFrom(input, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.Mark parseFrom(
|
||||
com.google.protobuf.CodedInputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.Mark parseFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input, extensionRegistry);
|
||||
}
|
||||
|
||||
public Builder newBuilderForType() { return newBuilder(); }
|
||||
public static Builder newBuilder() {
|
||||
return DEFAULT_INSTANCE.toBuilder();
|
||||
}
|
||||
public static Builder newBuilder(io.grpc.testing.Mark prototype) {
|
||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
||||
}
|
||||
public Builder toBuilder() {
|
||||
return this == DEFAULT_INSTANCE
|
||||
? new Builder() : new Builder().mergeFrom(this);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected Builder newBuilderForType(
|
||||
com.google.protobuf.GeneratedMessage.BuilderParent parent) {
|
||||
Builder builder = new Builder(parent);
|
||||
return builder;
|
||||
}
|
||||
/**
|
||||
* Protobuf type {@code grpc.testing.Mark}
|
||||
*
|
||||
* <pre>
|
||||
* Request current stats
|
||||
* </pre>
|
||||
*/
|
||||
public static final class Builder extends
|
||||
com.google.protobuf.GeneratedMessage.Builder<Builder> implements
|
||||
// @@protoc_insertion_point(builder_implements:grpc.testing.Mark)
|
||||
io.grpc.testing.MarkOrBuilder {
|
||||
public static final com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptor() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_Mark_descriptor;
|
||||
}
|
||||
|
||||
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_Mark_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
io.grpc.testing.Mark.class, io.grpc.testing.Mark.Builder.class);
|
||||
}
|
||||
|
||||
// Construct using io.grpc.testing.Mark.newBuilder()
|
||||
private Builder() {
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
|
||||
private Builder(
|
||||
com.google.protobuf.GeneratedMessage.BuilderParent parent) {
|
||||
super(parent);
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
private void maybeForceBuilderInitialization() {
|
||||
if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
|
||||
}
|
||||
}
|
||||
public Builder clear() {
|
||||
super.clear();
|
||||
return this;
|
||||
}
|
||||
|
||||
public com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptorForType() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_Mark_descriptor;
|
||||
}
|
||||
|
||||
public io.grpc.testing.Mark getDefaultInstanceForType() {
|
||||
return io.grpc.testing.Mark.getDefaultInstance();
|
||||
}
|
||||
|
||||
public io.grpc.testing.Mark build() {
|
||||
io.grpc.testing.Mark result = buildPartial();
|
||||
if (!result.isInitialized()) {
|
||||
throw newUninitializedMessageException(result);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
public io.grpc.testing.Mark buildPartial() {
|
||||
io.grpc.testing.Mark result = new io.grpc.testing.Mark(this);
|
||||
onBuilt();
|
||||
return result;
|
||||
}
|
||||
|
||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
||||
if (other instanceof io.grpc.testing.Mark) {
|
||||
return mergeFrom((io.grpc.testing.Mark)other);
|
||||
} else {
|
||||
super.mergeFrom(other);
|
||||
return this;
|
||||
}
|
||||
}
|
||||
|
||||
public Builder mergeFrom(io.grpc.testing.Mark other) {
|
||||
if (other == io.grpc.testing.Mark.getDefaultInstance()) return this;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
public final boolean isInitialized() {
|
||||
return true;
|
||||
}
|
||||
|
||||
public Builder mergeFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
io.grpc.testing.Mark parsedMessage = null;
|
||||
try {
|
||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
parsedMessage = (io.grpc.testing.Mark) e.getUnfinishedMessage();
|
||||
throw e;
|
||||
} finally {
|
||||
if (parsedMessage != null) {
|
||||
mergeFrom(parsedMessage);
|
||||
}
|
||||
}
|
||||
return this;
|
||||
}
|
||||
public final Builder setUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return this;
|
||||
}
|
||||
|
||||
public final Builder mergeUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return this;
|
||||
}
|
||||
|
||||
|
||||
// @@protoc_insertion_point(builder_scope:grpc.testing.Mark)
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(class_scope:grpc.testing.Mark)
|
||||
private static final io.grpc.testing.Mark DEFAULT_INSTANCE;
|
||||
static {
|
||||
DEFAULT_INSTANCE = new io.grpc.testing.Mark();
|
||||
}
|
||||
|
||||
public static io.grpc.testing.Mark getDefaultInstance() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
private static final com.google.protobuf.Parser<Mark>
|
||||
PARSER = new com.google.protobuf.AbstractParser<Mark>() {
|
||||
public Mark parsePartialFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
try {
|
||||
return new Mark(input, extensionRegistry);
|
||||
} catch (RuntimeException e) {
|
||||
if (e.getCause() instanceof
|
||||
com.google.protobuf.InvalidProtocolBufferException) {
|
||||
throw (com.google.protobuf.InvalidProtocolBufferException)
|
||||
e.getCause();
|
||||
}
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
public static com.google.protobuf.Parser<Mark> parser() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.Parser<Mark> getParserForType() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
public io.grpc.testing.Mark getDefaultInstanceForType() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
|
@ -1,9 +0,0 @@
|
|||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: qpstest.proto
|
||||
|
||||
package io.grpc.testing;
|
||||
|
||||
public interface MarkOrBuilder extends
|
||||
// @@protoc_insertion_point(interface_extends:grpc.testing.Mark)
|
||||
com.google.protobuf.MessageOrBuilder {
|
||||
}
|
||||
|
|
@ -1,498 +0,0 @@
|
|||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: qpstest.proto
|
||||
|
||||
package io.grpc.testing;
|
||||
|
||||
/**
|
||||
* Protobuf type {@code grpc.testing.Payload}
|
||||
*/
|
||||
public final class Payload extends
|
||||
com.google.protobuf.GeneratedMessage implements
|
||||
// @@protoc_insertion_point(message_implements:grpc.testing.Payload)
|
||||
PayloadOrBuilder {
|
||||
// Use Payload.newBuilder() to construct.
|
||||
private Payload(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
|
||||
super(builder);
|
||||
}
|
||||
private Payload() {
|
||||
type_ = 0;
|
||||
body_ = com.google.protobuf.ByteString.EMPTY;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public final com.google.protobuf.UnknownFieldSet
|
||||
getUnknownFields() {
|
||||
return com.google.protobuf.UnknownFieldSet.getDefaultInstance();
|
||||
}
|
||||
private Payload(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry) {
|
||||
this();
|
||||
int mutable_bitField0_ = 0;
|
||||
try {
|
||||
boolean done = false;
|
||||
while (!done) {
|
||||
int tag = input.readTag();
|
||||
switch (tag) {
|
||||
case 0:
|
||||
done = true;
|
||||
break;
|
||||
default: {
|
||||
if (!input.skipField(tag)) {
|
||||
done = true;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case 8: {
|
||||
int rawValue = input.readEnum();
|
||||
|
||||
type_ = rawValue;
|
||||
break;
|
||||
}
|
||||
case 18: {
|
||||
|
||||
body_ = input.readBytes();
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
throw new RuntimeException(e.setUnfinishedMessage(this));
|
||||
} catch (java.io.IOException e) {
|
||||
throw new RuntimeException(
|
||||
new com.google.protobuf.InvalidProtocolBufferException(
|
||||
e.getMessage()).setUnfinishedMessage(this));
|
||||
} finally {
|
||||
makeExtensionsImmutable();
|
||||
}
|
||||
}
|
||||
public static final com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptor() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_Payload_descriptor;
|
||||
}
|
||||
|
||||
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_Payload_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
io.grpc.testing.Payload.class, io.grpc.testing.Payload.Builder.class);
|
||||
}
|
||||
|
||||
public static final int TYPE_FIELD_NUMBER = 1;
|
||||
private int type_;
|
||||
/**
|
||||
* <code>optional .grpc.testing.PayloadType type = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
* The type of data in body.
|
||||
* </pre>
|
||||
*/
|
||||
public int getTypeValue() {
|
||||
return type_;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.PayloadType type = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
* The type of data in body.
|
||||
* </pre>
|
||||
*/
|
||||
public io.grpc.testing.PayloadType getType() {
|
||||
io.grpc.testing.PayloadType result = io.grpc.testing.PayloadType.valueOf(type_);
|
||||
return result == null ? io.grpc.testing.PayloadType.UNRECOGNIZED : result;
|
||||
}
|
||||
|
||||
public static final int BODY_FIELD_NUMBER = 2;
|
||||
private com.google.protobuf.ByteString body_;
|
||||
/**
|
||||
* <code>optional bytes body = 2;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Primary contents of payload.
|
||||
* </pre>
|
||||
*/
|
||||
public com.google.protobuf.ByteString getBody() {
|
||||
return body_;
|
||||
}
|
||||
|
||||
private byte memoizedIsInitialized = -1;
|
||||
public final boolean isInitialized() {
|
||||
byte isInitialized = memoizedIsInitialized;
|
||||
if (isInitialized == 1) return true;
|
||||
if (isInitialized == 0) return false;
|
||||
|
||||
memoizedIsInitialized = 1;
|
||||
return true;
|
||||
}
|
||||
|
||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
||||
throws java.io.IOException {
|
||||
if (type_ != io.grpc.testing.PayloadType.COMPRESSABLE.getNumber()) {
|
||||
output.writeEnum(1, type_);
|
||||
}
|
||||
if (!body_.isEmpty()) {
|
||||
output.writeBytes(2, body_);
|
||||
}
|
||||
}
|
||||
|
||||
public int getSerializedSize() {
|
||||
int size = memoizedSize;
|
||||
if (size != -1) return size;
|
||||
|
||||
size = 0;
|
||||
if (type_ != io.grpc.testing.PayloadType.COMPRESSABLE.getNumber()) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeEnumSize(1, type_);
|
||||
}
|
||||
if (!body_.isEmpty()) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeBytesSize(2, body_);
|
||||
}
|
||||
memoizedSize = size;
|
||||
return size;
|
||||
}
|
||||
|
||||
private static final long serialVersionUID = 0L;
|
||||
public static io.grpc.testing.Payload parseFrom(
|
||||
com.google.protobuf.ByteString data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static io.grpc.testing.Payload parseFrom(
|
||||
com.google.protobuf.ByteString data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.Payload parseFrom(byte[] data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static io.grpc.testing.Payload parseFrom(
|
||||
byte[] data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.Payload parseFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.Payload parseFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.Payload parseDelimitedFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseDelimitedFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.Payload parseDelimitedFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseDelimitedFrom(input, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.Payload parseFrom(
|
||||
com.google.protobuf.CodedInputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.Payload parseFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input, extensionRegistry);
|
||||
}
|
||||
|
||||
public Builder newBuilderForType() { return newBuilder(); }
|
||||
public static Builder newBuilder() {
|
||||
return DEFAULT_INSTANCE.toBuilder();
|
||||
}
|
||||
public static Builder newBuilder(io.grpc.testing.Payload prototype) {
|
||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
||||
}
|
||||
public Builder toBuilder() {
|
||||
return this == DEFAULT_INSTANCE
|
||||
? new Builder() : new Builder().mergeFrom(this);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected Builder newBuilderForType(
|
||||
com.google.protobuf.GeneratedMessage.BuilderParent parent) {
|
||||
Builder builder = new Builder(parent);
|
||||
return builder;
|
||||
}
|
||||
/**
|
||||
* Protobuf type {@code grpc.testing.Payload}
|
||||
*/
|
||||
public static final class Builder extends
|
||||
com.google.protobuf.GeneratedMessage.Builder<Builder> implements
|
||||
// @@protoc_insertion_point(builder_implements:grpc.testing.Payload)
|
||||
io.grpc.testing.PayloadOrBuilder {
|
||||
public static final com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptor() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_Payload_descriptor;
|
||||
}
|
||||
|
||||
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_Payload_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
io.grpc.testing.Payload.class, io.grpc.testing.Payload.Builder.class);
|
||||
}
|
||||
|
||||
// Construct using io.grpc.testing.Payload.newBuilder()
|
||||
private Builder() {
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
|
||||
private Builder(
|
||||
com.google.protobuf.GeneratedMessage.BuilderParent parent) {
|
||||
super(parent);
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
private void maybeForceBuilderInitialization() {
|
||||
if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
|
||||
}
|
||||
}
|
||||
public Builder clear() {
|
||||
super.clear();
|
||||
type_ = 0;
|
||||
|
||||
body_ = com.google.protobuf.ByteString.EMPTY;
|
||||
|
||||
return this;
|
||||
}
|
||||
|
||||
public com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptorForType() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_Payload_descriptor;
|
||||
}
|
||||
|
||||
public io.grpc.testing.Payload getDefaultInstanceForType() {
|
||||
return io.grpc.testing.Payload.getDefaultInstance();
|
||||
}
|
||||
|
||||
public io.grpc.testing.Payload build() {
|
||||
io.grpc.testing.Payload result = buildPartial();
|
||||
if (!result.isInitialized()) {
|
||||
throw newUninitializedMessageException(result);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
public io.grpc.testing.Payload buildPartial() {
|
||||
io.grpc.testing.Payload result = new io.grpc.testing.Payload(this);
|
||||
result.type_ = type_;
|
||||
result.body_ = body_;
|
||||
onBuilt();
|
||||
return result;
|
||||
}
|
||||
|
||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
||||
if (other instanceof io.grpc.testing.Payload) {
|
||||
return mergeFrom((io.grpc.testing.Payload)other);
|
||||
} else {
|
||||
super.mergeFrom(other);
|
||||
return this;
|
||||
}
|
||||
}
|
||||
|
||||
public Builder mergeFrom(io.grpc.testing.Payload other) {
|
||||
if (other == io.grpc.testing.Payload.getDefaultInstance()) return this;
|
||||
if (other.type_ != 0) {
|
||||
setTypeValue(other.getTypeValue());
|
||||
}
|
||||
if (other.getBody() != com.google.protobuf.ByteString.EMPTY) {
|
||||
setBody(other.getBody());
|
||||
}
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
public final boolean isInitialized() {
|
||||
return true;
|
||||
}
|
||||
|
||||
public Builder mergeFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
io.grpc.testing.Payload parsedMessage = null;
|
||||
try {
|
||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
parsedMessage = (io.grpc.testing.Payload) e.getUnfinishedMessage();
|
||||
throw e;
|
||||
} finally {
|
||||
if (parsedMessage != null) {
|
||||
mergeFrom(parsedMessage);
|
||||
}
|
||||
}
|
||||
return this;
|
||||
}
|
||||
|
||||
private int type_ = 0;
|
||||
/**
|
||||
* <code>optional .grpc.testing.PayloadType type = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
* The type of data in body.
|
||||
* </pre>
|
||||
*/
|
||||
public int getTypeValue() {
|
||||
return type_;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.PayloadType type = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
* The type of data in body.
|
||||
* </pre>
|
||||
*/
|
||||
public Builder setTypeValue(int value) {
|
||||
type_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.PayloadType type = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
* The type of data in body.
|
||||
* </pre>
|
||||
*/
|
||||
public io.grpc.testing.PayloadType getType() {
|
||||
io.grpc.testing.PayloadType result = io.grpc.testing.PayloadType.valueOf(type_);
|
||||
return result == null ? io.grpc.testing.PayloadType.UNRECOGNIZED : result;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.PayloadType type = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
* The type of data in body.
|
||||
* </pre>
|
||||
*/
|
||||
public Builder setType(io.grpc.testing.PayloadType value) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
|
||||
type_ = value.getNumber();
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.PayloadType type = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
* The type of data in body.
|
||||
* </pre>
|
||||
*/
|
||||
public Builder clearType() {
|
||||
|
||||
type_ = 0;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
private com.google.protobuf.ByteString body_ = com.google.protobuf.ByteString.EMPTY;
|
||||
/**
|
||||
* <code>optional bytes body = 2;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Primary contents of payload.
|
||||
* </pre>
|
||||
*/
|
||||
public com.google.protobuf.ByteString getBody() {
|
||||
return body_;
|
||||
}
|
||||
/**
|
||||
* <code>optional bytes body = 2;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Primary contents of payload.
|
||||
* </pre>
|
||||
*/
|
||||
public Builder setBody(com.google.protobuf.ByteString value) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
|
||||
body_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional bytes body = 2;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Primary contents of payload.
|
||||
* </pre>
|
||||
*/
|
||||
public Builder clearBody() {
|
||||
|
||||
body_ = getDefaultInstance().getBody();
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
public final Builder setUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return this;
|
||||
}
|
||||
|
||||
public final Builder mergeUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return this;
|
||||
}
|
||||
|
||||
|
||||
// @@protoc_insertion_point(builder_scope:grpc.testing.Payload)
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(class_scope:grpc.testing.Payload)
|
||||
private static final io.grpc.testing.Payload DEFAULT_INSTANCE;
|
||||
static {
|
||||
DEFAULT_INSTANCE = new io.grpc.testing.Payload();
|
||||
}
|
||||
|
||||
public static io.grpc.testing.Payload getDefaultInstance() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
private static final com.google.protobuf.Parser<Payload>
|
||||
PARSER = new com.google.protobuf.AbstractParser<Payload>() {
|
||||
public Payload parsePartialFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
try {
|
||||
return new Payload(input, extensionRegistry);
|
||||
} catch (RuntimeException e) {
|
||||
if (e.getCause() instanceof
|
||||
com.google.protobuf.InvalidProtocolBufferException) {
|
||||
throw (com.google.protobuf.InvalidProtocolBufferException)
|
||||
e.getCause();
|
||||
}
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
public static com.google.protobuf.Parser<Payload> parser() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.Parser<Payload> getParserForType() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
public io.grpc.testing.Payload getDefaultInstanceForType() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
|
@ -1,35 +0,0 @@
|
|||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: qpstest.proto
|
||||
|
||||
package io.grpc.testing;
|
||||
|
||||
public interface PayloadOrBuilder extends
|
||||
// @@protoc_insertion_point(interface_extends:grpc.testing.Payload)
|
||||
com.google.protobuf.MessageOrBuilder {
|
||||
|
||||
/**
|
||||
* <code>optional .grpc.testing.PayloadType type = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
* The type of data in body.
|
||||
* </pre>
|
||||
*/
|
||||
int getTypeValue();
|
||||
/**
|
||||
* <code>optional .grpc.testing.PayloadType type = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
* The type of data in body.
|
||||
* </pre>
|
||||
*/
|
||||
io.grpc.testing.PayloadType getType();
|
||||
|
||||
/**
|
||||
* <code>optional bytes body = 2;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Primary contents of payload.
|
||||
* </pre>
|
||||
*/
|
||||
com.google.protobuf.ByteString getBody();
|
||||
}
|
||||
|
|
@ -1,131 +0,0 @@
|
|||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: qpstest.proto
|
||||
|
||||
package io.grpc.testing;
|
||||
|
||||
/**
|
||||
* Protobuf enum {@code grpc.testing.PayloadType}
|
||||
*/
|
||||
public enum PayloadType
|
||||
implements com.google.protobuf.ProtocolMessageEnum {
|
||||
/**
|
||||
* <code>COMPRESSABLE = 0;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Compressable text format.
|
||||
* </pre>
|
||||
*/
|
||||
COMPRESSABLE(0, 0),
|
||||
/**
|
||||
* <code>UNCOMPRESSABLE = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Uncompressable binary format.
|
||||
* </pre>
|
||||
*/
|
||||
UNCOMPRESSABLE(1, 1),
|
||||
/**
|
||||
* <code>RANDOM = 2;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Randomly chosen from all other formats defined in this enum.
|
||||
* </pre>
|
||||
*/
|
||||
RANDOM(2, 2),
|
||||
UNRECOGNIZED(-1, -1),
|
||||
;
|
||||
|
||||
/**
|
||||
* <code>COMPRESSABLE = 0;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Compressable text format.
|
||||
* </pre>
|
||||
*/
|
||||
public static final int COMPRESSABLE_VALUE = 0;
|
||||
/**
|
||||
* <code>UNCOMPRESSABLE = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Uncompressable binary format.
|
||||
* </pre>
|
||||
*/
|
||||
public static final int UNCOMPRESSABLE_VALUE = 1;
|
||||
/**
|
||||
* <code>RANDOM = 2;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Randomly chosen from all other formats defined in this enum.
|
||||
* </pre>
|
||||
*/
|
||||
public static final int RANDOM_VALUE = 2;
|
||||
|
||||
|
||||
public final int getNumber() {
|
||||
if (index == -1) {
|
||||
throw new java.lang.IllegalArgumentException(
|
||||
"Can't get the number of an unknown enum value.");
|
||||
}
|
||||
return value;
|
||||
}
|
||||
|
||||
public static PayloadType valueOf(int value) {
|
||||
switch (value) {
|
||||
case 0: return COMPRESSABLE;
|
||||
case 1: return UNCOMPRESSABLE;
|
||||
case 2: return RANDOM;
|
||||
default: return null;
|
||||
}
|
||||
}
|
||||
|
||||
public static com.google.protobuf.Internal.EnumLiteMap<PayloadType>
|
||||
internalGetValueMap() {
|
||||
return internalValueMap;
|
||||
}
|
||||
private static final com.google.protobuf.Internal.EnumLiteMap<
|
||||
PayloadType> internalValueMap =
|
||||
new com.google.protobuf.Internal.EnumLiteMap<PayloadType>() {
|
||||
public PayloadType findValueByNumber(int number) {
|
||||
return PayloadType.valueOf(number);
|
||||
}
|
||||
};
|
||||
|
||||
public final com.google.protobuf.Descriptors.EnumValueDescriptor
|
||||
getValueDescriptor() {
|
||||
return getDescriptor().getValues().get(index);
|
||||
}
|
||||
public final com.google.protobuf.Descriptors.EnumDescriptor
|
||||
getDescriptorForType() {
|
||||
return getDescriptor();
|
||||
}
|
||||
public static final com.google.protobuf.Descriptors.EnumDescriptor
|
||||
getDescriptor() {
|
||||
return io.grpc.testing.QpsTestProto.getDescriptor()
|
||||
.getEnumTypes().get(0);
|
||||
}
|
||||
|
||||
private static final PayloadType[] VALUES = values();
|
||||
|
||||
public static PayloadType valueOf(
|
||||
com.google.protobuf.Descriptors.EnumValueDescriptor desc) {
|
||||
if (desc.getType() != getDescriptor()) {
|
||||
throw new java.lang.IllegalArgumentException(
|
||||
"EnumValueDescriptor is not for this type.");
|
||||
}
|
||||
if (desc.getIndex() == -1) {
|
||||
return UNRECOGNIZED;
|
||||
}
|
||||
return VALUES[desc.getIndex()];
|
||||
}
|
||||
|
||||
private final int index;
|
||||
private final int value;
|
||||
|
||||
private PayloadType(int index, int value) {
|
||||
this.index = index;
|
||||
this.value = value;
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(enum_scope:grpc.testing.PayloadType)
|
||||
}
|
||||
|
||||
|
|
@ -1,239 +0,0 @@
|
|||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: qpstest.proto
|
||||
|
||||
package io.grpc.testing;
|
||||
|
||||
public final class QpsTestProto {
|
||||
private QpsTestProto() {}
|
||||
public static void registerAllExtensions(
|
||||
com.google.protobuf.ExtensionRegistry registry) {
|
||||
}
|
||||
static com.google.protobuf.Descriptors.Descriptor
|
||||
internal_static_grpc_testing_StatsRequest_descriptor;
|
||||
static
|
||||
com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internal_static_grpc_testing_StatsRequest_fieldAccessorTable;
|
||||
static com.google.protobuf.Descriptors.Descriptor
|
||||
internal_static_grpc_testing_ServerStats_descriptor;
|
||||
static
|
||||
com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internal_static_grpc_testing_ServerStats_fieldAccessorTable;
|
||||
static com.google.protobuf.Descriptors.Descriptor
|
||||
internal_static_grpc_testing_Payload_descriptor;
|
||||
static
|
||||
com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internal_static_grpc_testing_Payload_fieldAccessorTable;
|
||||
static com.google.protobuf.Descriptors.Descriptor
|
||||
internal_static_grpc_testing_HistogramData_descriptor;
|
||||
static
|
||||
com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internal_static_grpc_testing_HistogramData_fieldAccessorTable;
|
||||
static com.google.protobuf.Descriptors.Descriptor
|
||||
internal_static_grpc_testing_ClientConfig_descriptor;
|
||||
static
|
||||
com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internal_static_grpc_testing_ClientConfig_fieldAccessorTable;
|
||||
static com.google.protobuf.Descriptors.Descriptor
|
||||
internal_static_grpc_testing_Mark_descriptor;
|
||||
static
|
||||
com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internal_static_grpc_testing_Mark_fieldAccessorTable;
|
||||
static com.google.protobuf.Descriptors.Descriptor
|
||||
internal_static_grpc_testing_ClientArgs_descriptor;
|
||||
static
|
||||
com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internal_static_grpc_testing_ClientArgs_fieldAccessorTable;
|
||||
static com.google.protobuf.Descriptors.Descriptor
|
||||
internal_static_grpc_testing_ClientStats_descriptor;
|
||||
static
|
||||
com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internal_static_grpc_testing_ClientStats_fieldAccessorTable;
|
||||
static com.google.protobuf.Descriptors.Descriptor
|
||||
internal_static_grpc_testing_ClientStatus_descriptor;
|
||||
static
|
||||
com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internal_static_grpc_testing_ClientStatus_fieldAccessorTable;
|
||||
static com.google.protobuf.Descriptors.Descriptor
|
||||
internal_static_grpc_testing_ServerConfig_descriptor;
|
||||
static
|
||||
com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internal_static_grpc_testing_ServerConfig_fieldAccessorTable;
|
||||
static com.google.protobuf.Descriptors.Descriptor
|
||||
internal_static_grpc_testing_ServerArgs_descriptor;
|
||||
static
|
||||
com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internal_static_grpc_testing_ServerArgs_fieldAccessorTable;
|
||||
static com.google.protobuf.Descriptors.Descriptor
|
||||
internal_static_grpc_testing_ServerStatus_descriptor;
|
||||
static
|
||||
com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internal_static_grpc_testing_ServerStatus_fieldAccessorTable;
|
||||
static com.google.protobuf.Descriptors.Descriptor
|
||||
internal_static_grpc_testing_SimpleRequest_descriptor;
|
||||
static
|
||||
com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internal_static_grpc_testing_SimpleRequest_fieldAccessorTable;
|
||||
static com.google.protobuf.Descriptors.Descriptor
|
||||
internal_static_grpc_testing_SimpleResponse_descriptor;
|
||||
static
|
||||
com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internal_static_grpc_testing_SimpleResponse_fieldAccessorTable;
|
||||
|
||||
public static com.google.protobuf.Descriptors.FileDescriptor
|
||||
getDescriptor() {
|
||||
return descriptor;
|
||||
}
|
||||
private static com.google.protobuf.Descriptors.FileDescriptor
|
||||
descriptor;
|
||||
static {
|
||||
java.lang.String[] descriptorData = {
|
||||
"\n\rqpstest.proto\022\014grpc.testing\" \n\014StatsRe" +
|
||||
"quest\022\020\n\010test_num\030\001 \001(\005\"K\n\013ServerStats\022\024" +
|
||||
"\n\014time_elapsed\030\001 \001(\001\022\021\n\ttime_user\030\002 \001(\001\022" +
|
||||
"\023\n\013time_system\030\003 \001(\001\"@\n\007Payload\022\'\n\004type\030" +
|
||||
"\001 \001(\0162\031.grpc.testing.PayloadType\022\014\n\004body" +
|
||||
"\030\002 \001(\014\"w\n\rHistogramData\022\016\n\006bucket\030\001 \003(\r\022" +
|
||||
"\020\n\010min_seen\030\002 \001(\001\022\020\n\010max_seen\030\003 \001(\001\022\013\n\003s" +
|
||||
"um\030\004 \001(\001\022\026\n\016sum_of_squares\030\005 \001(\001\022\r\n\005coun" +
|
||||
"t\030\006 \001(\001\"\205\002\n\014ClientConfig\022\026\n\016server_targe" +
|
||||
"ts\030\001 \003(\t\022-\n\013client_type\030\002 \001(\0162\030.grpc.tes",
|
||||
"ting.ClientType\022\022\n\nenable_ssl\030\003 \001(\010\022$\n\034o" +
|
||||
"utstanding_rpcs_per_channel\030\004 \001(\005\022\027\n\017cli" +
|
||||
"ent_channels\030\005 \001(\005\022\024\n\014payload_size\030\006 \001(\005" +
|
||||
"\022\034\n\024async_client_threads\030\007 \001(\005\022\'\n\010rpc_ty" +
|
||||
"pe\030\010 \001(\0162\025.grpc.testing.RpcType\"\006\n\004Mark\"" +
|
||||
"h\n\nClientArgs\022+\n\005setup\030\001 \001(\0132\032.grpc.test" +
|
||||
"ing.ClientConfigH\000\022\"\n\004mark\030\002 \001(\0132\022.grpc." +
|
||||
"testing.MarkH\000B\t\n\007argtype\"{\n\013ClientStats" +
|
||||
"\022.\n\tlatencies\030\001 \001(\0132\033.grpc.testing.Histo" +
|
||||
"gramData\022\024\n\014time_elapsed\030\003 \001(\001\022\021\n\ttime_u",
|
||||
"ser\030\004 \001(\001\022\023\n\013time_system\030\005 \001(\001\"8\n\014Client" +
|
||||
"Status\022(\n\005stats\030\001 \001(\0132\031.grpc.testing.Cli" +
|
||||
"entStats\"b\n\014ServerConfig\022-\n\013server_type\030" +
|
||||
"\001 \001(\0162\030.grpc.testing.ServerType\022\017\n\007threa" +
|
||||
"ds\030\002 \001(\005\022\022\n\nenable_ssl\030\003 \001(\010\"h\n\nServerAr" +
|
||||
"gs\022+\n\005setup\030\001 \001(\0132\032.grpc.testing.ServerC" +
|
||||
"onfigH\000\022\"\n\004mark\030\002 \001(\0132\022.grpc.testing.Mar" +
|
||||
"kH\000B\t\n\007argtype\"F\n\014ServerStatus\022(\n\005stats\030" +
|
||||
"\001 \001(\0132\031.grpc.testing.ServerStats\022\014\n\004port" +
|
||||
"\030\002 \001(\005\"\200\001\n\rSimpleRequest\0220\n\rresponse_typ",
|
||||
"e\030\001 \001(\0162\031.grpc.testing.PayloadType\022\025\n\rre" +
|
||||
"sponse_size\030\002 \001(\005\022&\n\007payload\030\003 \001(\0132\025.grp" +
|
||||
"c.testing.Payload\"8\n\016SimpleResponse\022&\n\007p" +
|
||||
"ayload\030\001 \001(\0132\025.grpc.testing.Payload*?\n\013P" +
|
||||
"ayloadType\022\020\n\014COMPRESSABLE\020\000\022\022\n\016UNCOMPRE" +
|
||||
"SSABLE\020\001\022\n\n\006RANDOM\020\002*6\n\nClientType\022\026\n\022SY" +
|
||||
"NCHRONOUS_CLIENT\020\000\022\020\n\014ASYNC_CLIENT\020\001*6\n\n" +
|
||||
"ServerType\022\026\n\022SYNCHRONOUS_SERVER\020\000\022\020\n\014AS" +
|
||||
"YNC_SERVER\020\001*#\n\007RpcType\022\t\n\005UNARY\020\000\022\r\n\tST" +
|
||||
"REAMING\020\0012\245\001\n\013TestService\022F\n\tUnaryCall\022\033",
|
||||
".grpc.testing.SimpleRequest\032\034.grpc.testi" +
|
||||
"ng.SimpleResponse\022N\n\rStreamingCall\022\033.grp" +
|
||||
"c.testing.SimpleRequest\032\034.grpc.testing.S" +
|
||||
"impleResponse(\0010\0012\224\001\n\006Worker\022C\n\007RunTest\022" +
|
||||
"\030.grpc.testing.ClientArgs\032\032.grpc.testing" +
|
||||
".ClientStatus(\0010\001\022E\n\tRunServer\022\030.grpc.te" +
|
||||
"sting.ServerArgs\032\032.grpc.testing.ServerSt" +
|
||||
"atus(\0010\001B!\n\017io.grpc.testingB\014QpsTestProt" +
|
||||
"oP\001b\006proto3"
|
||||
};
|
||||
com.google.protobuf.Descriptors.FileDescriptor.InternalDescriptorAssigner assigner =
|
||||
new com.google.protobuf.Descriptors.FileDescriptor. InternalDescriptorAssigner() {
|
||||
public com.google.protobuf.ExtensionRegistry assignDescriptors(
|
||||
com.google.protobuf.Descriptors.FileDescriptor root) {
|
||||
descriptor = root;
|
||||
return null;
|
||||
}
|
||||
};
|
||||
com.google.protobuf.Descriptors.FileDescriptor
|
||||
.internalBuildGeneratedFileFrom(descriptorData,
|
||||
new com.google.protobuf.Descriptors.FileDescriptor[] {
|
||||
}, assigner);
|
||||
internal_static_grpc_testing_StatsRequest_descriptor =
|
||||
getDescriptor().getMessageTypes().get(0);
|
||||
internal_static_grpc_testing_StatsRequest_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessage.FieldAccessorTable(
|
||||
internal_static_grpc_testing_StatsRequest_descriptor,
|
||||
new java.lang.String[] { "TestNum", });
|
||||
internal_static_grpc_testing_ServerStats_descriptor =
|
||||
getDescriptor().getMessageTypes().get(1);
|
||||
internal_static_grpc_testing_ServerStats_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessage.FieldAccessorTable(
|
||||
internal_static_grpc_testing_ServerStats_descriptor,
|
||||
new java.lang.String[] { "TimeElapsed", "TimeUser", "TimeSystem", });
|
||||
internal_static_grpc_testing_Payload_descriptor =
|
||||
getDescriptor().getMessageTypes().get(2);
|
||||
internal_static_grpc_testing_Payload_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessage.FieldAccessorTable(
|
||||
internal_static_grpc_testing_Payload_descriptor,
|
||||
new java.lang.String[] { "Type", "Body", });
|
||||
internal_static_grpc_testing_HistogramData_descriptor =
|
||||
getDescriptor().getMessageTypes().get(3);
|
||||
internal_static_grpc_testing_HistogramData_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessage.FieldAccessorTable(
|
||||
internal_static_grpc_testing_HistogramData_descriptor,
|
||||
new java.lang.String[] { "Bucket", "MinSeen", "MaxSeen", "Sum", "SumOfSquares", "Count", });
|
||||
internal_static_grpc_testing_ClientConfig_descriptor =
|
||||
getDescriptor().getMessageTypes().get(4);
|
||||
internal_static_grpc_testing_ClientConfig_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessage.FieldAccessorTable(
|
||||
internal_static_grpc_testing_ClientConfig_descriptor,
|
||||
new java.lang.String[] { "ServerTargets", "ClientType", "EnableSsl", "OutstandingRpcsPerChannel", "ClientChannels", "PayloadSize", "AsyncClientThreads", "RpcType", });
|
||||
internal_static_grpc_testing_Mark_descriptor =
|
||||
getDescriptor().getMessageTypes().get(5);
|
||||
internal_static_grpc_testing_Mark_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessage.FieldAccessorTable(
|
||||
internal_static_grpc_testing_Mark_descriptor,
|
||||
new java.lang.String[] { });
|
||||
internal_static_grpc_testing_ClientArgs_descriptor =
|
||||
getDescriptor().getMessageTypes().get(6);
|
||||
internal_static_grpc_testing_ClientArgs_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessage.FieldAccessorTable(
|
||||
internal_static_grpc_testing_ClientArgs_descriptor,
|
||||
new java.lang.String[] { "Setup", "Mark", "Argtype", });
|
||||
internal_static_grpc_testing_ClientStats_descriptor =
|
||||
getDescriptor().getMessageTypes().get(7);
|
||||
internal_static_grpc_testing_ClientStats_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessage.FieldAccessorTable(
|
||||
internal_static_grpc_testing_ClientStats_descriptor,
|
||||
new java.lang.String[] { "Latencies", "TimeElapsed", "TimeUser", "TimeSystem", });
|
||||
internal_static_grpc_testing_ClientStatus_descriptor =
|
||||
getDescriptor().getMessageTypes().get(8);
|
||||
internal_static_grpc_testing_ClientStatus_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessage.FieldAccessorTable(
|
||||
internal_static_grpc_testing_ClientStatus_descriptor,
|
||||
new java.lang.String[] { "Stats", });
|
||||
internal_static_grpc_testing_ServerConfig_descriptor =
|
||||
getDescriptor().getMessageTypes().get(9);
|
||||
internal_static_grpc_testing_ServerConfig_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessage.FieldAccessorTable(
|
||||
internal_static_grpc_testing_ServerConfig_descriptor,
|
||||
new java.lang.String[] { "ServerType", "Threads", "EnableSsl", });
|
||||
internal_static_grpc_testing_ServerArgs_descriptor =
|
||||
getDescriptor().getMessageTypes().get(10);
|
||||
internal_static_grpc_testing_ServerArgs_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessage.FieldAccessorTable(
|
||||
internal_static_grpc_testing_ServerArgs_descriptor,
|
||||
new java.lang.String[] { "Setup", "Mark", "Argtype", });
|
||||
internal_static_grpc_testing_ServerStatus_descriptor =
|
||||
getDescriptor().getMessageTypes().get(11);
|
||||
internal_static_grpc_testing_ServerStatus_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessage.FieldAccessorTable(
|
||||
internal_static_grpc_testing_ServerStatus_descriptor,
|
||||
new java.lang.String[] { "Stats", "Port", });
|
||||
internal_static_grpc_testing_SimpleRequest_descriptor =
|
||||
getDescriptor().getMessageTypes().get(12);
|
||||
internal_static_grpc_testing_SimpleRequest_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessage.FieldAccessorTable(
|
||||
internal_static_grpc_testing_SimpleRequest_descriptor,
|
||||
new java.lang.String[] { "ResponseType", "ResponseSize", "Payload", });
|
||||
internal_static_grpc_testing_SimpleResponse_descriptor =
|
||||
getDescriptor().getMessageTypes().get(13);
|
||||
internal_static_grpc_testing_SimpleResponse_fieldAccessorTable = new
|
||||
com.google.protobuf.GeneratedMessage.FieldAccessorTable(
|
||||
internal_static_grpc_testing_SimpleResponse_descriptor,
|
||||
new java.lang.String[] { "Payload", });
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(outer_class_scope)
|
||||
}
|
||||
|
|
@ -1,98 +0,0 @@
|
|||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: qpstest.proto
|
||||
|
||||
package io.grpc.testing;
|
||||
|
||||
/**
|
||||
* Protobuf enum {@code grpc.testing.RpcType}
|
||||
*/
|
||||
public enum RpcType
|
||||
implements com.google.protobuf.ProtocolMessageEnum {
|
||||
/**
|
||||
* <code>UNARY = 0;</code>
|
||||
*/
|
||||
UNARY(0, 0),
|
||||
/**
|
||||
* <code>STREAMING = 1;</code>
|
||||
*/
|
||||
STREAMING(1, 1),
|
||||
UNRECOGNIZED(-1, -1),
|
||||
;
|
||||
|
||||
/**
|
||||
* <code>UNARY = 0;</code>
|
||||
*/
|
||||
public static final int UNARY_VALUE = 0;
|
||||
/**
|
||||
* <code>STREAMING = 1;</code>
|
||||
*/
|
||||
public static final int STREAMING_VALUE = 1;
|
||||
|
||||
|
||||
public final int getNumber() {
|
||||
if (index == -1) {
|
||||
throw new java.lang.IllegalArgumentException(
|
||||
"Can't get the number of an unknown enum value.");
|
||||
}
|
||||
return value;
|
||||
}
|
||||
|
||||
public static RpcType valueOf(int value) {
|
||||
switch (value) {
|
||||
case 0: return UNARY;
|
||||
case 1: return STREAMING;
|
||||
default: return null;
|
||||
}
|
||||
}
|
||||
|
||||
public static com.google.protobuf.Internal.EnumLiteMap<RpcType>
|
||||
internalGetValueMap() {
|
||||
return internalValueMap;
|
||||
}
|
||||
private static final com.google.protobuf.Internal.EnumLiteMap<
|
||||
RpcType> internalValueMap =
|
||||
new com.google.protobuf.Internal.EnumLiteMap<RpcType>() {
|
||||
public RpcType findValueByNumber(int number) {
|
||||
return RpcType.valueOf(number);
|
||||
}
|
||||
};
|
||||
|
||||
public final com.google.protobuf.Descriptors.EnumValueDescriptor
|
||||
getValueDescriptor() {
|
||||
return getDescriptor().getValues().get(index);
|
||||
}
|
||||
public final com.google.protobuf.Descriptors.EnumDescriptor
|
||||
getDescriptorForType() {
|
||||
return getDescriptor();
|
||||
}
|
||||
public static final com.google.protobuf.Descriptors.EnumDescriptor
|
||||
getDescriptor() {
|
||||
return io.grpc.testing.QpsTestProto.getDescriptor()
|
||||
.getEnumTypes().get(3);
|
||||
}
|
||||
|
||||
private static final RpcType[] VALUES = values();
|
||||
|
||||
public static RpcType valueOf(
|
||||
com.google.protobuf.Descriptors.EnumValueDescriptor desc) {
|
||||
if (desc.getType() != getDescriptor()) {
|
||||
throw new java.lang.IllegalArgumentException(
|
||||
"EnumValueDescriptor is not for this type.");
|
||||
}
|
||||
if (desc.getIndex() == -1) {
|
||||
return UNRECOGNIZED;
|
||||
}
|
||||
return VALUES[desc.getIndex()];
|
||||
}
|
||||
|
||||
private final int index;
|
||||
private final int value;
|
||||
|
||||
private RpcType(int index, int value) {
|
||||
this.index = index;
|
||||
this.value = value;
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(enum_scope:grpc.testing.RpcType)
|
||||
}
|
||||
|
||||
|
|
@ -1,735 +0,0 @@
|
|||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: qpstest.proto
|
||||
|
||||
package io.grpc.testing;
|
||||
|
||||
/**
|
||||
* Protobuf type {@code grpc.testing.ServerArgs}
|
||||
*/
|
||||
public final class ServerArgs extends
|
||||
com.google.protobuf.GeneratedMessage implements
|
||||
// @@protoc_insertion_point(message_implements:grpc.testing.ServerArgs)
|
||||
ServerArgsOrBuilder {
|
||||
// Use ServerArgs.newBuilder() to construct.
|
||||
private ServerArgs(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
|
||||
super(builder);
|
||||
}
|
||||
private ServerArgs() {
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public final com.google.protobuf.UnknownFieldSet
|
||||
getUnknownFields() {
|
||||
return com.google.protobuf.UnknownFieldSet.getDefaultInstance();
|
||||
}
|
||||
private ServerArgs(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry) {
|
||||
this();
|
||||
int mutable_bitField0_ = 0;
|
||||
try {
|
||||
boolean done = false;
|
||||
while (!done) {
|
||||
int tag = input.readTag();
|
||||
switch (tag) {
|
||||
case 0:
|
||||
done = true;
|
||||
break;
|
||||
default: {
|
||||
if (!input.skipField(tag)) {
|
||||
done = true;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case 10: {
|
||||
io.grpc.testing.ServerConfig.Builder subBuilder = null;
|
||||
if (argtypeCase_ == 1) {
|
||||
subBuilder = ((io.grpc.testing.ServerConfig) argtype_).toBuilder();
|
||||
}
|
||||
argtype_ =
|
||||
input.readMessage(io.grpc.testing.ServerConfig.parser(), extensionRegistry);
|
||||
if (subBuilder != null) {
|
||||
subBuilder.mergeFrom((io.grpc.testing.ServerConfig) argtype_);
|
||||
argtype_ = subBuilder.buildPartial();
|
||||
}
|
||||
argtypeCase_ = 1;
|
||||
break;
|
||||
}
|
||||
case 18: {
|
||||
io.grpc.testing.Mark.Builder subBuilder = null;
|
||||
if (argtypeCase_ == 2) {
|
||||
subBuilder = ((io.grpc.testing.Mark) argtype_).toBuilder();
|
||||
}
|
||||
argtype_ =
|
||||
input.readMessage(io.grpc.testing.Mark.parser(), extensionRegistry);
|
||||
if (subBuilder != null) {
|
||||
subBuilder.mergeFrom((io.grpc.testing.Mark) argtype_);
|
||||
argtype_ = subBuilder.buildPartial();
|
||||
}
|
||||
argtypeCase_ = 2;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
throw new RuntimeException(e.setUnfinishedMessage(this));
|
||||
} catch (java.io.IOException e) {
|
||||
throw new RuntimeException(
|
||||
new com.google.protobuf.InvalidProtocolBufferException(
|
||||
e.getMessage()).setUnfinishedMessage(this));
|
||||
} finally {
|
||||
makeExtensionsImmutable();
|
||||
}
|
||||
}
|
||||
public static final com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptor() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ServerArgs_descriptor;
|
||||
}
|
||||
|
||||
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ServerArgs_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
io.grpc.testing.ServerArgs.class, io.grpc.testing.ServerArgs.Builder.class);
|
||||
}
|
||||
|
||||
private int argtypeCase_ = 0;
|
||||
private java.lang.Object argtype_;
|
||||
public enum ArgtypeCase
|
||||
implements com.google.protobuf.Internal.EnumLite {
|
||||
SETUP(1),
|
||||
MARK(2),
|
||||
ARGTYPE_NOT_SET(0);
|
||||
private int value = 0;
|
||||
private ArgtypeCase(int value) {
|
||||
this.value = value;
|
||||
}
|
||||
public static ArgtypeCase valueOf(int value) {
|
||||
switch (value) {
|
||||
case 1: return SETUP;
|
||||
case 2: return MARK;
|
||||
case 0: return ARGTYPE_NOT_SET;
|
||||
default: throw new java.lang.IllegalArgumentException(
|
||||
"Value is undefined for this oneof enum.");
|
||||
}
|
||||
}
|
||||
public int getNumber() {
|
||||
return this.value;
|
||||
}
|
||||
};
|
||||
|
||||
public ArgtypeCase
|
||||
getArgtypeCase() {
|
||||
return ArgtypeCase.valueOf(
|
||||
argtypeCase_);
|
||||
}
|
||||
|
||||
public static final int SETUP_FIELD_NUMBER = 1;
|
||||
/**
|
||||
* <code>optional .grpc.testing.ServerConfig setup = 1;</code>
|
||||
*/
|
||||
public io.grpc.testing.ServerConfig getSetup() {
|
||||
if (argtypeCase_ == 1) {
|
||||
return (io.grpc.testing.ServerConfig) argtype_;
|
||||
}
|
||||
return io.grpc.testing.ServerConfig.getDefaultInstance();
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ServerConfig setup = 1;</code>
|
||||
*/
|
||||
public io.grpc.testing.ServerConfigOrBuilder getSetupOrBuilder() {
|
||||
if (argtypeCase_ == 1) {
|
||||
return (io.grpc.testing.ServerConfig) argtype_;
|
||||
}
|
||||
return io.grpc.testing.ServerConfig.getDefaultInstance();
|
||||
}
|
||||
|
||||
public static final int MARK_FIELD_NUMBER = 2;
|
||||
/**
|
||||
* <code>optional .grpc.testing.Mark mark = 2;</code>
|
||||
*/
|
||||
public io.grpc.testing.Mark getMark() {
|
||||
if (argtypeCase_ == 2) {
|
||||
return (io.grpc.testing.Mark) argtype_;
|
||||
}
|
||||
return io.grpc.testing.Mark.getDefaultInstance();
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.Mark mark = 2;</code>
|
||||
*/
|
||||
public io.grpc.testing.MarkOrBuilder getMarkOrBuilder() {
|
||||
if (argtypeCase_ == 2) {
|
||||
return (io.grpc.testing.Mark) argtype_;
|
||||
}
|
||||
return io.grpc.testing.Mark.getDefaultInstance();
|
||||
}
|
||||
|
||||
private byte memoizedIsInitialized = -1;
|
||||
public final boolean isInitialized() {
|
||||
byte isInitialized = memoizedIsInitialized;
|
||||
if (isInitialized == 1) return true;
|
||||
if (isInitialized == 0) return false;
|
||||
|
||||
memoizedIsInitialized = 1;
|
||||
return true;
|
||||
}
|
||||
|
||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
||||
throws java.io.IOException {
|
||||
if (argtypeCase_ == 1) {
|
||||
output.writeMessage(1, (io.grpc.testing.ServerConfig) argtype_);
|
||||
}
|
||||
if (argtypeCase_ == 2) {
|
||||
output.writeMessage(2, (io.grpc.testing.Mark) argtype_);
|
||||
}
|
||||
}
|
||||
|
||||
public int getSerializedSize() {
|
||||
int size = memoizedSize;
|
||||
if (size != -1) return size;
|
||||
|
||||
size = 0;
|
||||
if (argtypeCase_ == 1) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeMessageSize(1, (io.grpc.testing.ServerConfig) argtype_);
|
||||
}
|
||||
if (argtypeCase_ == 2) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeMessageSize(2, (io.grpc.testing.Mark) argtype_);
|
||||
}
|
||||
memoizedSize = size;
|
||||
return size;
|
||||
}
|
||||
|
||||
private static final long serialVersionUID = 0L;
|
||||
public static io.grpc.testing.ServerArgs parseFrom(
|
||||
com.google.protobuf.ByteString data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static io.grpc.testing.ServerArgs parseFrom(
|
||||
com.google.protobuf.ByteString data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.ServerArgs parseFrom(byte[] data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static io.grpc.testing.ServerArgs parseFrom(
|
||||
byte[] data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.ServerArgs parseFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.ServerArgs parseFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.ServerArgs parseDelimitedFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseDelimitedFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.ServerArgs parseDelimitedFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseDelimitedFrom(input, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.ServerArgs parseFrom(
|
||||
com.google.protobuf.CodedInputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.ServerArgs parseFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input, extensionRegistry);
|
||||
}
|
||||
|
||||
public Builder newBuilderForType() { return newBuilder(); }
|
||||
public static Builder newBuilder() {
|
||||
return DEFAULT_INSTANCE.toBuilder();
|
||||
}
|
||||
public static Builder newBuilder(io.grpc.testing.ServerArgs prototype) {
|
||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
||||
}
|
||||
public Builder toBuilder() {
|
||||
return this == DEFAULT_INSTANCE
|
||||
? new Builder() : new Builder().mergeFrom(this);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected Builder newBuilderForType(
|
||||
com.google.protobuf.GeneratedMessage.BuilderParent parent) {
|
||||
Builder builder = new Builder(parent);
|
||||
return builder;
|
||||
}
|
||||
/**
|
||||
* Protobuf type {@code grpc.testing.ServerArgs}
|
||||
*/
|
||||
public static final class Builder extends
|
||||
com.google.protobuf.GeneratedMessage.Builder<Builder> implements
|
||||
// @@protoc_insertion_point(builder_implements:grpc.testing.ServerArgs)
|
||||
io.grpc.testing.ServerArgsOrBuilder {
|
||||
public static final com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptor() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ServerArgs_descriptor;
|
||||
}
|
||||
|
||||
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ServerArgs_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
io.grpc.testing.ServerArgs.class, io.grpc.testing.ServerArgs.Builder.class);
|
||||
}
|
||||
|
||||
// Construct using io.grpc.testing.ServerArgs.newBuilder()
|
||||
private Builder() {
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
|
||||
private Builder(
|
||||
com.google.protobuf.GeneratedMessage.BuilderParent parent) {
|
||||
super(parent);
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
private void maybeForceBuilderInitialization() {
|
||||
if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
|
||||
}
|
||||
}
|
||||
public Builder clear() {
|
||||
super.clear();
|
||||
argtypeCase_ = 0;
|
||||
argtype_ = null;
|
||||
return this;
|
||||
}
|
||||
|
||||
public com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptorForType() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ServerArgs_descriptor;
|
||||
}
|
||||
|
||||
public io.grpc.testing.ServerArgs getDefaultInstanceForType() {
|
||||
return io.grpc.testing.ServerArgs.getDefaultInstance();
|
||||
}
|
||||
|
||||
public io.grpc.testing.ServerArgs build() {
|
||||
io.grpc.testing.ServerArgs result = buildPartial();
|
||||
if (!result.isInitialized()) {
|
||||
throw newUninitializedMessageException(result);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
public io.grpc.testing.ServerArgs buildPartial() {
|
||||
io.grpc.testing.ServerArgs result = new io.grpc.testing.ServerArgs(this);
|
||||
if (argtypeCase_ == 1) {
|
||||
if (setupBuilder_ == null) {
|
||||
result.argtype_ = argtype_;
|
||||
} else {
|
||||
result.argtype_ = setupBuilder_.build();
|
||||
}
|
||||
}
|
||||
if (argtypeCase_ == 2) {
|
||||
if (markBuilder_ == null) {
|
||||
result.argtype_ = argtype_;
|
||||
} else {
|
||||
result.argtype_ = markBuilder_.build();
|
||||
}
|
||||
}
|
||||
result.argtypeCase_ = argtypeCase_;
|
||||
onBuilt();
|
||||
return result;
|
||||
}
|
||||
|
||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
||||
if (other instanceof io.grpc.testing.ServerArgs) {
|
||||
return mergeFrom((io.grpc.testing.ServerArgs)other);
|
||||
} else {
|
||||
super.mergeFrom(other);
|
||||
return this;
|
||||
}
|
||||
}
|
||||
|
||||
public Builder mergeFrom(io.grpc.testing.ServerArgs other) {
|
||||
if (other == io.grpc.testing.ServerArgs.getDefaultInstance()) return this;
|
||||
switch (other.getArgtypeCase()) {
|
||||
case SETUP: {
|
||||
mergeSetup(other.getSetup());
|
||||
break;
|
||||
}
|
||||
case MARK: {
|
||||
mergeMark(other.getMark());
|
||||
break;
|
||||
}
|
||||
case ARGTYPE_NOT_SET: {
|
||||
break;
|
||||
}
|
||||
}
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
public final boolean isInitialized() {
|
||||
return true;
|
||||
}
|
||||
|
||||
public Builder mergeFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
io.grpc.testing.ServerArgs parsedMessage = null;
|
||||
try {
|
||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
parsedMessage = (io.grpc.testing.ServerArgs) e.getUnfinishedMessage();
|
||||
throw e;
|
||||
} finally {
|
||||
if (parsedMessage != null) {
|
||||
mergeFrom(parsedMessage);
|
||||
}
|
||||
}
|
||||
return this;
|
||||
}
|
||||
private int argtypeCase_ = 0;
|
||||
private java.lang.Object argtype_;
|
||||
public ArgtypeCase
|
||||
getArgtypeCase() {
|
||||
return ArgtypeCase.valueOf(
|
||||
argtypeCase_);
|
||||
}
|
||||
|
||||
public Builder clearArgtype() {
|
||||
argtypeCase_ = 0;
|
||||
argtype_ = null;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
|
||||
private com.google.protobuf.SingleFieldBuilder<
|
||||
io.grpc.testing.ServerConfig, io.grpc.testing.ServerConfig.Builder, io.grpc.testing.ServerConfigOrBuilder> setupBuilder_;
|
||||
/**
|
||||
* <code>optional .grpc.testing.ServerConfig setup = 1;</code>
|
||||
*/
|
||||
public io.grpc.testing.ServerConfig getSetup() {
|
||||
if (setupBuilder_ == null) {
|
||||
if (argtypeCase_ == 1) {
|
||||
return (io.grpc.testing.ServerConfig) argtype_;
|
||||
}
|
||||
return io.grpc.testing.ServerConfig.getDefaultInstance();
|
||||
} else {
|
||||
if (argtypeCase_ == 1) {
|
||||
return setupBuilder_.getMessage();
|
||||
}
|
||||
return io.grpc.testing.ServerConfig.getDefaultInstance();
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ServerConfig setup = 1;</code>
|
||||
*/
|
||||
public Builder setSetup(io.grpc.testing.ServerConfig value) {
|
||||
if (setupBuilder_ == null) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
argtype_ = value;
|
||||
onChanged();
|
||||
} else {
|
||||
setupBuilder_.setMessage(value);
|
||||
}
|
||||
argtypeCase_ = 1;
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ServerConfig setup = 1;</code>
|
||||
*/
|
||||
public Builder setSetup(
|
||||
io.grpc.testing.ServerConfig.Builder builderForValue) {
|
||||
if (setupBuilder_ == null) {
|
||||
argtype_ = builderForValue.build();
|
||||
onChanged();
|
||||
} else {
|
||||
setupBuilder_.setMessage(builderForValue.build());
|
||||
}
|
||||
argtypeCase_ = 1;
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ServerConfig setup = 1;</code>
|
||||
*/
|
||||
public Builder mergeSetup(io.grpc.testing.ServerConfig value) {
|
||||
if (setupBuilder_ == null) {
|
||||
if (argtypeCase_ == 1 &&
|
||||
argtype_ != io.grpc.testing.ServerConfig.getDefaultInstance()) {
|
||||
argtype_ = io.grpc.testing.ServerConfig.newBuilder((io.grpc.testing.ServerConfig) argtype_)
|
||||
.mergeFrom(value).buildPartial();
|
||||
} else {
|
||||
argtype_ = value;
|
||||
}
|
||||
onChanged();
|
||||
} else {
|
||||
if (argtypeCase_ == 1) {
|
||||
setupBuilder_.mergeFrom(value);
|
||||
}
|
||||
setupBuilder_.setMessage(value);
|
||||
}
|
||||
argtypeCase_ = 1;
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ServerConfig setup = 1;</code>
|
||||
*/
|
||||
public Builder clearSetup() {
|
||||
if (setupBuilder_ == null) {
|
||||
if (argtypeCase_ == 1) {
|
||||
argtypeCase_ = 0;
|
||||
argtype_ = null;
|
||||
onChanged();
|
||||
}
|
||||
} else {
|
||||
if (argtypeCase_ == 1) {
|
||||
argtypeCase_ = 0;
|
||||
argtype_ = null;
|
||||
}
|
||||
setupBuilder_.clear();
|
||||
}
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ServerConfig setup = 1;</code>
|
||||
*/
|
||||
public io.grpc.testing.ServerConfig.Builder getSetupBuilder() {
|
||||
return getSetupFieldBuilder().getBuilder();
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ServerConfig setup = 1;</code>
|
||||
*/
|
||||
public io.grpc.testing.ServerConfigOrBuilder getSetupOrBuilder() {
|
||||
if ((argtypeCase_ == 1) && (setupBuilder_ != null)) {
|
||||
return setupBuilder_.getMessageOrBuilder();
|
||||
} else {
|
||||
if (argtypeCase_ == 1) {
|
||||
return (io.grpc.testing.ServerConfig) argtype_;
|
||||
}
|
||||
return io.grpc.testing.ServerConfig.getDefaultInstance();
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ServerConfig setup = 1;</code>
|
||||
*/
|
||||
private com.google.protobuf.SingleFieldBuilder<
|
||||
io.grpc.testing.ServerConfig, io.grpc.testing.ServerConfig.Builder, io.grpc.testing.ServerConfigOrBuilder>
|
||||
getSetupFieldBuilder() {
|
||||
if (setupBuilder_ == null) {
|
||||
if (!(argtypeCase_ == 1)) {
|
||||
argtype_ = io.grpc.testing.ServerConfig.getDefaultInstance();
|
||||
}
|
||||
setupBuilder_ = new com.google.protobuf.SingleFieldBuilder<
|
||||
io.grpc.testing.ServerConfig, io.grpc.testing.ServerConfig.Builder, io.grpc.testing.ServerConfigOrBuilder>(
|
||||
(io.grpc.testing.ServerConfig) argtype_,
|
||||
getParentForChildren(),
|
||||
isClean());
|
||||
argtype_ = null;
|
||||
}
|
||||
argtypeCase_ = 1;
|
||||
onChanged();;
|
||||
return setupBuilder_;
|
||||
}
|
||||
|
||||
private com.google.protobuf.SingleFieldBuilder<
|
||||
io.grpc.testing.Mark, io.grpc.testing.Mark.Builder, io.grpc.testing.MarkOrBuilder> markBuilder_;
|
||||
/**
|
||||
* <code>optional .grpc.testing.Mark mark = 2;</code>
|
||||
*/
|
||||
public io.grpc.testing.Mark getMark() {
|
||||
if (markBuilder_ == null) {
|
||||
if (argtypeCase_ == 2) {
|
||||
return (io.grpc.testing.Mark) argtype_;
|
||||
}
|
||||
return io.grpc.testing.Mark.getDefaultInstance();
|
||||
} else {
|
||||
if (argtypeCase_ == 2) {
|
||||
return markBuilder_.getMessage();
|
||||
}
|
||||
return io.grpc.testing.Mark.getDefaultInstance();
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.Mark mark = 2;</code>
|
||||
*/
|
||||
public Builder setMark(io.grpc.testing.Mark value) {
|
||||
if (markBuilder_ == null) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
argtype_ = value;
|
||||
onChanged();
|
||||
} else {
|
||||
markBuilder_.setMessage(value);
|
||||
}
|
||||
argtypeCase_ = 2;
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.Mark mark = 2;</code>
|
||||
*/
|
||||
public Builder setMark(
|
||||
io.grpc.testing.Mark.Builder builderForValue) {
|
||||
if (markBuilder_ == null) {
|
||||
argtype_ = builderForValue.build();
|
||||
onChanged();
|
||||
} else {
|
||||
markBuilder_.setMessage(builderForValue.build());
|
||||
}
|
||||
argtypeCase_ = 2;
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.Mark mark = 2;</code>
|
||||
*/
|
||||
public Builder mergeMark(io.grpc.testing.Mark value) {
|
||||
if (markBuilder_ == null) {
|
||||
if (argtypeCase_ == 2 &&
|
||||
argtype_ != io.grpc.testing.Mark.getDefaultInstance()) {
|
||||
argtype_ = io.grpc.testing.Mark.newBuilder((io.grpc.testing.Mark) argtype_)
|
||||
.mergeFrom(value).buildPartial();
|
||||
} else {
|
||||
argtype_ = value;
|
||||
}
|
||||
onChanged();
|
||||
} else {
|
||||
if (argtypeCase_ == 2) {
|
||||
markBuilder_.mergeFrom(value);
|
||||
}
|
||||
markBuilder_.setMessage(value);
|
||||
}
|
||||
argtypeCase_ = 2;
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.Mark mark = 2;</code>
|
||||
*/
|
||||
public Builder clearMark() {
|
||||
if (markBuilder_ == null) {
|
||||
if (argtypeCase_ == 2) {
|
||||
argtypeCase_ = 0;
|
||||
argtype_ = null;
|
||||
onChanged();
|
||||
}
|
||||
} else {
|
||||
if (argtypeCase_ == 2) {
|
||||
argtypeCase_ = 0;
|
||||
argtype_ = null;
|
||||
}
|
||||
markBuilder_.clear();
|
||||
}
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.Mark mark = 2;</code>
|
||||
*/
|
||||
public io.grpc.testing.Mark.Builder getMarkBuilder() {
|
||||
return getMarkFieldBuilder().getBuilder();
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.Mark mark = 2;</code>
|
||||
*/
|
||||
public io.grpc.testing.MarkOrBuilder getMarkOrBuilder() {
|
||||
if ((argtypeCase_ == 2) && (markBuilder_ != null)) {
|
||||
return markBuilder_.getMessageOrBuilder();
|
||||
} else {
|
||||
if (argtypeCase_ == 2) {
|
||||
return (io.grpc.testing.Mark) argtype_;
|
||||
}
|
||||
return io.grpc.testing.Mark.getDefaultInstance();
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.Mark mark = 2;</code>
|
||||
*/
|
||||
private com.google.protobuf.SingleFieldBuilder<
|
||||
io.grpc.testing.Mark, io.grpc.testing.Mark.Builder, io.grpc.testing.MarkOrBuilder>
|
||||
getMarkFieldBuilder() {
|
||||
if (markBuilder_ == null) {
|
||||
if (!(argtypeCase_ == 2)) {
|
||||
argtype_ = io.grpc.testing.Mark.getDefaultInstance();
|
||||
}
|
||||
markBuilder_ = new com.google.protobuf.SingleFieldBuilder<
|
||||
io.grpc.testing.Mark, io.grpc.testing.Mark.Builder, io.grpc.testing.MarkOrBuilder>(
|
||||
(io.grpc.testing.Mark) argtype_,
|
||||
getParentForChildren(),
|
||||
isClean());
|
||||
argtype_ = null;
|
||||
}
|
||||
argtypeCase_ = 2;
|
||||
onChanged();;
|
||||
return markBuilder_;
|
||||
}
|
||||
public final Builder setUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return this;
|
||||
}
|
||||
|
||||
public final Builder mergeUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return this;
|
||||
}
|
||||
|
||||
|
||||
// @@protoc_insertion_point(builder_scope:grpc.testing.ServerArgs)
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(class_scope:grpc.testing.ServerArgs)
|
||||
private static final io.grpc.testing.ServerArgs DEFAULT_INSTANCE;
|
||||
static {
|
||||
DEFAULT_INSTANCE = new io.grpc.testing.ServerArgs();
|
||||
}
|
||||
|
||||
public static io.grpc.testing.ServerArgs getDefaultInstance() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
private static final com.google.protobuf.Parser<ServerArgs>
|
||||
PARSER = new com.google.protobuf.AbstractParser<ServerArgs>() {
|
||||
public ServerArgs parsePartialFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
try {
|
||||
return new ServerArgs(input, extensionRegistry);
|
||||
} catch (RuntimeException e) {
|
||||
if (e.getCause() instanceof
|
||||
com.google.protobuf.InvalidProtocolBufferException) {
|
||||
throw (com.google.protobuf.InvalidProtocolBufferException)
|
||||
e.getCause();
|
||||
}
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
public static com.google.protobuf.Parser<ServerArgs> parser() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.Parser<ServerArgs> getParserForType() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
public io.grpc.testing.ServerArgs getDefaultInstanceForType() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
|
@ -1,29 +0,0 @@
|
|||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: qpstest.proto
|
||||
|
||||
package io.grpc.testing;
|
||||
|
||||
public interface ServerArgsOrBuilder extends
|
||||
// @@protoc_insertion_point(interface_extends:grpc.testing.ServerArgs)
|
||||
com.google.protobuf.MessageOrBuilder {
|
||||
|
||||
/**
|
||||
* <code>optional .grpc.testing.ServerConfig setup = 1;</code>
|
||||
*/
|
||||
io.grpc.testing.ServerConfig getSetup();
|
||||
/**
|
||||
* <code>optional .grpc.testing.ServerConfig setup = 1;</code>
|
||||
*/
|
||||
io.grpc.testing.ServerConfigOrBuilder getSetupOrBuilder();
|
||||
|
||||
/**
|
||||
* <code>optional .grpc.testing.Mark mark = 2;</code>
|
||||
*/
|
||||
io.grpc.testing.Mark getMark();
|
||||
/**
|
||||
* <code>optional .grpc.testing.Mark mark = 2;</code>
|
||||
*/
|
||||
io.grpc.testing.MarkOrBuilder getMarkOrBuilder();
|
||||
|
||||
public io.grpc.testing.ServerArgs.ArgtypeCase getArgtypeCase();
|
||||
}
|
||||
|
|
@ -1,505 +0,0 @@
|
|||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: qpstest.proto
|
||||
|
||||
package io.grpc.testing;
|
||||
|
||||
/**
|
||||
* Protobuf type {@code grpc.testing.ServerConfig}
|
||||
*/
|
||||
public final class ServerConfig extends
|
||||
com.google.protobuf.GeneratedMessage implements
|
||||
// @@protoc_insertion_point(message_implements:grpc.testing.ServerConfig)
|
||||
ServerConfigOrBuilder {
|
||||
// Use ServerConfig.newBuilder() to construct.
|
||||
private ServerConfig(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
|
||||
super(builder);
|
||||
}
|
||||
private ServerConfig() {
|
||||
serverType_ = 0;
|
||||
threads_ = 0;
|
||||
enableSsl_ = false;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public final com.google.protobuf.UnknownFieldSet
|
||||
getUnknownFields() {
|
||||
return com.google.protobuf.UnknownFieldSet.getDefaultInstance();
|
||||
}
|
||||
private ServerConfig(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry) {
|
||||
this();
|
||||
int mutable_bitField0_ = 0;
|
||||
try {
|
||||
boolean done = false;
|
||||
while (!done) {
|
||||
int tag = input.readTag();
|
||||
switch (tag) {
|
||||
case 0:
|
||||
done = true;
|
||||
break;
|
||||
default: {
|
||||
if (!input.skipField(tag)) {
|
||||
done = true;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case 8: {
|
||||
int rawValue = input.readEnum();
|
||||
|
||||
serverType_ = rawValue;
|
||||
break;
|
||||
}
|
||||
case 16: {
|
||||
|
||||
threads_ = input.readInt32();
|
||||
break;
|
||||
}
|
||||
case 24: {
|
||||
|
||||
enableSsl_ = input.readBool();
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
throw new RuntimeException(e.setUnfinishedMessage(this));
|
||||
} catch (java.io.IOException e) {
|
||||
throw new RuntimeException(
|
||||
new com.google.protobuf.InvalidProtocolBufferException(
|
||||
e.getMessage()).setUnfinishedMessage(this));
|
||||
} finally {
|
||||
makeExtensionsImmutable();
|
||||
}
|
||||
}
|
||||
public static final com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptor() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ServerConfig_descriptor;
|
||||
}
|
||||
|
||||
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ServerConfig_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
io.grpc.testing.ServerConfig.class, io.grpc.testing.ServerConfig.Builder.class);
|
||||
}
|
||||
|
||||
public static final int SERVER_TYPE_FIELD_NUMBER = 1;
|
||||
private int serverType_;
|
||||
/**
|
||||
* <code>optional .grpc.testing.ServerType server_type = 1;</code>
|
||||
*/
|
||||
public int getServerTypeValue() {
|
||||
return serverType_;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ServerType server_type = 1;</code>
|
||||
*/
|
||||
public io.grpc.testing.ServerType getServerType() {
|
||||
io.grpc.testing.ServerType result = io.grpc.testing.ServerType.valueOf(serverType_);
|
||||
return result == null ? io.grpc.testing.ServerType.UNRECOGNIZED : result;
|
||||
}
|
||||
|
||||
public static final int THREADS_FIELD_NUMBER = 2;
|
||||
private int threads_;
|
||||
/**
|
||||
* <code>optional int32 threads = 2;</code>
|
||||
*/
|
||||
public int getThreads() {
|
||||
return threads_;
|
||||
}
|
||||
|
||||
public static final int ENABLE_SSL_FIELD_NUMBER = 3;
|
||||
private boolean enableSsl_;
|
||||
/**
|
||||
* <code>optional bool enable_ssl = 3;</code>
|
||||
*/
|
||||
public boolean getEnableSsl() {
|
||||
return enableSsl_;
|
||||
}
|
||||
|
||||
private byte memoizedIsInitialized = -1;
|
||||
public final boolean isInitialized() {
|
||||
byte isInitialized = memoizedIsInitialized;
|
||||
if (isInitialized == 1) return true;
|
||||
if (isInitialized == 0) return false;
|
||||
|
||||
memoizedIsInitialized = 1;
|
||||
return true;
|
||||
}
|
||||
|
||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
||||
throws java.io.IOException {
|
||||
if (serverType_ != io.grpc.testing.ServerType.SYNCHRONOUS_SERVER.getNumber()) {
|
||||
output.writeEnum(1, serverType_);
|
||||
}
|
||||
if (threads_ != 0) {
|
||||
output.writeInt32(2, threads_);
|
||||
}
|
||||
if (enableSsl_ != false) {
|
||||
output.writeBool(3, enableSsl_);
|
||||
}
|
||||
}
|
||||
|
||||
public int getSerializedSize() {
|
||||
int size = memoizedSize;
|
||||
if (size != -1) return size;
|
||||
|
||||
size = 0;
|
||||
if (serverType_ != io.grpc.testing.ServerType.SYNCHRONOUS_SERVER.getNumber()) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeEnumSize(1, serverType_);
|
||||
}
|
||||
if (threads_ != 0) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeInt32Size(2, threads_);
|
||||
}
|
||||
if (enableSsl_ != false) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeBoolSize(3, enableSsl_);
|
||||
}
|
||||
memoizedSize = size;
|
||||
return size;
|
||||
}
|
||||
|
||||
private static final long serialVersionUID = 0L;
|
||||
public static io.grpc.testing.ServerConfig parseFrom(
|
||||
com.google.protobuf.ByteString data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static io.grpc.testing.ServerConfig parseFrom(
|
||||
com.google.protobuf.ByteString data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.ServerConfig parseFrom(byte[] data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static io.grpc.testing.ServerConfig parseFrom(
|
||||
byte[] data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.ServerConfig parseFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.ServerConfig parseFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.ServerConfig parseDelimitedFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseDelimitedFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.ServerConfig parseDelimitedFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseDelimitedFrom(input, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.ServerConfig parseFrom(
|
||||
com.google.protobuf.CodedInputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.ServerConfig parseFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input, extensionRegistry);
|
||||
}
|
||||
|
||||
public Builder newBuilderForType() { return newBuilder(); }
|
||||
public static Builder newBuilder() {
|
||||
return DEFAULT_INSTANCE.toBuilder();
|
||||
}
|
||||
public static Builder newBuilder(io.grpc.testing.ServerConfig prototype) {
|
||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
||||
}
|
||||
public Builder toBuilder() {
|
||||
return this == DEFAULT_INSTANCE
|
||||
? new Builder() : new Builder().mergeFrom(this);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected Builder newBuilderForType(
|
||||
com.google.protobuf.GeneratedMessage.BuilderParent parent) {
|
||||
Builder builder = new Builder(parent);
|
||||
return builder;
|
||||
}
|
||||
/**
|
||||
* Protobuf type {@code grpc.testing.ServerConfig}
|
||||
*/
|
||||
public static final class Builder extends
|
||||
com.google.protobuf.GeneratedMessage.Builder<Builder> implements
|
||||
// @@protoc_insertion_point(builder_implements:grpc.testing.ServerConfig)
|
||||
io.grpc.testing.ServerConfigOrBuilder {
|
||||
public static final com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptor() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ServerConfig_descriptor;
|
||||
}
|
||||
|
||||
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ServerConfig_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
io.grpc.testing.ServerConfig.class, io.grpc.testing.ServerConfig.Builder.class);
|
||||
}
|
||||
|
||||
// Construct using io.grpc.testing.ServerConfig.newBuilder()
|
||||
private Builder() {
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
|
||||
private Builder(
|
||||
com.google.protobuf.GeneratedMessage.BuilderParent parent) {
|
||||
super(parent);
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
private void maybeForceBuilderInitialization() {
|
||||
if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
|
||||
}
|
||||
}
|
||||
public Builder clear() {
|
||||
super.clear();
|
||||
serverType_ = 0;
|
||||
|
||||
threads_ = 0;
|
||||
|
||||
enableSsl_ = false;
|
||||
|
||||
return this;
|
||||
}
|
||||
|
||||
public com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptorForType() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ServerConfig_descriptor;
|
||||
}
|
||||
|
||||
public io.grpc.testing.ServerConfig getDefaultInstanceForType() {
|
||||
return io.grpc.testing.ServerConfig.getDefaultInstance();
|
||||
}
|
||||
|
||||
public io.grpc.testing.ServerConfig build() {
|
||||
io.grpc.testing.ServerConfig result = buildPartial();
|
||||
if (!result.isInitialized()) {
|
||||
throw newUninitializedMessageException(result);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
public io.grpc.testing.ServerConfig buildPartial() {
|
||||
io.grpc.testing.ServerConfig result = new io.grpc.testing.ServerConfig(this);
|
||||
result.serverType_ = serverType_;
|
||||
result.threads_ = threads_;
|
||||
result.enableSsl_ = enableSsl_;
|
||||
onBuilt();
|
||||
return result;
|
||||
}
|
||||
|
||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
||||
if (other instanceof io.grpc.testing.ServerConfig) {
|
||||
return mergeFrom((io.grpc.testing.ServerConfig)other);
|
||||
} else {
|
||||
super.mergeFrom(other);
|
||||
return this;
|
||||
}
|
||||
}
|
||||
|
||||
public Builder mergeFrom(io.grpc.testing.ServerConfig other) {
|
||||
if (other == io.grpc.testing.ServerConfig.getDefaultInstance()) return this;
|
||||
if (other.serverType_ != 0) {
|
||||
setServerTypeValue(other.getServerTypeValue());
|
||||
}
|
||||
if (other.getThreads() != 0) {
|
||||
setThreads(other.getThreads());
|
||||
}
|
||||
if (other.getEnableSsl() != false) {
|
||||
setEnableSsl(other.getEnableSsl());
|
||||
}
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
public final boolean isInitialized() {
|
||||
return true;
|
||||
}
|
||||
|
||||
public Builder mergeFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
io.grpc.testing.ServerConfig parsedMessage = null;
|
||||
try {
|
||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
parsedMessage = (io.grpc.testing.ServerConfig) e.getUnfinishedMessage();
|
||||
throw e;
|
||||
} finally {
|
||||
if (parsedMessage != null) {
|
||||
mergeFrom(parsedMessage);
|
||||
}
|
||||
}
|
||||
return this;
|
||||
}
|
||||
|
||||
private int serverType_ = 0;
|
||||
/**
|
||||
* <code>optional .grpc.testing.ServerType server_type = 1;</code>
|
||||
*/
|
||||
public int getServerTypeValue() {
|
||||
return serverType_;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ServerType server_type = 1;</code>
|
||||
*/
|
||||
public Builder setServerTypeValue(int value) {
|
||||
serverType_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ServerType server_type = 1;</code>
|
||||
*/
|
||||
public io.grpc.testing.ServerType getServerType() {
|
||||
io.grpc.testing.ServerType result = io.grpc.testing.ServerType.valueOf(serverType_);
|
||||
return result == null ? io.grpc.testing.ServerType.UNRECOGNIZED : result;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ServerType server_type = 1;</code>
|
||||
*/
|
||||
public Builder setServerType(io.grpc.testing.ServerType value) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
|
||||
serverType_ = value.getNumber();
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ServerType server_type = 1;</code>
|
||||
*/
|
||||
public Builder clearServerType() {
|
||||
|
||||
serverType_ = 0;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
private int threads_ ;
|
||||
/**
|
||||
* <code>optional int32 threads = 2;</code>
|
||||
*/
|
||||
public int getThreads() {
|
||||
return threads_;
|
||||
}
|
||||
/**
|
||||
* <code>optional int32 threads = 2;</code>
|
||||
*/
|
||||
public Builder setThreads(int value) {
|
||||
|
||||
threads_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional int32 threads = 2;</code>
|
||||
*/
|
||||
public Builder clearThreads() {
|
||||
|
||||
threads_ = 0;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
private boolean enableSsl_ ;
|
||||
/**
|
||||
* <code>optional bool enable_ssl = 3;</code>
|
||||
*/
|
||||
public boolean getEnableSsl() {
|
||||
return enableSsl_;
|
||||
}
|
||||
/**
|
||||
* <code>optional bool enable_ssl = 3;</code>
|
||||
*/
|
||||
public Builder setEnableSsl(boolean value) {
|
||||
|
||||
enableSsl_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional bool enable_ssl = 3;</code>
|
||||
*/
|
||||
public Builder clearEnableSsl() {
|
||||
|
||||
enableSsl_ = false;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
public final Builder setUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return this;
|
||||
}
|
||||
|
||||
public final Builder mergeUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return this;
|
||||
}
|
||||
|
||||
|
||||
// @@protoc_insertion_point(builder_scope:grpc.testing.ServerConfig)
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(class_scope:grpc.testing.ServerConfig)
|
||||
private static final io.grpc.testing.ServerConfig DEFAULT_INSTANCE;
|
||||
static {
|
||||
DEFAULT_INSTANCE = new io.grpc.testing.ServerConfig();
|
||||
}
|
||||
|
||||
public static io.grpc.testing.ServerConfig getDefaultInstance() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
private static final com.google.protobuf.Parser<ServerConfig>
|
||||
PARSER = new com.google.protobuf.AbstractParser<ServerConfig>() {
|
||||
public ServerConfig parsePartialFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
try {
|
||||
return new ServerConfig(input, extensionRegistry);
|
||||
} catch (RuntimeException e) {
|
||||
if (e.getCause() instanceof
|
||||
com.google.protobuf.InvalidProtocolBufferException) {
|
||||
throw (com.google.protobuf.InvalidProtocolBufferException)
|
||||
e.getCause();
|
||||
}
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
public static com.google.protobuf.Parser<ServerConfig> parser() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.Parser<ServerConfig> getParserForType() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
public io.grpc.testing.ServerConfig getDefaultInstanceForType() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
|
@ -1,28 +0,0 @@
|
|||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: qpstest.proto
|
||||
|
||||
package io.grpc.testing;
|
||||
|
||||
public interface ServerConfigOrBuilder extends
|
||||
// @@protoc_insertion_point(interface_extends:grpc.testing.ServerConfig)
|
||||
com.google.protobuf.MessageOrBuilder {
|
||||
|
||||
/**
|
||||
* <code>optional .grpc.testing.ServerType server_type = 1;</code>
|
||||
*/
|
||||
int getServerTypeValue();
|
||||
/**
|
||||
* <code>optional .grpc.testing.ServerType server_type = 1;</code>
|
||||
*/
|
||||
io.grpc.testing.ServerType getServerType();
|
||||
|
||||
/**
|
||||
* <code>optional int32 threads = 2;</code>
|
||||
*/
|
||||
int getThreads();
|
||||
|
||||
/**
|
||||
* <code>optional bool enable_ssl = 3;</code>
|
||||
*/
|
||||
boolean getEnableSsl();
|
||||
}
|
||||
|
|
@ -1,527 +0,0 @@
|
|||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: qpstest.proto
|
||||
|
||||
package io.grpc.testing;
|
||||
|
||||
/**
|
||||
* Protobuf type {@code grpc.testing.ServerStats}
|
||||
*/
|
||||
public final class ServerStats extends
|
||||
com.google.protobuf.GeneratedMessage implements
|
||||
// @@protoc_insertion_point(message_implements:grpc.testing.ServerStats)
|
||||
ServerStatsOrBuilder {
|
||||
// Use ServerStats.newBuilder() to construct.
|
||||
private ServerStats(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
|
||||
super(builder);
|
||||
}
|
||||
private ServerStats() {
|
||||
timeElapsed_ = 0D;
|
||||
timeUser_ = 0D;
|
||||
timeSystem_ = 0D;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public final com.google.protobuf.UnknownFieldSet
|
||||
getUnknownFields() {
|
||||
return com.google.protobuf.UnknownFieldSet.getDefaultInstance();
|
||||
}
|
||||
private ServerStats(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry) {
|
||||
this();
|
||||
int mutable_bitField0_ = 0;
|
||||
try {
|
||||
boolean done = false;
|
||||
while (!done) {
|
||||
int tag = input.readTag();
|
||||
switch (tag) {
|
||||
case 0:
|
||||
done = true;
|
||||
break;
|
||||
default: {
|
||||
if (!input.skipField(tag)) {
|
||||
done = true;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case 9: {
|
||||
|
||||
timeElapsed_ = input.readDouble();
|
||||
break;
|
||||
}
|
||||
case 17: {
|
||||
|
||||
timeUser_ = input.readDouble();
|
||||
break;
|
||||
}
|
||||
case 25: {
|
||||
|
||||
timeSystem_ = input.readDouble();
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
throw new RuntimeException(e.setUnfinishedMessage(this));
|
||||
} catch (java.io.IOException e) {
|
||||
throw new RuntimeException(
|
||||
new com.google.protobuf.InvalidProtocolBufferException(
|
||||
e.getMessage()).setUnfinishedMessage(this));
|
||||
} finally {
|
||||
makeExtensionsImmutable();
|
||||
}
|
||||
}
|
||||
public static final com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptor() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ServerStats_descriptor;
|
||||
}
|
||||
|
||||
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ServerStats_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
io.grpc.testing.ServerStats.class, io.grpc.testing.ServerStats.Builder.class);
|
||||
}
|
||||
|
||||
public static final int TIME_ELAPSED_FIELD_NUMBER = 1;
|
||||
private double timeElapsed_;
|
||||
/**
|
||||
* <code>optional double time_elapsed = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
* wall clock time
|
||||
* </pre>
|
||||
*/
|
||||
public double getTimeElapsed() {
|
||||
return timeElapsed_;
|
||||
}
|
||||
|
||||
public static final int TIME_USER_FIELD_NUMBER = 2;
|
||||
private double timeUser_;
|
||||
/**
|
||||
* <code>optional double time_user = 2;</code>
|
||||
*
|
||||
* <pre>
|
||||
* user time used by the server process and threads
|
||||
* </pre>
|
||||
*/
|
||||
public double getTimeUser() {
|
||||
return timeUser_;
|
||||
}
|
||||
|
||||
public static final int TIME_SYSTEM_FIELD_NUMBER = 3;
|
||||
private double timeSystem_;
|
||||
/**
|
||||
* <code>optional double time_system = 3;</code>
|
||||
*
|
||||
* <pre>
|
||||
* server time used by the server process and all threads
|
||||
* </pre>
|
||||
*/
|
||||
public double getTimeSystem() {
|
||||
return timeSystem_;
|
||||
}
|
||||
|
||||
private byte memoizedIsInitialized = -1;
|
||||
public final boolean isInitialized() {
|
||||
byte isInitialized = memoizedIsInitialized;
|
||||
if (isInitialized == 1) return true;
|
||||
if (isInitialized == 0) return false;
|
||||
|
||||
memoizedIsInitialized = 1;
|
||||
return true;
|
||||
}
|
||||
|
||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
||||
throws java.io.IOException {
|
||||
if (timeElapsed_ != 0D) {
|
||||
output.writeDouble(1, timeElapsed_);
|
||||
}
|
||||
if (timeUser_ != 0D) {
|
||||
output.writeDouble(2, timeUser_);
|
||||
}
|
||||
if (timeSystem_ != 0D) {
|
||||
output.writeDouble(3, timeSystem_);
|
||||
}
|
||||
}
|
||||
|
||||
public int getSerializedSize() {
|
||||
int size = memoizedSize;
|
||||
if (size != -1) return size;
|
||||
|
||||
size = 0;
|
||||
if (timeElapsed_ != 0D) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeDoubleSize(1, timeElapsed_);
|
||||
}
|
||||
if (timeUser_ != 0D) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeDoubleSize(2, timeUser_);
|
||||
}
|
||||
if (timeSystem_ != 0D) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeDoubleSize(3, timeSystem_);
|
||||
}
|
||||
memoizedSize = size;
|
||||
return size;
|
||||
}
|
||||
|
||||
private static final long serialVersionUID = 0L;
|
||||
public static io.grpc.testing.ServerStats parseFrom(
|
||||
com.google.protobuf.ByteString data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static io.grpc.testing.ServerStats parseFrom(
|
||||
com.google.protobuf.ByteString data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.ServerStats parseFrom(byte[] data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static io.grpc.testing.ServerStats parseFrom(
|
||||
byte[] data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.ServerStats parseFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.ServerStats parseFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.ServerStats parseDelimitedFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseDelimitedFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.ServerStats parseDelimitedFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseDelimitedFrom(input, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.ServerStats parseFrom(
|
||||
com.google.protobuf.CodedInputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.ServerStats parseFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input, extensionRegistry);
|
||||
}
|
||||
|
||||
public Builder newBuilderForType() { return newBuilder(); }
|
||||
public static Builder newBuilder() {
|
||||
return DEFAULT_INSTANCE.toBuilder();
|
||||
}
|
||||
public static Builder newBuilder(io.grpc.testing.ServerStats prototype) {
|
||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
||||
}
|
||||
public Builder toBuilder() {
|
||||
return this == DEFAULT_INSTANCE
|
||||
? new Builder() : new Builder().mergeFrom(this);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected Builder newBuilderForType(
|
||||
com.google.protobuf.GeneratedMessage.BuilderParent parent) {
|
||||
Builder builder = new Builder(parent);
|
||||
return builder;
|
||||
}
|
||||
/**
|
||||
* Protobuf type {@code grpc.testing.ServerStats}
|
||||
*/
|
||||
public static final class Builder extends
|
||||
com.google.protobuf.GeneratedMessage.Builder<Builder> implements
|
||||
// @@protoc_insertion_point(builder_implements:grpc.testing.ServerStats)
|
||||
io.grpc.testing.ServerStatsOrBuilder {
|
||||
public static final com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptor() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ServerStats_descriptor;
|
||||
}
|
||||
|
||||
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ServerStats_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
io.grpc.testing.ServerStats.class, io.grpc.testing.ServerStats.Builder.class);
|
||||
}
|
||||
|
||||
// Construct using io.grpc.testing.ServerStats.newBuilder()
|
||||
private Builder() {
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
|
||||
private Builder(
|
||||
com.google.protobuf.GeneratedMessage.BuilderParent parent) {
|
||||
super(parent);
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
private void maybeForceBuilderInitialization() {
|
||||
if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
|
||||
}
|
||||
}
|
||||
public Builder clear() {
|
||||
super.clear();
|
||||
timeElapsed_ = 0D;
|
||||
|
||||
timeUser_ = 0D;
|
||||
|
||||
timeSystem_ = 0D;
|
||||
|
||||
return this;
|
||||
}
|
||||
|
||||
public com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptorForType() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ServerStats_descriptor;
|
||||
}
|
||||
|
||||
public io.grpc.testing.ServerStats getDefaultInstanceForType() {
|
||||
return io.grpc.testing.ServerStats.getDefaultInstance();
|
||||
}
|
||||
|
||||
public io.grpc.testing.ServerStats build() {
|
||||
io.grpc.testing.ServerStats result = buildPartial();
|
||||
if (!result.isInitialized()) {
|
||||
throw newUninitializedMessageException(result);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
public io.grpc.testing.ServerStats buildPartial() {
|
||||
io.grpc.testing.ServerStats result = new io.grpc.testing.ServerStats(this);
|
||||
result.timeElapsed_ = timeElapsed_;
|
||||
result.timeUser_ = timeUser_;
|
||||
result.timeSystem_ = timeSystem_;
|
||||
onBuilt();
|
||||
return result;
|
||||
}
|
||||
|
||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
||||
if (other instanceof io.grpc.testing.ServerStats) {
|
||||
return mergeFrom((io.grpc.testing.ServerStats)other);
|
||||
} else {
|
||||
super.mergeFrom(other);
|
||||
return this;
|
||||
}
|
||||
}
|
||||
|
||||
public Builder mergeFrom(io.grpc.testing.ServerStats other) {
|
||||
if (other == io.grpc.testing.ServerStats.getDefaultInstance()) return this;
|
||||
if (other.getTimeElapsed() != 0D) {
|
||||
setTimeElapsed(other.getTimeElapsed());
|
||||
}
|
||||
if (other.getTimeUser() != 0D) {
|
||||
setTimeUser(other.getTimeUser());
|
||||
}
|
||||
if (other.getTimeSystem() != 0D) {
|
||||
setTimeSystem(other.getTimeSystem());
|
||||
}
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
public final boolean isInitialized() {
|
||||
return true;
|
||||
}
|
||||
|
||||
public Builder mergeFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
io.grpc.testing.ServerStats parsedMessage = null;
|
||||
try {
|
||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
parsedMessage = (io.grpc.testing.ServerStats) e.getUnfinishedMessage();
|
||||
throw e;
|
||||
} finally {
|
||||
if (parsedMessage != null) {
|
||||
mergeFrom(parsedMessage);
|
||||
}
|
||||
}
|
||||
return this;
|
||||
}
|
||||
|
||||
private double timeElapsed_ ;
|
||||
/**
|
||||
* <code>optional double time_elapsed = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
* wall clock time
|
||||
* </pre>
|
||||
*/
|
||||
public double getTimeElapsed() {
|
||||
return timeElapsed_;
|
||||
}
|
||||
/**
|
||||
* <code>optional double time_elapsed = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
* wall clock time
|
||||
* </pre>
|
||||
*/
|
||||
public Builder setTimeElapsed(double value) {
|
||||
|
||||
timeElapsed_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional double time_elapsed = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
* wall clock time
|
||||
* </pre>
|
||||
*/
|
||||
public Builder clearTimeElapsed() {
|
||||
|
||||
timeElapsed_ = 0D;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
private double timeUser_ ;
|
||||
/**
|
||||
* <code>optional double time_user = 2;</code>
|
||||
*
|
||||
* <pre>
|
||||
* user time used by the server process and threads
|
||||
* </pre>
|
||||
*/
|
||||
public double getTimeUser() {
|
||||
return timeUser_;
|
||||
}
|
||||
/**
|
||||
* <code>optional double time_user = 2;</code>
|
||||
*
|
||||
* <pre>
|
||||
* user time used by the server process and threads
|
||||
* </pre>
|
||||
*/
|
||||
public Builder setTimeUser(double value) {
|
||||
|
||||
timeUser_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional double time_user = 2;</code>
|
||||
*
|
||||
* <pre>
|
||||
* user time used by the server process and threads
|
||||
* </pre>
|
||||
*/
|
||||
public Builder clearTimeUser() {
|
||||
|
||||
timeUser_ = 0D;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
private double timeSystem_ ;
|
||||
/**
|
||||
* <code>optional double time_system = 3;</code>
|
||||
*
|
||||
* <pre>
|
||||
* server time used by the server process and all threads
|
||||
* </pre>
|
||||
*/
|
||||
public double getTimeSystem() {
|
||||
return timeSystem_;
|
||||
}
|
||||
/**
|
||||
* <code>optional double time_system = 3;</code>
|
||||
*
|
||||
* <pre>
|
||||
* server time used by the server process and all threads
|
||||
* </pre>
|
||||
*/
|
||||
public Builder setTimeSystem(double value) {
|
||||
|
||||
timeSystem_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional double time_system = 3;</code>
|
||||
*
|
||||
* <pre>
|
||||
* server time used by the server process and all threads
|
||||
* </pre>
|
||||
*/
|
||||
public Builder clearTimeSystem() {
|
||||
|
||||
timeSystem_ = 0D;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
public final Builder setUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return this;
|
||||
}
|
||||
|
||||
public final Builder mergeUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return this;
|
||||
}
|
||||
|
||||
|
||||
// @@protoc_insertion_point(builder_scope:grpc.testing.ServerStats)
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(class_scope:grpc.testing.ServerStats)
|
||||
private static final io.grpc.testing.ServerStats DEFAULT_INSTANCE;
|
||||
static {
|
||||
DEFAULT_INSTANCE = new io.grpc.testing.ServerStats();
|
||||
}
|
||||
|
||||
public static io.grpc.testing.ServerStats getDefaultInstance() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
private static final com.google.protobuf.Parser<ServerStats>
|
||||
PARSER = new com.google.protobuf.AbstractParser<ServerStats>() {
|
||||
public ServerStats parsePartialFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
try {
|
||||
return new ServerStats(input, extensionRegistry);
|
||||
} catch (RuntimeException e) {
|
||||
if (e.getCause() instanceof
|
||||
com.google.protobuf.InvalidProtocolBufferException) {
|
||||
throw (com.google.protobuf.InvalidProtocolBufferException)
|
||||
e.getCause();
|
||||
}
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
public static com.google.protobuf.Parser<ServerStats> parser() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.Parser<ServerStats> getParserForType() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
public io.grpc.testing.ServerStats getDefaultInstanceForType() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
|
@ -1,36 +0,0 @@
|
|||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: qpstest.proto
|
||||
|
||||
package io.grpc.testing;
|
||||
|
||||
public interface ServerStatsOrBuilder extends
|
||||
// @@protoc_insertion_point(interface_extends:grpc.testing.ServerStats)
|
||||
com.google.protobuf.MessageOrBuilder {
|
||||
|
||||
/**
|
||||
* <code>optional double time_elapsed = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
* wall clock time
|
||||
* </pre>
|
||||
*/
|
||||
double getTimeElapsed();
|
||||
|
||||
/**
|
||||
* <code>optional double time_user = 2;</code>
|
||||
*
|
||||
* <pre>
|
||||
* user time used by the server process and threads
|
||||
* </pre>
|
||||
*/
|
||||
double getTimeUser();
|
||||
|
||||
/**
|
||||
* <code>optional double time_system = 3;</code>
|
||||
*
|
||||
* <pre>
|
||||
* server time used by the server process and all threads
|
||||
* </pre>
|
||||
*/
|
||||
double getTimeSystem();
|
||||
}
|
||||
|
|
@ -1,543 +0,0 @@
|
|||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: qpstest.proto
|
||||
|
||||
package io.grpc.testing;
|
||||
|
||||
/**
|
||||
* Protobuf type {@code grpc.testing.ServerStatus}
|
||||
*/
|
||||
public final class ServerStatus extends
|
||||
com.google.protobuf.GeneratedMessage implements
|
||||
// @@protoc_insertion_point(message_implements:grpc.testing.ServerStatus)
|
||||
ServerStatusOrBuilder {
|
||||
// Use ServerStatus.newBuilder() to construct.
|
||||
private ServerStatus(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
|
||||
super(builder);
|
||||
}
|
||||
private ServerStatus() {
|
||||
port_ = 0;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public final com.google.protobuf.UnknownFieldSet
|
||||
getUnknownFields() {
|
||||
return com.google.protobuf.UnknownFieldSet.getDefaultInstance();
|
||||
}
|
||||
private ServerStatus(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry) {
|
||||
this();
|
||||
int mutable_bitField0_ = 0;
|
||||
try {
|
||||
boolean done = false;
|
||||
while (!done) {
|
||||
int tag = input.readTag();
|
||||
switch (tag) {
|
||||
case 0:
|
||||
done = true;
|
||||
break;
|
||||
default: {
|
||||
if (!input.skipField(tag)) {
|
||||
done = true;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case 10: {
|
||||
io.grpc.testing.ServerStats.Builder subBuilder = null;
|
||||
if (stats_ != null) {
|
||||
subBuilder = stats_.toBuilder();
|
||||
}
|
||||
stats_ = input.readMessage(io.grpc.testing.ServerStats.parser(), extensionRegistry);
|
||||
if (subBuilder != null) {
|
||||
subBuilder.mergeFrom(stats_);
|
||||
stats_ = subBuilder.buildPartial();
|
||||
}
|
||||
|
||||
break;
|
||||
}
|
||||
case 16: {
|
||||
|
||||
port_ = input.readInt32();
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
throw new RuntimeException(e.setUnfinishedMessage(this));
|
||||
} catch (java.io.IOException e) {
|
||||
throw new RuntimeException(
|
||||
new com.google.protobuf.InvalidProtocolBufferException(
|
||||
e.getMessage()).setUnfinishedMessage(this));
|
||||
} finally {
|
||||
makeExtensionsImmutable();
|
||||
}
|
||||
}
|
||||
public static final com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptor() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ServerStatus_descriptor;
|
||||
}
|
||||
|
||||
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ServerStatus_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
io.grpc.testing.ServerStatus.class, io.grpc.testing.ServerStatus.Builder.class);
|
||||
}
|
||||
|
||||
public static final int STATS_FIELD_NUMBER = 1;
|
||||
private io.grpc.testing.ServerStats stats_;
|
||||
/**
|
||||
* <code>optional .grpc.testing.ServerStats stats = 1;</code>
|
||||
*/
|
||||
public boolean hasStats() {
|
||||
return stats_ != null;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ServerStats stats = 1;</code>
|
||||
*/
|
||||
public io.grpc.testing.ServerStats getStats() {
|
||||
return stats_ == null ? io.grpc.testing.ServerStats.getDefaultInstance() : stats_;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ServerStats stats = 1;</code>
|
||||
*/
|
||||
public io.grpc.testing.ServerStatsOrBuilder getStatsOrBuilder() {
|
||||
return getStats();
|
||||
}
|
||||
|
||||
public static final int PORT_FIELD_NUMBER = 2;
|
||||
private int port_;
|
||||
/**
|
||||
* <code>optional int32 port = 2;</code>
|
||||
*/
|
||||
public int getPort() {
|
||||
return port_;
|
||||
}
|
||||
|
||||
private byte memoizedIsInitialized = -1;
|
||||
public final boolean isInitialized() {
|
||||
byte isInitialized = memoizedIsInitialized;
|
||||
if (isInitialized == 1) return true;
|
||||
if (isInitialized == 0) return false;
|
||||
|
||||
memoizedIsInitialized = 1;
|
||||
return true;
|
||||
}
|
||||
|
||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
||||
throws java.io.IOException {
|
||||
if (stats_ != null) {
|
||||
output.writeMessage(1, getStats());
|
||||
}
|
||||
if (port_ != 0) {
|
||||
output.writeInt32(2, port_);
|
||||
}
|
||||
}
|
||||
|
||||
public int getSerializedSize() {
|
||||
int size = memoizedSize;
|
||||
if (size != -1) return size;
|
||||
|
||||
size = 0;
|
||||
if (stats_ != null) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeMessageSize(1, getStats());
|
||||
}
|
||||
if (port_ != 0) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeInt32Size(2, port_);
|
||||
}
|
||||
memoizedSize = size;
|
||||
return size;
|
||||
}
|
||||
|
||||
private static final long serialVersionUID = 0L;
|
||||
public static io.grpc.testing.ServerStatus parseFrom(
|
||||
com.google.protobuf.ByteString data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static io.grpc.testing.ServerStatus parseFrom(
|
||||
com.google.protobuf.ByteString data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.ServerStatus parseFrom(byte[] data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static io.grpc.testing.ServerStatus parseFrom(
|
||||
byte[] data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.ServerStatus parseFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.ServerStatus parseFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.ServerStatus parseDelimitedFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseDelimitedFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.ServerStatus parseDelimitedFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseDelimitedFrom(input, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.ServerStatus parseFrom(
|
||||
com.google.protobuf.CodedInputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.ServerStatus parseFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input, extensionRegistry);
|
||||
}
|
||||
|
||||
public Builder newBuilderForType() { return newBuilder(); }
|
||||
public static Builder newBuilder() {
|
||||
return DEFAULT_INSTANCE.toBuilder();
|
||||
}
|
||||
public static Builder newBuilder(io.grpc.testing.ServerStatus prototype) {
|
||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
||||
}
|
||||
public Builder toBuilder() {
|
||||
return this == DEFAULT_INSTANCE
|
||||
? new Builder() : new Builder().mergeFrom(this);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected Builder newBuilderForType(
|
||||
com.google.protobuf.GeneratedMessage.BuilderParent parent) {
|
||||
Builder builder = new Builder(parent);
|
||||
return builder;
|
||||
}
|
||||
/**
|
||||
* Protobuf type {@code grpc.testing.ServerStatus}
|
||||
*/
|
||||
public static final class Builder extends
|
||||
com.google.protobuf.GeneratedMessage.Builder<Builder> implements
|
||||
// @@protoc_insertion_point(builder_implements:grpc.testing.ServerStatus)
|
||||
io.grpc.testing.ServerStatusOrBuilder {
|
||||
public static final com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptor() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ServerStatus_descriptor;
|
||||
}
|
||||
|
||||
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ServerStatus_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
io.grpc.testing.ServerStatus.class, io.grpc.testing.ServerStatus.Builder.class);
|
||||
}
|
||||
|
||||
// Construct using io.grpc.testing.ServerStatus.newBuilder()
|
||||
private Builder() {
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
|
||||
private Builder(
|
||||
com.google.protobuf.GeneratedMessage.BuilderParent parent) {
|
||||
super(parent);
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
private void maybeForceBuilderInitialization() {
|
||||
if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
|
||||
}
|
||||
}
|
||||
public Builder clear() {
|
||||
super.clear();
|
||||
if (statsBuilder_ == null) {
|
||||
stats_ = null;
|
||||
} else {
|
||||
stats_ = null;
|
||||
statsBuilder_ = null;
|
||||
}
|
||||
port_ = 0;
|
||||
|
||||
return this;
|
||||
}
|
||||
|
||||
public com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptorForType() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_ServerStatus_descriptor;
|
||||
}
|
||||
|
||||
public io.grpc.testing.ServerStatus getDefaultInstanceForType() {
|
||||
return io.grpc.testing.ServerStatus.getDefaultInstance();
|
||||
}
|
||||
|
||||
public io.grpc.testing.ServerStatus build() {
|
||||
io.grpc.testing.ServerStatus result = buildPartial();
|
||||
if (!result.isInitialized()) {
|
||||
throw newUninitializedMessageException(result);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
public io.grpc.testing.ServerStatus buildPartial() {
|
||||
io.grpc.testing.ServerStatus result = new io.grpc.testing.ServerStatus(this);
|
||||
if (statsBuilder_ == null) {
|
||||
result.stats_ = stats_;
|
||||
} else {
|
||||
result.stats_ = statsBuilder_.build();
|
||||
}
|
||||
result.port_ = port_;
|
||||
onBuilt();
|
||||
return result;
|
||||
}
|
||||
|
||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
||||
if (other instanceof io.grpc.testing.ServerStatus) {
|
||||
return mergeFrom((io.grpc.testing.ServerStatus)other);
|
||||
} else {
|
||||
super.mergeFrom(other);
|
||||
return this;
|
||||
}
|
||||
}
|
||||
|
||||
public Builder mergeFrom(io.grpc.testing.ServerStatus other) {
|
||||
if (other == io.grpc.testing.ServerStatus.getDefaultInstance()) return this;
|
||||
if (other.hasStats()) {
|
||||
mergeStats(other.getStats());
|
||||
}
|
||||
if (other.getPort() != 0) {
|
||||
setPort(other.getPort());
|
||||
}
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
public final boolean isInitialized() {
|
||||
return true;
|
||||
}
|
||||
|
||||
public Builder mergeFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
io.grpc.testing.ServerStatus parsedMessage = null;
|
||||
try {
|
||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
parsedMessage = (io.grpc.testing.ServerStatus) e.getUnfinishedMessage();
|
||||
throw e;
|
||||
} finally {
|
||||
if (parsedMessage != null) {
|
||||
mergeFrom(parsedMessage);
|
||||
}
|
||||
}
|
||||
return this;
|
||||
}
|
||||
|
||||
private io.grpc.testing.ServerStats stats_ = null;
|
||||
private com.google.protobuf.SingleFieldBuilder<
|
||||
io.grpc.testing.ServerStats, io.grpc.testing.ServerStats.Builder, io.grpc.testing.ServerStatsOrBuilder> statsBuilder_;
|
||||
/**
|
||||
* <code>optional .grpc.testing.ServerStats stats = 1;</code>
|
||||
*/
|
||||
public boolean hasStats() {
|
||||
return statsBuilder_ != null || stats_ != null;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ServerStats stats = 1;</code>
|
||||
*/
|
||||
public io.grpc.testing.ServerStats getStats() {
|
||||
if (statsBuilder_ == null) {
|
||||
return stats_ == null ? io.grpc.testing.ServerStats.getDefaultInstance() : stats_;
|
||||
} else {
|
||||
return statsBuilder_.getMessage();
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ServerStats stats = 1;</code>
|
||||
*/
|
||||
public Builder setStats(io.grpc.testing.ServerStats value) {
|
||||
if (statsBuilder_ == null) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
stats_ = value;
|
||||
onChanged();
|
||||
} else {
|
||||
statsBuilder_.setMessage(value);
|
||||
}
|
||||
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ServerStats stats = 1;</code>
|
||||
*/
|
||||
public Builder setStats(
|
||||
io.grpc.testing.ServerStats.Builder builderForValue) {
|
||||
if (statsBuilder_ == null) {
|
||||
stats_ = builderForValue.build();
|
||||
onChanged();
|
||||
} else {
|
||||
statsBuilder_.setMessage(builderForValue.build());
|
||||
}
|
||||
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ServerStats stats = 1;</code>
|
||||
*/
|
||||
public Builder mergeStats(io.grpc.testing.ServerStats value) {
|
||||
if (statsBuilder_ == null) {
|
||||
if (stats_ != null) {
|
||||
stats_ =
|
||||
io.grpc.testing.ServerStats.newBuilder(stats_).mergeFrom(value).buildPartial();
|
||||
} else {
|
||||
stats_ = value;
|
||||
}
|
||||
onChanged();
|
||||
} else {
|
||||
statsBuilder_.mergeFrom(value);
|
||||
}
|
||||
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ServerStats stats = 1;</code>
|
||||
*/
|
||||
public Builder clearStats() {
|
||||
if (statsBuilder_ == null) {
|
||||
stats_ = null;
|
||||
onChanged();
|
||||
} else {
|
||||
stats_ = null;
|
||||
statsBuilder_ = null;
|
||||
}
|
||||
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ServerStats stats = 1;</code>
|
||||
*/
|
||||
public io.grpc.testing.ServerStats.Builder getStatsBuilder() {
|
||||
|
||||
onChanged();
|
||||
return getStatsFieldBuilder().getBuilder();
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ServerStats stats = 1;</code>
|
||||
*/
|
||||
public io.grpc.testing.ServerStatsOrBuilder getStatsOrBuilder() {
|
||||
if (statsBuilder_ != null) {
|
||||
return statsBuilder_.getMessageOrBuilder();
|
||||
} else {
|
||||
return stats_ == null ?
|
||||
io.grpc.testing.ServerStats.getDefaultInstance() : stats_;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.ServerStats stats = 1;</code>
|
||||
*/
|
||||
private com.google.protobuf.SingleFieldBuilder<
|
||||
io.grpc.testing.ServerStats, io.grpc.testing.ServerStats.Builder, io.grpc.testing.ServerStatsOrBuilder>
|
||||
getStatsFieldBuilder() {
|
||||
if (statsBuilder_ == null) {
|
||||
statsBuilder_ = new com.google.protobuf.SingleFieldBuilder<
|
||||
io.grpc.testing.ServerStats, io.grpc.testing.ServerStats.Builder, io.grpc.testing.ServerStatsOrBuilder>(
|
||||
getStats(),
|
||||
getParentForChildren(),
|
||||
isClean());
|
||||
stats_ = null;
|
||||
}
|
||||
return statsBuilder_;
|
||||
}
|
||||
|
||||
private int port_ ;
|
||||
/**
|
||||
* <code>optional int32 port = 2;</code>
|
||||
*/
|
||||
public int getPort() {
|
||||
return port_;
|
||||
}
|
||||
/**
|
||||
* <code>optional int32 port = 2;</code>
|
||||
*/
|
||||
public Builder setPort(int value) {
|
||||
|
||||
port_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional int32 port = 2;</code>
|
||||
*/
|
||||
public Builder clearPort() {
|
||||
|
||||
port_ = 0;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
public final Builder setUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return this;
|
||||
}
|
||||
|
||||
public final Builder mergeUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return this;
|
||||
}
|
||||
|
||||
|
||||
// @@protoc_insertion_point(builder_scope:grpc.testing.ServerStatus)
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(class_scope:grpc.testing.ServerStatus)
|
||||
private static final io.grpc.testing.ServerStatus DEFAULT_INSTANCE;
|
||||
static {
|
||||
DEFAULT_INSTANCE = new io.grpc.testing.ServerStatus();
|
||||
}
|
||||
|
||||
public static io.grpc.testing.ServerStatus getDefaultInstance() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
private static final com.google.protobuf.Parser<ServerStatus>
|
||||
PARSER = new com.google.protobuf.AbstractParser<ServerStatus>() {
|
||||
public ServerStatus parsePartialFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
try {
|
||||
return new ServerStatus(input, extensionRegistry);
|
||||
} catch (RuntimeException e) {
|
||||
if (e.getCause() instanceof
|
||||
com.google.protobuf.InvalidProtocolBufferException) {
|
||||
throw (com.google.protobuf.InvalidProtocolBufferException)
|
||||
e.getCause();
|
||||
}
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
public static com.google.protobuf.Parser<ServerStatus> parser() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.Parser<ServerStatus> getParserForType() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
public io.grpc.testing.ServerStatus getDefaultInstanceForType() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
|
@ -1,27 +0,0 @@
|
|||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: qpstest.proto
|
||||
|
||||
package io.grpc.testing;
|
||||
|
||||
public interface ServerStatusOrBuilder extends
|
||||
// @@protoc_insertion_point(interface_extends:grpc.testing.ServerStatus)
|
||||
com.google.protobuf.MessageOrBuilder {
|
||||
|
||||
/**
|
||||
* <code>optional .grpc.testing.ServerStats stats = 1;</code>
|
||||
*/
|
||||
boolean hasStats();
|
||||
/**
|
||||
* <code>optional .grpc.testing.ServerStats stats = 1;</code>
|
||||
*/
|
||||
io.grpc.testing.ServerStats getStats();
|
||||
/**
|
||||
* <code>optional .grpc.testing.ServerStats stats = 1;</code>
|
||||
*/
|
||||
io.grpc.testing.ServerStatsOrBuilder getStatsOrBuilder();
|
||||
|
||||
/**
|
||||
* <code>optional int32 port = 2;</code>
|
||||
*/
|
||||
int getPort();
|
||||
}
|
||||
|
|
@ -1,98 +0,0 @@
|
|||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: qpstest.proto
|
||||
|
||||
package io.grpc.testing;
|
||||
|
||||
/**
|
||||
* Protobuf enum {@code grpc.testing.ServerType}
|
||||
*/
|
||||
public enum ServerType
|
||||
implements com.google.protobuf.ProtocolMessageEnum {
|
||||
/**
|
||||
* <code>SYNCHRONOUS_SERVER = 0;</code>
|
||||
*/
|
||||
SYNCHRONOUS_SERVER(0, 0),
|
||||
/**
|
||||
* <code>ASYNC_SERVER = 1;</code>
|
||||
*/
|
||||
ASYNC_SERVER(1, 1),
|
||||
UNRECOGNIZED(-1, -1),
|
||||
;
|
||||
|
||||
/**
|
||||
* <code>SYNCHRONOUS_SERVER = 0;</code>
|
||||
*/
|
||||
public static final int SYNCHRONOUS_SERVER_VALUE = 0;
|
||||
/**
|
||||
* <code>ASYNC_SERVER = 1;</code>
|
||||
*/
|
||||
public static final int ASYNC_SERVER_VALUE = 1;
|
||||
|
||||
|
||||
public final int getNumber() {
|
||||
if (index == -1) {
|
||||
throw new java.lang.IllegalArgumentException(
|
||||
"Can't get the number of an unknown enum value.");
|
||||
}
|
||||
return value;
|
||||
}
|
||||
|
||||
public static ServerType valueOf(int value) {
|
||||
switch (value) {
|
||||
case 0: return SYNCHRONOUS_SERVER;
|
||||
case 1: return ASYNC_SERVER;
|
||||
default: return null;
|
||||
}
|
||||
}
|
||||
|
||||
public static com.google.protobuf.Internal.EnumLiteMap<ServerType>
|
||||
internalGetValueMap() {
|
||||
return internalValueMap;
|
||||
}
|
||||
private static final com.google.protobuf.Internal.EnumLiteMap<
|
||||
ServerType> internalValueMap =
|
||||
new com.google.protobuf.Internal.EnumLiteMap<ServerType>() {
|
||||
public ServerType findValueByNumber(int number) {
|
||||
return ServerType.valueOf(number);
|
||||
}
|
||||
};
|
||||
|
||||
public final com.google.protobuf.Descriptors.EnumValueDescriptor
|
||||
getValueDescriptor() {
|
||||
return getDescriptor().getValues().get(index);
|
||||
}
|
||||
public final com.google.protobuf.Descriptors.EnumDescriptor
|
||||
getDescriptorForType() {
|
||||
return getDescriptor();
|
||||
}
|
||||
public static final com.google.protobuf.Descriptors.EnumDescriptor
|
||||
getDescriptor() {
|
||||
return io.grpc.testing.QpsTestProto.getDescriptor()
|
||||
.getEnumTypes().get(2);
|
||||
}
|
||||
|
||||
private static final ServerType[] VALUES = values();
|
||||
|
||||
public static ServerType valueOf(
|
||||
com.google.protobuf.Descriptors.EnumValueDescriptor desc) {
|
||||
if (desc.getType() != getDescriptor()) {
|
||||
throw new java.lang.IllegalArgumentException(
|
||||
"EnumValueDescriptor is not for this type.");
|
||||
}
|
||||
if (desc.getIndex() == -1) {
|
||||
return UNRECOGNIZED;
|
||||
}
|
||||
return VALUES[desc.getIndex()];
|
||||
}
|
||||
|
||||
private final int index;
|
||||
private final int value;
|
||||
|
||||
private ServerType(int index, int value) {
|
||||
this.index = index;
|
||||
this.value = value;
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(enum_scope:grpc.testing.ServerType)
|
||||
}
|
||||
|
||||
|
|
@ -1,726 +0,0 @@
|
|||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: qpstest.proto
|
||||
|
||||
package io.grpc.testing;
|
||||
|
||||
/**
|
||||
* Protobuf type {@code grpc.testing.SimpleRequest}
|
||||
*/
|
||||
public final class SimpleRequest extends
|
||||
com.google.protobuf.GeneratedMessage implements
|
||||
// @@protoc_insertion_point(message_implements:grpc.testing.SimpleRequest)
|
||||
SimpleRequestOrBuilder {
|
||||
// Use SimpleRequest.newBuilder() to construct.
|
||||
private SimpleRequest(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
|
||||
super(builder);
|
||||
}
|
||||
private SimpleRequest() {
|
||||
responseType_ = 0;
|
||||
responseSize_ = 0;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public final com.google.protobuf.UnknownFieldSet
|
||||
getUnknownFields() {
|
||||
return com.google.protobuf.UnknownFieldSet.getDefaultInstance();
|
||||
}
|
||||
private SimpleRequest(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry) {
|
||||
this();
|
||||
int mutable_bitField0_ = 0;
|
||||
try {
|
||||
boolean done = false;
|
||||
while (!done) {
|
||||
int tag = input.readTag();
|
||||
switch (tag) {
|
||||
case 0:
|
||||
done = true;
|
||||
break;
|
||||
default: {
|
||||
if (!input.skipField(tag)) {
|
||||
done = true;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case 8: {
|
||||
int rawValue = input.readEnum();
|
||||
|
||||
responseType_ = rawValue;
|
||||
break;
|
||||
}
|
||||
case 16: {
|
||||
|
||||
responseSize_ = input.readInt32();
|
||||
break;
|
||||
}
|
||||
case 26: {
|
||||
io.grpc.testing.Payload.Builder subBuilder = null;
|
||||
if (payload_ != null) {
|
||||
subBuilder = payload_.toBuilder();
|
||||
}
|
||||
payload_ = input.readMessage(io.grpc.testing.Payload.parser(), extensionRegistry);
|
||||
if (subBuilder != null) {
|
||||
subBuilder.mergeFrom(payload_);
|
||||
payload_ = subBuilder.buildPartial();
|
||||
}
|
||||
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
throw new RuntimeException(e.setUnfinishedMessage(this));
|
||||
} catch (java.io.IOException e) {
|
||||
throw new RuntimeException(
|
||||
new com.google.protobuf.InvalidProtocolBufferException(
|
||||
e.getMessage()).setUnfinishedMessage(this));
|
||||
} finally {
|
||||
makeExtensionsImmutable();
|
||||
}
|
||||
}
|
||||
public static final com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptor() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_SimpleRequest_descriptor;
|
||||
}
|
||||
|
||||
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_SimpleRequest_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
io.grpc.testing.SimpleRequest.class, io.grpc.testing.SimpleRequest.Builder.class);
|
||||
}
|
||||
|
||||
public static final int RESPONSE_TYPE_FIELD_NUMBER = 1;
|
||||
private int responseType_;
|
||||
/**
|
||||
* <code>optional .grpc.testing.PayloadType response_type = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Desired payload type in the response from the server.
|
||||
* If response_type is RANDOM, server randomly chooses one from other formats.
|
||||
* </pre>
|
||||
*/
|
||||
public int getResponseTypeValue() {
|
||||
return responseType_;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.PayloadType response_type = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Desired payload type in the response from the server.
|
||||
* If response_type is RANDOM, server randomly chooses one from other formats.
|
||||
* </pre>
|
||||
*/
|
||||
public io.grpc.testing.PayloadType getResponseType() {
|
||||
io.grpc.testing.PayloadType result = io.grpc.testing.PayloadType.valueOf(responseType_);
|
||||
return result == null ? io.grpc.testing.PayloadType.UNRECOGNIZED : result;
|
||||
}
|
||||
|
||||
public static final int RESPONSE_SIZE_FIELD_NUMBER = 2;
|
||||
private int responseSize_;
|
||||
/**
|
||||
* <code>optional int32 response_size = 2;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Desired payload size in the response from the server.
|
||||
* If response_type is COMPRESSABLE, this denotes the size before compression.
|
||||
* </pre>
|
||||
*/
|
||||
public int getResponseSize() {
|
||||
return responseSize_;
|
||||
}
|
||||
|
||||
public static final int PAYLOAD_FIELD_NUMBER = 3;
|
||||
private io.grpc.testing.Payload payload_;
|
||||
/**
|
||||
* <code>optional .grpc.testing.Payload payload = 3;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Optional input payload sent along with the request.
|
||||
* </pre>
|
||||
*/
|
||||
public boolean hasPayload() {
|
||||
return payload_ != null;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.Payload payload = 3;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Optional input payload sent along with the request.
|
||||
* </pre>
|
||||
*/
|
||||
public io.grpc.testing.Payload getPayload() {
|
||||
return payload_ == null ? io.grpc.testing.Payload.getDefaultInstance() : payload_;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.Payload payload = 3;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Optional input payload sent along with the request.
|
||||
* </pre>
|
||||
*/
|
||||
public io.grpc.testing.PayloadOrBuilder getPayloadOrBuilder() {
|
||||
return getPayload();
|
||||
}
|
||||
|
||||
private byte memoizedIsInitialized = -1;
|
||||
public final boolean isInitialized() {
|
||||
byte isInitialized = memoizedIsInitialized;
|
||||
if (isInitialized == 1) return true;
|
||||
if (isInitialized == 0) return false;
|
||||
|
||||
memoizedIsInitialized = 1;
|
||||
return true;
|
||||
}
|
||||
|
||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
||||
throws java.io.IOException {
|
||||
if (responseType_ != io.grpc.testing.PayloadType.COMPRESSABLE.getNumber()) {
|
||||
output.writeEnum(1, responseType_);
|
||||
}
|
||||
if (responseSize_ != 0) {
|
||||
output.writeInt32(2, responseSize_);
|
||||
}
|
||||
if (payload_ != null) {
|
||||
output.writeMessage(3, getPayload());
|
||||
}
|
||||
}
|
||||
|
||||
public int getSerializedSize() {
|
||||
int size = memoizedSize;
|
||||
if (size != -1) return size;
|
||||
|
||||
size = 0;
|
||||
if (responseType_ != io.grpc.testing.PayloadType.COMPRESSABLE.getNumber()) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeEnumSize(1, responseType_);
|
||||
}
|
||||
if (responseSize_ != 0) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeInt32Size(2, responseSize_);
|
||||
}
|
||||
if (payload_ != null) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeMessageSize(3, getPayload());
|
||||
}
|
||||
memoizedSize = size;
|
||||
return size;
|
||||
}
|
||||
|
||||
private static final long serialVersionUID = 0L;
|
||||
public static io.grpc.testing.SimpleRequest parseFrom(
|
||||
com.google.protobuf.ByteString data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static io.grpc.testing.SimpleRequest parseFrom(
|
||||
com.google.protobuf.ByteString data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.SimpleRequest parseFrom(byte[] data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static io.grpc.testing.SimpleRequest parseFrom(
|
||||
byte[] data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.SimpleRequest parseFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.SimpleRequest parseFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.SimpleRequest parseDelimitedFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseDelimitedFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.SimpleRequest parseDelimitedFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseDelimitedFrom(input, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.SimpleRequest parseFrom(
|
||||
com.google.protobuf.CodedInputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.SimpleRequest parseFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input, extensionRegistry);
|
||||
}
|
||||
|
||||
public Builder newBuilderForType() { return newBuilder(); }
|
||||
public static Builder newBuilder() {
|
||||
return DEFAULT_INSTANCE.toBuilder();
|
||||
}
|
||||
public static Builder newBuilder(io.grpc.testing.SimpleRequest prototype) {
|
||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
||||
}
|
||||
public Builder toBuilder() {
|
||||
return this == DEFAULT_INSTANCE
|
||||
? new Builder() : new Builder().mergeFrom(this);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected Builder newBuilderForType(
|
||||
com.google.protobuf.GeneratedMessage.BuilderParent parent) {
|
||||
Builder builder = new Builder(parent);
|
||||
return builder;
|
||||
}
|
||||
/**
|
||||
* Protobuf type {@code grpc.testing.SimpleRequest}
|
||||
*/
|
||||
public static final class Builder extends
|
||||
com.google.protobuf.GeneratedMessage.Builder<Builder> implements
|
||||
// @@protoc_insertion_point(builder_implements:grpc.testing.SimpleRequest)
|
||||
io.grpc.testing.SimpleRequestOrBuilder {
|
||||
public static final com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptor() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_SimpleRequest_descriptor;
|
||||
}
|
||||
|
||||
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_SimpleRequest_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
io.grpc.testing.SimpleRequest.class, io.grpc.testing.SimpleRequest.Builder.class);
|
||||
}
|
||||
|
||||
// Construct using io.grpc.testing.SimpleRequest.newBuilder()
|
||||
private Builder() {
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
|
||||
private Builder(
|
||||
com.google.protobuf.GeneratedMessage.BuilderParent parent) {
|
||||
super(parent);
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
private void maybeForceBuilderInitialization() {
|
||||
if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
|
||||
}
|
||||
}
|
||||
public Builder clear() {
|
||||
super.clear();
|
||||
responseType_ = 0;
|
||||
|
||||
responseSize_ = 0;
|
||||
|
||||
if (payloadBuilder_ == null) {
|
||||
payload_ = null;
|
||||
} else {
|
||||
payload_ = null;
|
||||
payloadBuilder_ = null;
|
||||
}
|
||||
return this;
|
||||
}
|
||||
|
||||
public com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptorForType() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_SimpleRequest_descriptor;
|
||||
}
|
||||
|
||||
public io.grpc.testing.SimpleRequest getDefaultInstanceForType() {
|
||||
return io.grpc.testing.SimpleRequest.getDefaultInstance();
|
||||
}
|
||||
|
||||
public io.grpc.testing.SimpleRequest build() {
|
||||
io.grpc.testing.SimpleRequest result = buildPartial();
|
||||
if (!result.isInitialized()) {
|
||||
throw newUninitializedMessageException(result);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
public io.grpc.testing.SimpleRequest buildPartial() {
|
||||
io.grpc.testing.SimpleRequest result = new io.grpc.testing.SimpleRequest(this);
|
||||
result.responseType_ = responseType_;
|
||||
result.responseSize_ = responseSize_;
|
||||
if (payloadBuilder_ == null) {
|
||||
result.payload_ = payload_;
|
||||
} else {
|
||||
result.payload_ = payloadBuilder_.build();
|
||||
}
|
||||
onBuilt();
|
||||
return result;
|
||||
}
|
||||
|
||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
||||
if (other instanceof io.grpc.testing.SimpleRequest) {
|
||||
return mergeFrom((io.grpc.testing.SimpleRequest)other);
|
||||
} else {
|
||||
super.mergeFrom(other);
|
||||
return this;
|
||||
}
|
||||
}
|
||||
|
||||
public Builder mergeFrom(io.grpc.testing.SimpleRequest other) {
|
||||
if (other == io.grpc.testing.SimpleRequest.getDefaultInstance()) return this;
|
||||
if (other.responseType_ != 0) {
|
||||
setResponseTypeValue(other.getResponseTypeValue());
|
||||
}
|
||||
if (other.getResponseSize() != 0) {
|
||||
setResponseSize(other.getResponseSize());
|
||||
}
|
||||
if (other.hasPayload()) {
|
||||
mergePayload(other.getPayload());
|
||||
}
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
public final boolean isInitialized() {
|
||||
return true;
|
||||
}
|
||||
|
||||
public Builder mergeFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
io.grpc.testing.SimpleRequest parsedMessage = null;
|
||||
try {
|
||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
parsedMessage = (io.grpc.testing.SimpleRequest) e.getUnfinishedMessage();
|
||||
throw e;
|
||||
} finally {
|
||||
if (parsedMessage != null) {
|
||||
mergeFrom(parsedMessage);
|
||||
}
|
||||
}
|
||||
return this;
|
||||
}
|
||||
|
||||
private int responseType_ = 0;
|
||||
/**
|
||||
* <code>optional .grpc.testing.PayloadType response_type = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Desired payload type in the response from the server.
|
||||
* If response_type is RANDOM, server randomly chooses one from other formats.
|
||||
* </pre>
|
||||
*/
|
||||
public int getResponseTypeValue() {
|
||||
return responseType_;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.PayloadType response_type = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Desired payload type in the response from the server.
|
||||
* If response_type is RANDOM, server randomly chooses one from other formats.
|
||||
* </pre>
|
||||
*/
|
||||
public Builder setResponseTypeValue(int value) {
|
||||
responseType_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.PayloadType response_type = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Desired payload type in the response from the server.
|
||||
* If response_type is RANDOM, server randomly chooses one from other formats.
|
||||
* </pre>
|
||||
*/
|
||||
public io.grpc.testing.PayloadType getResponseType() {
|
||||
io.grpc.testing.PayloadType result = io.grpc.testing.PayloadType.valueOf(responseType_);
|
||||
return result == null ? io.grpc.testing.PayloadType.UNRECOGNIZED : result;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.PayloadType response_type = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Desired payload type in the response from the server.
|
||||
* If response_type is RANDOM, server randomly chooses one from other formats.
|
||||
* </pre>
|
||||
*/
|
||||
public Builder setResponseType(io.grpc.testing.PayloadType value) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
|
||||
responseType_ = value.getNumber();
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.PayloadType response_type = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Desired payload type in the response from the server.
|
||||
* If response_type is RANDOM, server randomly chooses one from other formats.
|
||||
* </pre>
|
||||
*/
|
||||
public Builder clearResponseType() {
|
||||
|
||||
responseType_ = 0;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
private int responseSize_ ;
|
||||
/**
|
||||
* <code>optional int32 response_size = 2;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Desired payload size in the response from the server.
|
||||
* If response_type is COMPRESSABLE, this denotes the size before compression.
|
||||
* </pre>
|
||||
*/
|
||||
public int getResponseSize() {
|
||||
return responseSize_;
|
||||
}
|
||||
/**
|
||||
* <code>optional int32 response_size = 2;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Desired payload size in the response from the server.
|
||||
* If response_type is COMPRESSABLE, this denotes the size before compression.
|
||||
* </pre>
|
||||
*/
|
||||
public Builder setResponseSize(int value) {
|
||||
|
||||
responseSize_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional int32 response_size = 2;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Desired payload size in the response from the server.
|
||||
* If response_type is COMPRESSABLE, this denotes the size before compression.
|
||||
* </pre>
|
||||
*/
|
||||
public Builder clearResponseSize() {
|
||||
|
||||
responseSize_ = 0;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
private io.grpc.testing.Payload payload_ = null;
|
||||
private com.google.protobuf.SingleFieldBuilder<
|
||||
io.grpc.testing.Payload, io.grpc.testing.Payload.Builder, io.grpc.testing.PayloadOrBuilder> payloadBuilder_;
|
||||
/**
|
||||
* <code>optional .grpc.testing.Payload payload = 3;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Optional input payload sent along with the request.
|
||||
* </pre>
|
||||
*/
|
||||
public boolean hasPayload() {
|
||||
return payloadBuilder_ != null || payload_ != null;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.Payload payload = 3;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Optional input payload sent along with the request.
|
||||
* </pre>
|
||||
*/
|
||||
public io.grpc.testing.Payload getPayload() {
|
||||
if (payloadBuilder_ == null) {
|
||||
return payload_ == null ? io.grpc.testing.Payload.getDefaultInstance() : payload_;
|
||||
} else {
|
||||
return payloadBuilder_.getMessage();
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.Payload payload = 3;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Optional input payload sent along with the request.
|
||||
* </pre>
|
||||
*/
|
||||
public Builder setPayload(io.grpc.testing.Payload value) {
|
||||
if (payloadBuilder_ == null) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
payload_ = value;
|
||||
onChanged();
|
||||
} else {
|
||||
payloadBuilder_.setMessage(value);
|
||||
}
|
||||
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.Payload payload = 3;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Optional input payload sent along with the request.
|
||||
* </pre>
|
||||
*/
|
||||
public Builder setPayload(
|
||||
io.grpc.testing.Payload.Builder builderForValue) {
|
||||
if (payloadBuilder_ == null) {
|
||||
payload_ = builderForValue.build();
|
||||
onChanged();
|
||||
} else {
|
||||
payloadBuilder_.setMessage(builderForValue.build());
|
||||
}
|
||||
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.Payload payload = 3;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Optional input payload sent along with the request.
|
||||
* </pre>
|
||||
*/
|
||||
public Builder mergePayload(io.grpc.testing.Payload value) {
|
||||
if (payloadBuilder_ == null) {
|
||||
if (payload_ != null) {
|
||||
payload_ =
|
||||
io.grpc.testing.Payload.newBuilder(payload_).mergeFrom(value).buildPartial();
|
||||
} else {
|
||||
payload_ = value;
|
||||
}
|
||||
onChanged();
|
||||
} else {
|
||||
payloadBuilder_.mergeFrom(value);
|
||||
}
|
||||
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.Payload payload = 3;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Optional input payload sent along with the request.
|
||||
* </pre>
|
||||
*/
|
||||
public Builder clearPayload() {
|
||||
if (payloadBuilder_ == null) {
|
||||
payload_ = null;
|
||||
onChanged();
|
||||
} else {
|
||||
payload_ = null;
|
||||
payloadBuilder_ = null;
|
||||
}
|
||||
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.Payload payload = 3;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Optional input payload sent along with the request.
|
||||
* </pre>
|
||||
*/
|
||||
public io.grpc.testing.Payload.Builder getPayloadBuilder() {
|
||||
|
||||
onChanged();
|
||||
return getPayloadFieldBuilder().getBuilder();
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.Payload payload = 3;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Optional input payload sent along with the request.
|
||||
* </pre>
|
||||
*/
|
||||
public io.grpc.testing.PayloadOrBuilder getPayloadOrBuilder() {
|
||||
if (payloadBuilder_ != null) {
|
||||
return payloadBuilder_.getMessageOrBuilder();
|
||||
} else {
|
||||
return payload_ == null ?
|
||||
io.grpc.testing.Payload.getDefaultInstance() : payload_;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.Payload payload = 3;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Optional input payload sent along with the request.
|
||||
* </pre>
|
||||
*/
|
||||
private com.google.protobuf.SingleFieldBuilder<
|
||||
io.grpc.testing.Payload, io.grpc.testing.Payload.Builder, io.grpc.testing.PayloadOrBuilder>
|
||||
getPayloadFieldBuilder() {
|
||||
if (payloadBuilder_ == null) {
|
||||
payloadBuilder_ = new com.google.protobuf.SingleFieldBuilder<
|
||||
io.grpc.testing.Payload, io.grpc.testing.Payload.Builder, io.grpc.testing.PayloadOrBuilder>(
|
||||
getPayload(),
|
||||
getParentForChildren(),
|
||||
isClean());
|
||||
payload_ = null;
|
||||
}
|
||||
return payloadBuilder_;
|
||||
}
|
||||
public final Builder setUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return this;
|
||||
}
|
||||
|
||||
public final Builder mergeUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return this;
|
||||
}
|
||||
|
||||
|
||||
// @@protoc_insertion_point(builder_scope:grpc.testing.SimpleRequest)
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(class_scope:grpc.testing.SimpleRequest)
|
||||
private static final io.grpc.testing.SimpleRequest DEFAULT_INSTANCE;
|
||||
static {
|
||||
DEFAULT_INSTANCE = new io.grpc.testing.SimpleRequest();
|
||||
}
|
||||
|
||||
public static io.grpc.testing.SimpleRequest getDefaultInstance() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
private static final com.google.protobuf.Parser<SimpleRequest>
|
||||
PARSER = new com.google.protobuf.AbstractParser<SimpleRequest>() {
|
||||
public SimpleRequest parsePartialFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
try {
|
||||
return new SimpleRequest(input, extensionRegistry);
|
||||
} catch (RuntimeException e) {
|
||||
if (e.getCause() instanceof
|
||||
com.google.protobuf.InvalidProtocolBufferException) {
|
||||
throw (com.google.protobuf.InvalidProtocolBufferException)
|
||||
e.getCause();
|
||||
}
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
public static com.google.protobuf.Parser<SimpleRequest> parser() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.Parser<SimpleRequest> getParserForType() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
public io.grpc.testing.SimpleRequest getDefaultInstanceForType() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
|
@ -1,63 +0,0 @@
|
|||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: qpstest.proto
|
||||
|
||||
package io.grpc.testing;
|
||||
|
||||
public interface SimpleRequestOrBuilder extends
|
||||
// @@protoc_insertion_point(interface_extends:grpc.testing.SimpleRequest)
|
||||
com.google.protobuf.MessageOrBuilder {
|
||||
|
||||
/**
|
||||
* <code>optional .grpc.testing.PayloadType response_type = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Desired payload type in the response from the server.
|
||||
* If response_type is RANDOM, server randomly chooses one from other formats.
|
||||
* </pre>
|
||||
*/
|
||||
int getResponseTypeValue();
|
||||
/**
|
||||
* <code>optional .grpc.testing.PayloadType response_type = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Desired payload type in the response from the server.
|
||||
* If response_type is RANDOM, server randomly chooses one from other formats.
|
||||
* </pre>
|
||||
*/
|
||||
io.grpc.testing.PayloadType getResponseType();
|
||||
|
||||
/**
|
||||
* <code>optional int32 response_size = 2;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Desired payload size in the response from the server.
|
||||
* If response_type is COMPRESSABLE, this denotes the size before compression.
|
||||
* </pre>
|
||||
*/
|
||||
int getResponseSize();
|
||||
|
||||
/**
|
||||
* <code>optional .grpc.testing.Payload payload = 3;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Optional input payload sent along with the request.
|
||||
* </pre>
|
||||
*/
|
||||
boolean hasPayload();
|
||||
/**
|
||||
* <code>optional .grpc.testing.Payload payload = 3;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Optional input payload sent along with the request.
|
||||
* </pre>
|
||||
*/
|
||||
io.grpc.testing.Payload getPayload();
|
||||
/**
|
||||
* <code>optional .grpc.testing.Payload payload = 3;</code>
|
||||
*
|
||||
* <pre>
|
||||
* Optional input payload sent along with the request.
|
||||
* </pre>
|
||||
*/
|
||||
io.grpc.testing.PayloadOrBuilder getPayloadOrBuilder();
|
||||
}
|
||||
|
|
@ -1,489 +0,0 @@
|
|||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: qpstest.proto
|
||||
|
||||
package io.grpc.testing;
|
||||
|
||||
/**
|
||||
* Protobuf type {@code grpc.testing.SimpleResponse}
|
||||
*/
|
||||
public final class SimpleResponse extends
|
||||
com.google.protobuf.GeneratedMessage implements
|
||||
// @@protoc_insertion_point(message_implements:grpc.testing.SimpleResponse)
|
||||
SimpleResponseOrBuilder {
|
||||
// Use SimpleResponse.newBuilder() to construct.
|
||||
private SimpleResponse(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
|
||||
super(builder);
|
||||
}
|
||||
private SimpleResponse() {
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public final com.google.protobuf.UnknownFieldSet
|
||||
getUnknownFields() {
|
||||
return com.google.protobuf.UnknownFieldSet.getDefaultInstance();
|
||||
}
|
||||
private SimpleResponse(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry) {
|
||||
this();
|
||||
int mutable_bitField0_ = 0;
|
||||
try {
|
||||
boolean done = false;
|
||||
while (!done) {
|
||||
int tag = input.readTag();
|
||||
switch (tag) {
|
||||
case 0:
|
||||
done = true;
|
||||
break;
|
||||
default: {
|
||||
if (!input.skipField(tag)) {
|
||||
done = true;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case 10: {
|
||||
io.grpc.testing.Payload.Builder subBuilder = null;
|
||||
if (payload_ != null) {
|
||||
subBuilder = payload_.toBuilder();
|
||||
}
|
||||
payload_ = input.readMessage(io.grpc.testing.Payload.parser(), extensionRegistry);
|
||||
if (subBuilder != null) {
|
||||
subBuilder.mergeFrom(payload_);
|
||||
payload_ = subBuilder.buildPartial();
|
||||
}
|
||||
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
throw new RuntimeException(e.setUnfinishedMessage(this));
|
||||
} catch (java.io.IOException e) {
|
||||
throw new RuntimeException(
|
||||
new com.google.protobuf.InvalidProtocolBufferException(
|
||||
e.getMessage()).setUnfinishedMessage(this));
|
||||
} finally {
|
||||
makeExtensionsImmutable();
|
||||
}
|
||||
}
|
||||
public static final com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptor() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_SimpleResponse_descriptor;
|
||||
}
|
||||
|
||||
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_SimpleResponse_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
io.grpc.testing.SimpleResponse.class, io.grpc.testing.SimpleResponse.Builder.class);
|
||||
}
|
||||
|
||||
public static final int PAYLOAD_FIELD_NUMBER = 1;
|
||||
private io.grpc.testing.Payload payload_;
|
||||
/**
|
||||
* <code>optional .grpc.testing.Payload payload = 1;</code>
|
||||
*/
|
||||
public boolean hasPayload() {
|
||||
return payload_ != null;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.Payload payload = 1;</code>
|
||||
*/
|
||||
public io.grpc.testing.Payload getPayload() {
|
||||
return payload_ == null ? io.grpc.testing.Payload.getDefaultInstance() : payload_;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.Payload payload = 1;</code>
|
||||
*/
|
||||
public io.grpc.testing.PayloadOrBuilder getPayloadOrBuilder() {
|
||||
return getPayload();
|
||||
}
|
||||
|
||||
private byte memoizedIsInitialized = -1;
|
||||
public final boolean isInitialized() {
|
||||
byte isInitialized = memoizedIsInitialized;
|
||||
if (isInitialized == 1) return true;
|
||||
if (isInitialized == 0) return false;
|
||||
|
||||
memoizedIsInitialized = 1;
|
||||
return true;
|
||||
}
|
||||
|
||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
||||
throws java.io.IOException {
|
||||
if (payload_ != null) {
|
||||
output.writeMessage(1, getPayload());
|
||||
}
|
||||
}
|
||||
|
||||
public int getSerializedSize() {
|
||||
int size = memoizedSize;
|
||||
if (size != -1) return size;
|
||||
|
||||
size = 0;
|
||||
if (payload_ != null) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeMessageSize(1, getPayload());
|
||||
}
|
||||
memoizedSize = size;
|
||||
return size;
|
||||
}
|
||||
|
||||
private static final long serialVersionUID = 0L;
|
||||
public static io.grpc.testing.SimpleResponse parseFrom(
|
||||
com.google.protobuf.ByteString data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static io.grpc.testing.SimpleResponse parseFrom(
|
||||
com.google.protobuf.ByteString data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.SimpleResponse parseFrom(byte[] data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static io.grpc.testing.SimpleResponse parseFrom(
|
||||
byte[] data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.SimpleResponse parseFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.SimpleResponse parseFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.SimpleResponse parseDelimitedFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseDelimitedFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.SimpleResponse parseDelimitedFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseDelimitedFrom(input, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.SimpleResponse parseFrom(
|
||||
com.google.protobuf.CodedInputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.SimpleResponse parseFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input, extensionRegistry);
|
||||
}
|
||||
|
||||
public Builder newBuilderForType() { return newBuilder(); }
|
||||
public static Builder newBuilder() {
|
||||
return DEFAULT_INSTANCE.toBuilder();
|
||||
}
|
||||
public static Builder newBuilder(io.grpc.testing.SimpleResponse prototype) {
|
||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
||||
}
|
||||
public Builder toBuilder() {
|
||||
return this == DEFAULT_INSTANCE
|
||||
? new Builder() : new Builder().mergeFrom(this);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected Builder newBuilderForType(
|
||||
com.google.protobuf.GeneratedMessage.BuilderParent parent) {
|
||||
Builder builder = new Builder(parent);
|
||||
return builder;
|
||||
}
|
||||
/**
|
||||
* Protobuf type {@code grpc.testing.SimpleResponse}
|
||||
*/
|
||||
public static final class Builder extends
|
||||
com.google.protobuf.GeneratedMessage.Builder<Builder> implements
|
||||
// @@protoc_insertion_point(builder_implements:grpc.testing.SimpleResponse)
|
||||
io.grpc.testing.SimpleResponseOrBuilder {
|
||||
public static final com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptor() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_SimpleResponse_descriptor;
|
||||
}
|
||||
|
||||
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_SimpleResponse_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
io.grpc.testing.SimpleResponse.class, io.grpc.testing.SimpleResponse.Builder.class);
|
||||
}
|
||||
|
||||
// Construct using io.grpc.testing.SimpleResponse.newBuilder()
|
||||
private Builder() {
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
|
||||
private Builder(
|
||||
com.google.protobuf.GeneratedMessage.BuilderParent parent) {
|
||||
super(parent);
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
private void maybeForceBuilderInitialization() {
|
||||
if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
|
||||
}
|
||||
}
|
||||
public Builder clear() {
|
||||
super.clear();
|
||||
if (payloadBuilder_ == null) {
|
||||
payload_ = null;
|
||||
} else {
|
||||
payload_ = null;
|
||||
payloadBuilder_ = null;
|
||||
}
|
||||
return this;
|
||||
}
|
||||
|
||||
public com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptorForType() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_SimpleResponse_descriptor;
|
||||
}
|
||||
|
||||
public io.grpc.testing.SimpleResponse getDefaultInstanceForType() {
|
||||
return io.grpc.testing.SimpleResponse.getDefaultInstance();
|
||||
}
|
||||
|
||||
public io.grpc.testing.SimpleResponse build() {
|
||||
io.grpc.testing.SimpleResponse result = buildPartial();
|
||||
if (!result.isInitialized()) {
|
||||
throw newUninitializedMessageException(result);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
public io.grpc.testing.SimpleResponse buildPartial() {
|
||||
io.grpc.testing.SimpleResponse result = new io.grpc.testing.SimpleResponse(this);
|
||||
if (payloadBuilder_ == null) {
|
||||
result.payload_ = payload_;
|
||||
} else {
|
||||
result.payload_ = payloadBuilder_.build();
|
||||
}
|
||||
onBuilt();
|
||||
return result;
|
||||
}
|
||||
|
||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
||||
if (other instanceof io.grpc.testing.SimpleResponse) {
|
||||
return mergeFrom((io.grpc.testing.SimpleResponse)other);
|
||||
} else {
|
||||
super.mergeFrom(other);
|
||||
return this;
|
||||
}
|
||||
}
|
||||
|
||||
public Builder mergeFrom(io.grpc.testing.SimpleResponse other) {
|
||||
if (other == io.grpc.testing.SimpleResponse.getDefaultInstance()) return this;
|
||||
if (other.hasPayload()) {
|
||||
mergePayload(other.getPayload());
|
||||
}
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
public final boolean isInitialized() {
|
||||
return true;
|
||||
}
|
||||
|
||||
public Builder mergeFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
io.grpc.testing.SimpleResponse parsedMessage = null;
|
||||
try {
|
||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
parsedMessage = (io.grpc.testing.SimpleResponse) e.getUnfinishedMessage();
|
||||
throw e;
|
||||
} finally {
|
||||
if (parsedMessage != null) {
|
||||
mergeFrom(parsedMessage);
|
||||
}
|
||||
}
|
||||
return this;
|
||||
}
|
||||
|
||||
private io.grpc.testing.Payload payload_ = null;
|
||||
private com.google.protobuf.SingleFieldBuilder<
|
||||
io.grpc.testing.Payload, io.grpc.testing.Payload.Builder, io.grpc.testing.PayloadOrBuilder> payloadBuilder_;
|
||||
/**
|
||||
* <code>optional .grpc.testing.Payload payload = 1;</code>
|
||||
*/
|
||||
public boolean hasPayload() {
|
||||
return payloadBuilder_ != null || payload_ != null;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.Payload payload = 1;</code>
|
||||
*/
|
||||
public io.grpc.testing.Payload getPayload() {
|
||||
if (payloadBuilder_ == null) {
|
||||
return payload_ == null ? io.grpc.testing.Payload.getDefaultInstance() : payload_;
|
||||
} else {
|
||||
return payloadBuilder_.getMessage();
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.Payload payload = 1;</code>
|
||||
*/
|
||||
public Builder setPayload(io.grpc.testing.Payload value) {
|
||||
if (payloadBuilder_ == null) {
|
||||
if (value == null) {
|
||||
throw new NullPointerException();
|
||||
}
|
||||
payload_ = value;
|
||||
onChanged();
|
||||
} else {
|
||||
payloadBuilder_.setMessage(value);
|
||||
}
|
||||
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.Payload payload = 1;</code>
|
||||
*/
|
||||
public Builder setPayload(
|
||||
io.grpc.testing.Payload.Builder builderForValue) {
|
||||
if (payloadBuilder_ == null) {
|
||||
payload_ = builderForValue.build();
|
||||
onChanged();
|
||||
} else {
|
||||
payloadBuilder_.setMessage(builderForValue.build());
|
||||
}
|
||||
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.Payload payload = 1;</code>
|
||||
*/
|
||||
public Builder mergePayload(io.grpc.testing.Payload value) {
|
||||
if (payloadBuilder_ == null) {
|
||||
if (payload_ != null) {
|
||||
payload_ =
|
||||
io.grpc.testing.Payload.newBuilder(payload_).mergeFrom(value).buildPartial();
|
||||
} else {
|
||||
payload_ = value;
|
||||
}
|
||||
onChanged();
|
||||
} else {
|
||||
payloadBuilder_.mergeFrom(value);
|
||||
}
|
||||
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.Payload payload = 1;</code>
|
||||
*/
|
||||
public Builder clearPayload() {
|
||||
if (payloadBuilder_ == null) {
|
||||
payload_ = null;
|
||||
onChanged();
|
||||
} else {
|
||||
payload_ = null;
|
||||
payloadBuilder_ = null;
|
||||
}
|
||||
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.Payload payload = 1;</code>
|
||||
*/
|
||||
public io.grpc.testing.Payload.Builder getPayloadBuilder() {
|
||||
|
||||
onChanged();
|
||||
return getPayloadFieldBuilder().getBuilder();
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.Payload payload = 1;</code>
|
||||
*/
|
||||
public io.grpc.testing.PayloadOrBuilder getPayloadOrBuilder() {
|
||||
if (payloadBuilder_ != null) {
|
||||
return payloadBuilder_.getMessageOrBuilder();
|
||||
} else {
|
||||
return payload_ == null ?
|
||||
io.grpc.testing.Payload.getDefaultInstance() : payload_;
|
||||
}
|
||||
}
|
||||
/**
|
||||
* <code>optional .grpc.testing.Payload payload = 1;</code>
|
||||
*/
|
||||
private com.google.protobuf.SingleFieldBuilder<
|
||||
io.grpc.testing.Payload, io.grpc.testing.Payload.Builder, io.grpc.testing.PayloadOrBuilder>
|
||||
getPayloadFieldBuilder() {
|
||||
if (payloadBuilder_ == null) {
|
||||
payloadBuilder_ = new com.google.protobuf.SingleFieldBuilder<
|
||||
io.grpc.testing.Payload, io.grpc.testing.Payload.Builder, io.grpc.testing.PayloadOrBuilder>(
|
||||
getPayload(),
|
||||
getParentForChildren(),
|
||||
isClean());
|
||||
payload_ = null;
|
||||
}
|
||||
return payloadBuilder_;
|
||||
}
|
||||
public final Builder setUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return this;
|
||||
}
|
||||
|
||||
public final Builder mergeUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return this;
|
||||
}
|
||||
|
||||
|
||||
// @@protoc_insertion_point(builder_scope:grpc.testing.SimpleResponse)
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(class_scope:grpc.testing.SimpleResponse)
|
||||
private static final io.grpc.testing.SimpleResponse DEFAULT_INSTANCE;
|
||||
static {
|
||||
DEFAULT_INSTANCE = new io.grpc.testing.SimpleResponse();
|
||||
}
|
||||
|
||||
public static io.grpc.testing.SimpleResponse getDefaultInstance() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
private static final com.google.protobuf.Parser<SimpleResponse>
|
||||
PARSER = new com.google.protobuf.AbstractParser<SimpleResponse>() {
|
||||
public SimpleResponse parsePartialFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
try {
|
||||
return new SimpleResponse(input, extensionRegistry);
|
||||
} catch (RuntimeException e) {
|
||||
if (e.getCause() instanceof
|
||||
com.google.protobuf.InvalidProtocolBufferException) {
|
||||
throw (com.google.protobuf.InvalidProtocolBufferException)
|
||||
e.getCause();
|
||||
}
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
public static com.google.protobuf.Parser<SimpleResponse> parser() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.Parser<SimpleResponse> getParserForType() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
public io.grpc.testing.SimpleResponse getDefaultInstanceForType() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
|
@ -1,22 +0,0 @@
|
|||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: qpstest.proto
|
||||
|
||||
package io.grpc.testing;
|
||||
|
||||
public interface SimpleResponseOrBuilder extends
|
||||
// @@protoc_insertion_point(interface_extends:grpc.testing.SimpleResponse)
|
||||
com.google.protobuf.MessageOrBuilder {
|
||||
|
||||
/**
|
||||
* <code>optional .grpc.testing.Payload payload = 1;</code>
|
||||
*/
|
||||
boolean hasPayload();
|
||||
/**
|
||||
* <code>optional .grpc.testing.Payload payload = 1;</code>
|
||||
*/
|
||||
io.grpc.testing.Payload getPayload();
|
||||
/**
|
||||
* <code>optional .grpc.testing.Payload payload = 1;</code>
|
||||
*/
|
||||
io.grpc.testing.PayloadOrBuilder getPayloadOrBuilder();
|
||||
}
|
||||
|
|
@ -1,387 +0,0 @@
|
|||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: qpstest.proto
|
||||
|
||||
package io.grpc.testing;
|
||||
|
||||
/**
|
||||
* Protobuf type {@code grpc.testing.StatsRequest}
|
||||
*/
|
||||
public final class StatsRequest extends
|
||||
com.google.protobuf.GeneratedMessage implements
|
||||
// @@protoc_insertion_point(message_implements:grpc.testing.StatsRequest)
|
||||
StatsRequestOrBuilder {
|
||||
// Use StatsRequest.newBuilder() to construct.
|
||||
private StatsRequest(com.google.protobuf.GeneratedMessage.Builder<?> builder) {
|
||||
super(builder);
|
||||
}
|
||||
private StatsRequest() {
|
||||
testNum_ = 0;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public final com.google.protobuf.UnknownFieldSet
|
||||
getUnknownFields() {
|
||||
return com.google.protobuf.UnknownFieldSet.getDefaultInstance();
|
||||
}
|
||||
private StatsRequest(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry) {
|
||||
this();
|
||||
int mutable_bitField0_ = 0;
|
||||
try {
|
||||
boolean done = false;
|
||||
while (!done) {
|
||||
int tag = input.readTag();
|
||||
switch (tag) {
|
||||
case 0:
|
||||
done = true;
|
||||
break;
|
||||
default: {
|
||||
if (!input.skipField(tag)) {
|
||||
done = true;
|
||||
}
|
||||
break;
|
||||
}
|
||||
case 8: {
|
||||
|
||||
testNum_ = input.readInt32();
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
throw new RuntimeException(e.setUnfinishedMessage(this));
|
||||
} catch (java.io.IOException e) {
|
||||
throw new RuntimeException(
|
||||
new com.google.protobuf.InvalidProtocolBufferException(
|
||||
e.getMessage()).setUnfinishedMessage(this));
|
||||
} finally {
|
||||
makeExtensionsImmutable();
|
||||
}
|
||||
}
|
||||
public static final com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptor() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_StatsRequest_descriptor;
|
||||
}
|
||||
|
||||
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_StatsRequest_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
io.grpc.testing.StatsRequest.class, io.grpc.testing.StatsRequest.Builder.class);
|
||||
}
|
||||
|
||||
public static final int TEST_NUM_FIELD_NUMBER = 1;
|
||||
private int testNum_;
|
||||
/**
|
||||
* <code>optional int32 test_num = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
* run number
|
||||
* </pre>
|
||||
*/
|
||||
public int getTestNum() {
|
||||
return testNum_;
|
||||
}
|
||||
|
||||
private byte memoizedIsInitialized = -1;
|
||||
public final boolean isInitialized() {
|
||||
byte isInitialized = memoizedIsInitialized;
|
||||
if (isInitialized == 1) return true;
|
||||
if (isInitialized == 0) return false;
|
||||
|
||||
memoizedIsInitialized = 1;
|
||||
return true;
|
||||
}
|
||||
|
||||
public void writeTo(com.google.protobuf.CodedOutputStream output)
|
||||
throws java.io.IOException {
|
||||
if (testNum_ != 0) {
|
||||
output.writeInt32(1, testNum_);
|
||||
}
|
||||
}
|
||||
|
||||
public int getSerializedSize() {
|
||||
int size = memoizedSize;
|
||||
if (size != -1) return size;
|
||||
|
||||
size = 0;
|
||||
if (testNum_ != 0) {
|
||||
size += com.google.protobuf.CodedOutputStream
|
||||
.computeInt32Size(1, testNum_);
|
||||
}
|
||||
memoizedSize = size;
|
||||
return size;
|
||||
}
|
||||
|
||||
private static final long serialVersionUID = 0L;
|
||||
public static io.grpc.testing.StatsRequest parseFrom(
|
||||
com.google.protobuf.ByteString data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static io.grpc.testing.StatsRequest parseFrom(
|
||||
com.google.protobuf.ByteString data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.StatsRequest parseFrom(byte[] data)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data);
|
||||
}
|
||||
public static io.grpc.testing.StatsRequest parseFrom(
|
||||
byte[] data,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
return PARSER.parseFrom(data, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.StatsRequest parseFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.StatsRequest parseFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.StatsRequest parseDelimitedFrom(java.io.InputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseDelimitedFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.StatsRequest parseDelimitedFrom(
|
||||
java.io.InputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseDelimitedFrom(input, extensionRegistry);
|
||||
}
|
||||
public static io.grpc.testing.StatsRequest parseFrom(
|
||||
com.google.protobuf.CodedInputStream input)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input);
|
||||
}
|
||||
public static io.grpc.testing.StatsRequest parseFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
return PARSER.parseFrom(input, extensionRegistry);
|
||||
}
|
||||
|
||||
public Builder newBuilderForType() { return newBuilder(); }
|
||||
public static Builder newBuilder() {
|
||||
return DEFAULT_INSTANCE.toBuilder();
|
||||
}
|
||||
public static Builder newBuilder(io.grpc.testing.StatsRequest prototype) {
|
||||
return DEFAULT_INSTANCE.toBuilder().mergeFrom(prototype);
|
||||
}
|
||||
public Builder toBuilder() {
|
||||
return this == DEFAULT_INSTANCE
|
||||
? new Builder() : new Builder().mergeFrom(this);
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
protected Builder newBuilderForType(
|
||||
com.google.protobuf.GeneratedMessage.BuilderParent parent) {
|
||||
Builder builder = new Builder(parent);
|
||||
return builder;
|
||||
}
|
||||
/**
|
||||
* Protobuf type {@code grpc.testing.StatsRequest}
|
||||
*/
|
||||
public static final class Builder extends
|
||||
com.google.protobuf.GeneratedMessage.Builder<Builder> implements
|
||||
// @@protoc_insertion_point(builder_implements:grpc.testing.StatsRequest)
|
||||
io.grpc.testing.StatsRequestOrBuilder {
|
||||
public static final com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptor() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_StatsRequest_descriptor;
|
||||
}
|
||||
|
||||
protected com.google.protobuf.GeneratedMessage.FieldAccessorTable
|
||||
internalGetFieldAccessorTable() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_StatsRequest_fieldAccessorTable
|
||||
.ensureFieldAccessorsInitialized(
|
||||
io.grpc.testing.StatsRequest.class, io.grpc.testing.StatsRequest.Builder.class);
|
||||
}
|
||||
|
||||
// Construct using io.grpc.testing.StatsRequest.newBuilder()
|
||||
private Builder() {
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
|
||||
private Builder(
|
||||
com.google.protobuf.GeneratedMessage.BuilderParent parent) {
|
||||
super(parent);
|
||||
maybeForceBuilderInitialization();
|
||||
}
|
||||
private void maybeForceBuilderInitialization() {
|
||||
if (com.google.protobuf.GeneratedMessage.alwaysUseFieldBuilders) {
|
||||
}
|
||||
}
|
||||
public Builder clear() {
|
||||
super.clear();
|
||||
testNum_ = 0;
|
||||
|
||||
return this;
|
||||
}
|
||||
|
||||
public com.google.protobuf.Descriptors.Descriptor
|
||||
getDescriptorForType() {
|
||||
return io.grpc.testing.QpsTestProto.internal_static_grpc_testing_StatsRequest_descriptor;
|
||||
}
|
||||
|
||||
public io.grpc.testing.StatsRequest getDefaultInstanceForType() {
|
||||
return io.grpc.testing.StatsRequest.getDefaultInstance();
|
||||
}
|
||||
|
||||
public io.grpc.testing.StatsRequest build() {
|
||||
io.grpc.testing.StatsRequest result = buildPartial();
|
||||
if (!result.isInitialized()) {
|
||||
throw newUninitializedMessageException(result);
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
public io.grpc.testing.StatsRequest buildPartial() {
|
||||
io.grpc.testing.StatsRequest result = new io.grpc.testing.StatsRequest(this);
|
||||
result.testNum_ = testNum_;
|
||||
onBuilt();
|
||||
return result;
|
||||
}
|
||||
|
||||
public Builder mergeFrom(com.google.protobuf.Message other) {
|
||||
if (other instanceof io.grpc.testing.StatsRequest) {
|
||||
return mergeFrom((io.grpc.testing.StatsRequest)other);
|
||||
} else {
|
||||
super.mergeFrom(other);
|
||||
return this;
|
||||
}
|
||||
}
|
||||
|
||||
public Builder mergeFrom(io.grpc.testing.StatsRequest other) {
|
||||
if (other == io.grpc.testing.StatsRequest.getDefaultInstance()) return this;
|
||||
if (other.getTestNum() != 0) {
|
||||
setTestNum(other.getTestNum());
|
||||
}
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
|
||||
public final boolean isInitialized() {
|
||||
return true;
|
||||
}
|
||||
|
||||
public Builder mergeFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws java.io.IOException {
|
||||
io.grpc.testing.StatsRequest parsedMessage = null;
|
||||
try {
|
||||
parsedMessage = PARSER.parsePartialFrom(input, extensionRegistry);
|
||||
} catch (com.google.protobuf.InvalidProtocolBufferException e) {
|
||||
parsedMessage = (io.grpc.testing.StatsRequest) e.getUnfinishedMessage();
|
||||
throw e;
|
||||
} finally {
|
||||
if (parsedMessage != null) {
|
||||
mergeFrom(parsedMessage);
|
||||
}
|
||||
}
|
||||
return this;
|
||||
}
|
||||
|
||||
private int testNum_ ;
|
||||
/**
|
||||
* <code>optional int32 test_num = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
* run number
|
||||
* </pre>
|
||||
*/
|
||||
public int getTestNum() {
|
||||
return testNum_;
|
||||
}
|
||||
/**
|
||||
* <code>optional int32 test_num = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
* run number
|
||||
* </pre>
|
||||
*/
|
||||
public Builder setTestNum(int value) {
|
||||
|
||||
testNum_ = value;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
/**
|
||||
* <code>optional int32 test_num = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
* run number
|
||||
* </pre>
|
||||
*/
|
||||
public Builder clearTestNum() {
|
||||
|
||||
testNum_ = 0;
|
||||
onChanged();
|
||||
return this;
|
||||
}
|
||||
public final Builder setUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return this;
|
||||
}
|
||||
|
||||
public final Builder mergeUnknownFields(
|
||||
final com.google.protobuf.UnknownFieldSet unknownFields) {
|
||||
return this;
|
||||
}
|
||||
|
||||
|
||||
// @@protoc_insertion_point(builder_scope:grpc.testing.StatsRequest)
|
||||
}
|
||||
|
||||
// @@protoc_insertion_point(class_scope:grpc.testing.StatsRequest)
|
||||
private static final io.grpc.testing.StatsRequest DEFAULT_INSTANCE;
|
||||
static {
|
||||
DEFAULT_INSTANCE = new io.grpc.testing.StatsRequest();
|
||||
}
|
||||
|
||||
public static io.grpc.testing.StatsRequest getDefaultInstance() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
private static final com.google.protobuf.Parser<StatsRequest>
|
||||
PARSER = new com.google.protobuf.AbstractParser<StatsRequest>() {
|
||||
public StatsRequest parsePartialFrom(
|
||||
com.google.protobuf.CodedInputStream input,
|
||||
com.google.protobuf.ExtensionRegistryLite extensionRegistry)
|
||||
throws com.google.protobuf.InvalidProtocolBufferException {
|
||||
try {
|
||||
return new StatsRequest(input, extensionRegistry);
|
||||
} catch (RuntimeException e) {
|
||||
if (e.getCause() instanceof
|
||||
com.google.protobuf.InvalidProtocolBufferException) {
|
||||
throw (com.google.protobuf.InvalidProtocolBufferException)
|
||||
e.getCause();
|
||||
}
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
public static com.google.protobuf.Parser<StatsRequest> parser() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
@java.lang.Override
|
||||
public com.google.protobuf.Parser<StatsRequest> getParserForType() {
|
||||
return PARSER;
|
||||
}
|
||||
|
||||
public io.grpc.testing.StatsRequest getDefaultInstanceForType() {
|
||||
return DEFAULT_INSTANCE;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
|
|
@ -1,18 +0,0 @@
|
|||
// Generated by the protocol buffer compiler. DO NOT EDIT!
|
||||
// source: qpstest.proto
|
||||
|
||||
package io.grpc.testing;
|
||||
|
||||
public interface StatsRequestOrBuilder extends
|
||||
// @@protoc_insertion_point(interface_extends:grpc.testing.StatsRequest)
|
||||
com.google.protobuf.MessageOrBuilder {
|
||||
|
||||
/**
|
||||
* <code>optional int32 test_num = 1;</code>
|
||||
*
|
||||
* <pre>
|
||||
* run number
|
||||
* </pre>
|
||||
*/
|
||||
int getTestNum();
|
||||
}
|
||||
|
|
@ -37,6 +37,10 @@ import com.google.protobuf.ByteString;
|
|||
|
||||
import io.grpc.ManagedChannel;
|
||||
import io.grpc.Server;
|
||||
import io.grpc.benchmarks.proto.BenchmarkServiceGrpc;
|
||||
import io.grpc.benchmarks.proto.Messages.Payload;
|
||||
import io.grpc.benchmarks.proto.Messages.SimpleRequest;
|
||||
import io.grpc.benchmarks.proto.Messages.SimpleResponse;
|
||||
import io.grpc.benchmarks.qps.AsyncServer;
|
||||
import io.grpc.inprocess.InProcessChannelBuilder;
|
||||
import io.grpc.inprocess.InProcessServerBuilder;
|
||||
|
|
@ -46,10 +50,6 @@ import io.grpc.netty.NegotiationType;
|
|||
import io.grpc.netty.NettyChannelBuilder;
|
||||
import io.grpc.netty.NettyServerBuilder;
|
||||
import io.grpc.okhttp.OkHttpChannelBuilder;
|
||||
import io.grpc.testing.Payload;
|
||||
import io.grpc.testing.SimpleRequest;
|
||||
import io.grpc.testing.SimpleResponse;
|
||||
import io.grpc.testing.TestServiceGrpc;
|
||||
import io.netty.channel.local.LocalAddress;
|
||||
import io.netty.channel.local.LocalChannel;
|
||||
import io.netty.channel.local.LocalServerChannel;
|
||||
|
|
@ -81,7 +81,7 @@ public class TransportBenchmark {
|
|||
|
||||
private ManagedChannel channel;
|
||||
private Server server;
|
||||
private TestServiceGrpc.TestServiceBlockingStub stub;
|
||||
private BenchmarkServiceGrpc.BenchmarkServiceBlockingStub stub;
|
||||
|
||||
@Setup
|
||||
public void setUp() throws Exception {
|
||||
|
|
@ -134,11 +134,11 @@ public class TransportBenchmark {
|
|||
}
|
||||
|
||||
server = serverBuilder
|
||||
.addService(TestServiceGrpc.bindService(new AsyncServer.TestServiceImpl()))
|
||||
.addService(BenchmarkServiceGrpc.bindService(new AsyncServer.BenchmarkServiceImpl()))
|
||||
.build();
|
||||
server.start();
|
||||
channel = channelBuilder.build();
|
||||
stub = TestServiceGrpc.newBlockingStub(channel);
|
||||
stub = BenchmarkServiceGrpc.newBlockingStub(channel);
|
||||
// Wait for channel to start
|
||||
stub.unaryCall(SimpleRequest.getDefaultInstance());
|
||||
}
|
||||
|
|
|
|||
|
|
@ -57,12 +57,12 @@ import com.google.protobuf.ByteString;
|
|||
import io.grpc.Channel;
|
||||
import io.grpc.ManagedChannel;
|
||||
import io.grpc.Status;
|
||||
import io.grpc.benchmarks.proto.BenchmarkServiceGrpc;
|
||||
import io.grpc.benchmarks.proto.BenchmarkServiceGrpc.BenchmarkServiceStub;
|
||||
import io.grpc.benchmarks.proto.Messages.Payload;
|
||||
import io.grpc.benchmarks.proto.Messages.SimpleRequest;
|
||||
import io.grpc.benchmarks.proto.Messages.SimpleResponse;
|
||||
import io.grpc.stub.StreamObserver;
|
||||
import io.grpc.testing.Payload;
|
||||
import io.grpc.testing.SimpleRequest;
|
||||
import io.grpc.testing.SimpleResponse;
|
||||
import io.grpc.testing.TestServiceGrpc;
|
||||
import io.grpc.testing.TestServiceGrpc.TestServiceStub;
|
||||
|
||||
import org.HdrHistogram.Histogram;
|
||||
import org.HdrHistogram.HistogramIterationValue;
|
||||
|
|
@ -172,7 +172,7 @@ public class AsyncClient {
|
|||
|
||||
private Future<Histogram> doUnaryCalls(Channel channel, final SimpleRequest request,
|
||||
final long endTime) {
|
||||
final TestServiceStub stub = TestServiceGrpc.newStub(channel);
|
||||
final BenchmarkServiceStub stub = BenchmarkServiceGrpc.newStub(channel);
|
||||
final Histogram histogram = new Histogram(HISTOGRAM_MAX_VALUE, HISTOGRAM_PRECISION);
|
||||
final HistogramFuture future = new HistogramFuture(histogram);
|
||||
|
||||
|
|
@ -212,7 +212,7 @@ public class AsyncClient {
|
|||
|
||||
private static Future<Histogram> doStreamingCalls(Channel channel, final SimpleRequest request,
|
||||
final long endTime) {
|
||||
final TestServiceStub stub = TestServiceGrpc.newStub(channel);
|
||||
final BenchmarkServiceStub stub = BenchmarkServiceGrpc.newStub(channel);
|
||||
final Histogram histogram = new Histogram(HISTOGRAM_MAX_VALUE, HISTOGRAM_PRECISION);
|
||||
final HistogramFuture future = new HistogramFuture(histogram);
|
||||
|
||||
|
|
|
|||
|
|
@ -35,14 +35,14 @@ import com.google.protobuf.ByteString;
|
|||
|
||||
import io.grpc.Server;
|
||||
import io.grpc.Status;
|
||||
import io.grpc.benchmarks.proto.BenchmarkServiceGrpc;
|
||||
import io.grpc.benchmarks.proto.Messages.Payload;
|
||||
import io.grpc.benchmarks.proto.Messages.PayloadType;
|
||||
import io.grpc.benchmarks.proto.Messages.SimpleRequest;
|
||||
import io.grpc.benchmarks.proto.Messages.SimpleResponse;
|
||||
import io.grpc.netty.GrpcSslContexts;
|
||||
import io.grpc.netty.NettyServerBuilder;
|
||||
import io.grpc.stub.StreamObserver;
|
||||
import io.grpc.testing.Payload;
|
||||
import io.grpc.testing.PayloadType;
|
||||
import io.grpc.testing.SimpleRequest;
|
||||
import io.grpc.testing.SimpleResponse;
|
||||
import io.grpc.testing.TestServiceGrpc;
|
||||
import io.grpc.testing.TestUtils;
|
||||
import io.netty.channel.EventLoopGroup;
|
||||
import io.netty.channel.ServerChannel;
|
||||
|
|
@ -171,7 +171,7 @@ public class AsyncServer {
|
|||
.bossEventLoopGroup(boss)
|
||||
.workerEventLoopGroup(worker)
|
||||
.channelType(channelType)
|
||||
.addService(TestServiceGrpc.bindService(new TestServiceImpl()))
|
||||
.addService(BenchmarkServiceGrpc.bindService(new BenchmarkServiceImpl()))
|
||||
.sslContext(sslContext)
|
||||
.flowControlWindow(config.flowControlWindow);
|
||||
if (config.directExecutor) {
|
||||
|
|
@ -181,7 +181,7 @@ public class AsyncServer {
|
|||
return builder.build();
|
||||
}
|
||||
|
||||
public static class TestServiceImpl implements TestServiceGrpc.TestService {
|
||||
public static class BenchmarkServiceImpl implements BenchmarkServiceGrpc.BenchmarkService {
|
||||
|
||||
@Override
|
||||
public void unaryCall(SimpleRequest request, StreamObserver<SimpleResponse> responseObserver) {
|
||||
|
|
|
|||
|
|
@ -34,14 +34,12 @@ package io.grpc.benchmarks.qps;
|
|||
import static io.grpc.benchmarks.qps.SocketAddressValidator.INET;
|
||||
import static io.grpc.benchmarks.qps.SocketAddressValidator.UDS;
|
||||
import static io.grpc.benchmarks.qps.Utils.parseBoolean;
|
||||
import static io.grpc.testing.RpcType.STREAMING;
|
||||
import static io.grpc.testing.RpcType.UNARY;
|
||||
import static java.lang.Integer.parseInt;
|
||||
import static java.util.Arrays.asList;
|
||||
|
||||
import io.grpc.benchmarks.proto.Control.RpcType;
|
||||
import io.grpc.benchmarks.proto.Messages.PayloadType;
|
||||
import io.grpc.netty.NettyChannelBuilder;
|
||||
import io.grpc.testing.PayloadType;
|
||||
import io.grpc.testing.RpcType;
|
||||
import io.grpc.testing.TestUtils;
|
||||
|
||||
import java.net.InetSocketAddress;
|
||||
|
|
@ -74,7 +72,7 @@ class ClientConfiguration implements Configuration {
|
|||
int warmupDuration = 10;
|
||||
int targetQps;
|
||||
String histogramFile;
|
||||
RpcType rpcType = UNARY;
|
||||
RpcType rpcType = RpcType.UNARY;
|
||||
PayloadType payloadType = PayloadType.COMPRESSABLE;
|
||||
|
||||
private ClientConfiguration() {
|
||||
|
|
@ -276,7 +274,7 @@ class ClientConfiguration implements Configuration {
|
|||
STREAMING_RPCS("", "Use Streaming RPCs.", "false") {
|
||||
@Override
|
||||
protected void setClientValue(ClientConfiguration config, String value) {
|
||||
config.rpcType = STREAMING;
|
||||
config.rpcType = RpcType.STREAMING;
|
||||
}
|
||||
},
|
||||
FLOW_CONTROL_WINDOW("BYTES", "The HTTP/2 flow control window.",
|
||||
|
|
|
|||
|
|
@ -52,11 +52,11 @@ import static io.grpc.benchmarks.qps.Utils.saveHistogram;
|
|||
import io.grpc.Channel;
|
||||
import io.grpc.ManagedChannel;
|
||||
import io.grpc.Status;
|
||||
import io.grpc.benchmarks.proto.BenchmarkServiceGrpc;
|
||||
import io.grpc.benchmarks.proto.Messages.SimpleRequest;
|
||||
import io.grpc.benchmarks.proto.Messages.SimpleResponse;
|
||||
|
||||
import io.grpc.stub.StreamObserver;
|
||||
import io.grpc.testing.SimpleRequest;
|
||||
import io.grpc.testing.SimpleResponse;
|
||||
import io.grpc.testing.TestServiceGrpc;
|
||||
import io.grpc.testing.TestServiceGrpc.TestServiceStub;
|
||||
|
||||
import org.HdrHistogram.AtomicHistogram;
|
||||
import org.HdrHistogram.Histogram;
|
||||
|
|
@ -147,14 +147,14 @@ public class OpenLoopClient {
|
|||
|
||||
static class LoadGenerationWorker implements Callable<Histogram> {
|
||||
final Histogram histogram = new AtomicHistogram(HISTOGRAM_MAX_VALUE, HISTOGRAM_PRECISION);
|
||||
final TestServiceStub stub;
|
||||
final BenchmarkServiceGrpc.BenchmarkServiceStub stub;
|
||||
final SimpleRequest request;
|
||||
final Random rnd;
|
||||
final int targetQps;
|
||||
final long numRpcs;
|
||||
|
||||
LoadGenerationWorker(Channel channel, SimpleRequest request, int targetQps, int duration) {
|
||||
stub = TestServiceGrpc.newStub(checkNotNull(channel, "channel"));
|
||||
stub = BenchmarkServiceGrpc.newStub(checkNotNull(channel, "channel"));
|
||||
this.request = checkNotNull(request, "request");
|
||||
this.targetQps = targetQps;
|
||||
numRpcs = targetQps * duration;
|
||||
|
|
@ -197,7 +197,7 @@ public class OpenLoopClient {
|
|||
return histogram;
|
||||
}
|
||||
|
||||
private void newRpc(TestServiceStub stub) {
|
||||
private void newRpc(BenchmarkServiceGrpc.BenchmarkServiceStub stub) {
|
||||
stub.unaryCall(request, new StreamObserver<SimpleResponse>() {
|
||||
|
||||
private final long start = System.nanoTime();
|
||||
|
|
|
|||
|
|
@ -35,13 +35,13 @@ import com.google.common.util.concurrent.ThreadFactoryBuilder;
|
|||
import com.google.protobuf.ByteString;
|
||||
|
||||
import io.grpc.ManagedChannel;
|
||||
import io.grpc.benchmarks.proto.Messages.Payload;
|
||||
import io.grpc.benchmarks.proto.Messages.SimpleRequest;
|
||||
import io.grpc.internal.GrpcUtil;
|
||||
import io.grpc.netty.GrpcSslContexts;
|
||||
import io.grpc.netty.NegotiationType;
|
||||
import io.grpc.netty.NettyChannelBuilder;
|
||||
import io.grpc.okhttp.OkHttpChannelBuilder;
|
||||
import io.grpc.testing.Payload;
|
||||
import io.grpc.testing.SimpleRequest;
|
||||
import io.grpc.testing.TestUtils;
|
||||
import io.netty.channel.EventLoopGroup;
|
||||
import io.netty.channel.epoll.EpollDomainSocketChannel;
|
||||
|
|
|
|||
|
|
@ -0,0 +1,175 @@
|
|||
// Copyright 2015-2016, Google Inc.
|
||||
// All rights reserved.
|
||||
//
|
||||
// Redistribution and use in source and binary forms, with or without
|
||||
// modification, are permitted provided that the following conditions are
|
||||
// met:
|
||||
//
|
||||
// * Redistributions of source code must retain the above copyright
|
||||
// notice, this list of conditions and the following disclaimer.
|
||||
// * Redistributions in binary form must reproduce the above
|
||||
// copyright notice, this list of conditions and the following disclaimer
|
||||
// in the documentation and/or other materials provided with the
|
||||
// distribution.
|
||||
// * Neither the name of Google Inc. nor the names of its
|
||||
// contributors may be used to endorse or promote products derived from
|
||||
// this software without specific prior written permission.
|
||||
//
|
||||
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
syntax = "proto3";
|
||||
|
||||
import "payloads.proto";
|
||||
import "stats.proto";
|
||||
|
||||
package grpc.testing;
|
||||
|
||||
option java_package = "io.grpc.benchmarks.proto";
|
||||
option java_outer_classname = "Control";
|
||||
|
||||
enum ClientType {
|
||||
SYNC_CLIENT = 0;
|
||||
ASYNC_CLIENT = 1;
|
||||
}
|
||||
|
||||
enum ServerType {
|
||||
SYNC_SERVER = 0;
|
||||
ASYNC_SERVER = 1;
|
||||
ASYNC_GENERIC_SERVER = 2;
|
||||
}
|
||||
|
||||
enum RpcType {
|
||||
UNARY = 0;
|
||||
STREAMING = 1;
|
||||
}
|
||||
|
||||
// Parameters of poisson process distribution, which is a good representation
|
||||
// of activity coming in from independent identical stationary sources.
|
||||
message PoissonParams {
|
||||
// The rate of arrivals (a.k.a. lambda parameter of the exp distribution).
|
||||
double offered_load = 1;
|
||||
}
|
||||
|
||||
message UniformParams {
|
||||
double interarrival_lo = 1;
|
||||
double interarrival_hi = 2;
|
||||
}
|
||||
|
||||
message DeterministicParams { double offered_load = 1; }
|
||||
|
||||
message ParetoParams {
|
||||
double interarrival_base = 1;
|
||||
double alpha = 2;
|
||||
}
|
||||
|
||||
// Once an RPC finishes, immediately start a new one.
|
||||
// No configuration parameters needed.
|
||||
message ClosedLoopParams {}
|
||||
|
||||
message LoadParams {
|
||||
oneof load {
|
||||
ClosedLoopParams closed_loop = 1;
|
||||
PoissonParams poisson = 2;
|
||||
UniformParams uniform = 3;
|
||||
DeterministicParams determ = 4;
|
||||
ParetoParams pareto = 5;
|
||||
};
|
||||
}
|
||||
|
||||
// presence of SecurityParams implies use of TLS
|
||||
message SecurityParams {
|
||||
bool use_test_ca = 1;
|
||||
string server_host_override = 2;
|
||||
}
|
||||
|
||||
message ClientConfig {
|
||||
// List of targets to connect to. At least one target needs to be specified.
|
||||
repeated string server_targets = 1;
|
||||
ClientType client_type = 2;
|
||||
SecurityParams security_params = 3;
|
||||
// How many concurrent RPCs to start for each channel.
|
||||
// For synchronous client, use a separate thread for each outstanding RPC.
|
||||
int32 outstanding_rpcs_per_channel = 4;
|
||||
// Number of independent client channels to create.
|
||||
// i-th channel will connect to server_target[i % server_targets.size()]
|
||||
int32 client_channels = 5;
|
||||
// Only for async client. Number of threads to use to start/manage RPCs.
|
||||
int32 async_client_threads = 7;
|
||||
RpcType rpc_type = 8;
|
||||
// The requested load for the entire client (aggregated over all the threads).
|
||||
LoadParams load_params = 10;
|
||||
PayloadConfig payload_config = 11;
|
||||
HistogramParams histogram_params = 12;
|
||||
|
||||
// Specify the cores we should run the client on, if desired
|
||||
repeated int32 core_list = 13;
|
||||
int32 core_limit = 14;
|
||||
}
|
||||
|
||||
message ClientStatus { ClientStats stats = 1; }
|
||||
|
||||
// Request current stats
|
||||
message Mark {
|
||||
// if true, the stats will be reset after taking their snapshot.
|
||||
bool reset = 1;
|
||||
}
|
||||
|
||||
message ClientArgs {
|
||||
oneof argtype {
|
||||
ClientConfig setup = 1;
|
||||
Mark mark = 2;
|
||||
}
|
||||
}
|
||||
|
||||
message ServerConfig {
|
||||
ServerType server_type = 1;
|
||||
SecurityParams security_params = 2;
|
||||
// Port on which to listen. Zero means pick unused port.
|
||||
int32 port = 4;
|
||||
// Only for async server. Number of threads used to serve the requests.
|
||||
int32 async_server_threads = 7;
|
||||
// Specify the number of cores to limit server to, if desired
|
||||
int32 core_limit = 8;
|
||||
// payload config, used in generic server
|
||||
PayloadConfig payload_config = 9;
|
||||
|
||||
// Specify the cores we should run the server on, if desired
|
||||
repeated int32 core_list = 10;
|
||||
}
|
||||
|
||||
message ServerArgs {
|
||||
oneof argtype {
|
||||
ServerConfig setup = 1;
|
||||
Mark mark = 2;
|
||||
}
|
||||
}
|
||||
|
||||
message ServerStatus {
|
||||
ServerStats stats = 1;
|
||||
// the port bound by the server
|
||||
int32 port = 2;
|
||||
// Number of cores available to the server
|
||||
int32 cores = 3;
|
||||
}
|
||||
|
||||
message CoreRequest {
|
||||
}
|
||||
|
||||
message CoreResponse {
|
||||
// Number of cores available on the server
|
||||
int32 cores = 1;
|
||||
}
|
||||
|
||||
message Void {
|
||||
}
|
||||
|
||||
|
|
@ -0,0 +1,170 @@
|
|||
// Copyright 2015, Google Inc.
|
||||
// All rights reserved.
|
||||
//
|
||||
// Redistribution and use in source and binary forms, with or without
|
||||
// modification, are permitted provided that the following conditions are
|
||||
// met:
|
||||
//
|
||||
// * Redistributions of source code must retain the above copyright
|
||||
// notice, this list of conditions and the following disclaimer.
|
||||
// * Redistributions in binary form must reproduce the above
|
||||
// copyright notice, this list of conditions and the following disclaimer
|
||||
// in the documentation and/or other materials provided with the
|
||||
// distribution.
|
||||
// * Neither the name of Google Inc. nor the names of its
|
||||
// contributors may be used to endorse or promote products derived from
|
||||
// this software without specific prior written permission.
|
||||
//
|
||||
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
// Message definitions to be used by integration test service definitions.
|
||||
|
||||
syntax = "proto3";
|
||||
|
||||
package grpc.testing;
|
||||
|
||||
option java_package = "io.grpc.benchmarks.proto";
|
||||
option java_outer_classname = "Messages";
|
||||
|
||||
|
||||
// The type of payload that should be returned.
|
||||
enum PayloadType {
|
||||
// Compressable text format.
|
||||
COMPRESSABLE = 0;
|
||||
|
||||
// Uncompressable binary format.
|
||||
UNCOMPRESSABLE = 1;
|
||||
|
||||
// Randomly chosen from all other formats defined in this enum.
|
||||
RANDOM = 2;
|
||||
}
|
||||
|
||||
// Compression algorithms
|
||||
enum CompressionType {
|
||||
// No compression
|
||||
NONE = 0;
|
||||
GZIP = 1;
|
||||
DEFLATE = 2;
|
||||
}
|
||||
|
||||
// A block of data, to simply increase gRPC message size.
|
||||
message Payload {
|
||||
// The type of data in body.
|
||||
PayloadType type = 1;
|
||||
// Primary contents of payload.
|
||||
bytes body = 2;
|
||||
}
|
||||
|
||||
// A protobuf representation for grpc status. This is used by test
|
||||
// clients to specify a status that the server should attempt to return.
|
||||
message EchoStatus {
|
||||
int32 code = 1;
|
||||
string message = 2;
|
||||
}
|
||||
|
||||
// Unary request.
|
||||
message SimpleRequest {
|
||||
// Desired payload type in the response from the server.
|
||||
// If response_type is RANDOM, server randomly chooses one from other formats.
|
||||
PayloadType response_type = 1;
|
||||
|
||||
// Desired payload size in the response from the server.
|
||||
// If response_type is COMPRESSABLE, this denotes the size before compression.
|
||||
int32 response_size = 2;
|
||||
|
||||
// Optional input payload sent along with the request.
|
||||
Payload payload = 3;
|
||||
|
||||
// Whether SimpleResponse should include username.
|
||||
bool fill_username = 4;
|
||||
|
||||
// Whether SimpleResponse should include OAuth scope.
|
||||
bool fill_oauth_scope = 5;
|
||||
|
||||
// Compression algorithm to be used by the server for the response (stream)
|
||||
CompressionType response_compression = 6;
|
||||
|
||||
// Whether server should return a given status
|
||||
EchoStatus response_status = 7;
|
||||
}
|
||||
|
||||
// Unary response, as configured by the request.
|
||||
message SimpleResponse {
|
||||
// Payload to increase message size.
|
||||
Payload payload = 1;
|
||||
// The user the request came from, for verifying authentication was
|
||||
// successful when the client expected it.
|
||||
string username = 2;
|
||||
// OAuth scope.
|
||||
string oauth_scope = 3;
|
||||
}
|
||||
|
||||
// Client-streaming request.
|
||||
message StreamingInputCallRequest {
|
||||
// Optional input payload sent along with the request.
|
||||
Payload payload = 1;
|
||||
|
||||
// Not expecting any payload from the response.
|
||||
}
|
||||
|
||||
// Client-streaming response.
|
||||
message StreamingInputCallResponse {
|
||||
// Aggregated size of payloads received from the client.
|
||||
int32 aggregated_payload_size = 1;
|
||||
}
|
||||
|
||||
// Configuration for a particular response.
|
||||
message ResponseParameters {
|
||||
// Desired payload sizes in responses from the server.
|
||||
// If response_type is COMPRESSABLE, this denotes the size before compression.
|
||||
int32 size = 1;
|
||||
|
||||
// Desired interval between consecutive responses in the response stream in
|
||||
// microseconds.
|
||||
int32 interval_us = 2;
|
||||
}
|
||||
|
||||
// Server-streaming request.
|
||||
message StreamingOutputCallRequest {
|
||||
// Desired payload type in the response from the server.
|
||||
// If response_type is RANDOM, the payload from each response in the stream
|
||||
// might be of different types. This is to simulate a mixed type of payload
|
||||
// stream.
|
||||
PayloadType response_type = 1;
|
||||
|
||||
// Configuration for each expected response message.
|
||||
repeated ResponseParameters response_parameters = 2;
|
||||
|
||||
// Optional input payload sent along with the request.
|
||||
Payload payload = 3;
|
||||
|
||||
// Compression algorithm to be used by the server for the response (stream)
|
||||
CompressionType response_compression = 6;
|
||||
|
||||
// Whether server should return a given status
|
||||
EchoStatus response_status = 7;
|
||||
}
|
||||
|
||||
// Server-streaming response, as configured by the request and parameters.
|
||||
message StreamingOutputCallResponse {
|
||||
// Payload to increase response size.
|
||||
Payload payload = 1;
|
||||
}
|
||||
|
||||
// For reconnect interop test only.
|
||||
// Server tells client whether its reconnects are following the spec and the
|
||||
// reconnect backoffs it saw.
|
||||
message ReconnectInfo {
|
||||
bool passed = 1;
|
||||
repeated int32 backoff_ms = 2;
|
||||
}
|
||||
|
|
@ -0,0 +1,58 @@
|
|||
// Copyright 2015, Google Inc.
|
||||
// All rights reserved.
|
||||
//
|
||||
// Redistribution and use in source and binary forms, with or without
|
||||
// modification, are permitted provided that the following conditions are
|
||||
// met:
|
||||
//
|
||||
// * Redistributions of source code must retain the above copyright
|
||||
// notice, this list of conditions and the following disclaimer.
|
||||
// * Redistributions in binary form must reproduce the above
|
||||
// copyright notice, this list of conditions and the following disclaimer
|
||||
// in the documentation and/or other materials provided with the
|
||||
// distribution.
|
||||
// * Neither the name of Google Inc. nor the names of its
|
||||
// contributors may be used to endorse or promote products derived from
|
||||
// this software without specific prior written permission.
|
||||
//
|
||||
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
syntax = "proto3";
|
||||
|
||||
package grpc.testing;
|
||||
|
||||
option java_package = "io.grpc.benchmarks.proto";
|
||||
option java_outer_classname = "Payloads";
|
||||
|
||||
message ByteBufferParams {
|
||||
int32 req_size = 1;
|
||||
int32 resp_size = 2;
|
||||
}
|
||||
|
||||
message SimpleProtoParams {
|
||||
int32 req_size = 1;
|
||||
int32 resp_size = 2;
|
||||
}
|
||||
|
||||
message ComplexProtoParams {
|
||||
// TODO (vpai): Fill this in once the details of complex, representative
|
||||
// protos are decided
|
||||
}
|
||||
|
||||
message PayloadConfig {
|
||||
oneof payload {
|
||||
ByteBufferParams bytebuf_params = 1;
|
||||
SimpleProtoParams simple_params = 2;
|
||||
ComplexProtoParams complex_params = 3;
|
||||
}
|
||||
}
|
||||
|
|
@ -1,182 +0,0 @@
|
|||
|
||||
// Copyright 2015, Google Inc.
|
||||
// All rights reserved.
|
||||
//
|
||||
// Redistribution and use in source and binary forms, with or without
|
||||
// modification, are permitted provided that the following conditions are
|
||||
// met:
|
||||
//
|
||||
// * Redistributions of source code must retain the above copyright
|
||||
// notice, this list of conditions and the following disclaimer.
|
||||
// * Redistributions in binary form must reproduce the above
|
||||
// copyright notice, this list of conditions and the following disclaimer
|
||||
// in the documentation and/or other materials provided with the
|
||||
// distribution.
|
||||
// * Neither the name of Google Inc. nor the names of its
|
||||
// contributors may be used to endorse or promote products derived from
|
||||
// this software without specific prior written permission.
|
||||
//
|
||||
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
// An integration test service that covers all the method signature permutations
|
||||
// of unary/streaming requests/responses.
|
||||
syntax = "proto3";
|
||||
|
||||
package grpc.testing;
|
||||
|
||||
option java_multiple_files = true;
|
||||
option java_package = "io.grpc.testing";
|
||||
option java_outer_classname = "QpsTestProto";
|
||||
|
||||
enum PayloadType {
|
||||
// Compressable text format.
|
||||
COMPRESSABLE = 0;
|
||||
|
||||
// Uncompressable binary format.
|
||||
UNCOMPRESSABLE = 1;
|
||||
|
||||
// Randomly chosen from all other formats defined in this enum.
|
||||
RANDOM = 2;
|
||||
}
|
||||
|
||||
message StatsRequest {
|
||||
// run number
|
||||
int32 test_num = 1;
|
||||
}
|
||||
|
||||
message ServerStats {
|
||||
// wall clock time
|
||||
double time_elapsed = 1;
|
||||
|
||||
// user time used by the server process and threads
|
||||
double time_user = 2;
|
||||
|
||||
// server time used by the server process and all threads
|
||||
double time_system = 3;
|
||||
}
|
||||
|
||||
message Payload {
|
||||
// The type of data in body.
|
||||
PayloadType type = 1;
|
||||
// Primary contents of payload.
|
||||
bytes body = 2;
|
||||
}
|
||||
|
||||
message HistogramData {
|
||||
repeated uint32 bucket = 1;
|
||||
double min_seen = 2;
|
||||
double max_seen = 3;
|
||||
double sum = 4;
|
||||
double sum_of_squares = 5;
|
||||
double count = 6;
|
||||
}
|
||||
|
||||
enum ClientType {
|
||||
SYNCHRONOUS_CLIENT = 0;
|
||||
ASYNC_CLIENT = 1;
|
||||
}
|
||||
|
||||
enum ServerType {
|
||||
SYNCHRONOUS_SERVER = 0;
|
||||
ASYNC_SERVER = 1;
|
||||
}
|
||||
|
||||
enum RpcType {
|
||||
UNARY = 0;
|
||||
STREAMING = 1;
|
||||
}
|
||||
|
||||
message ClientConfig {
|
||||
repeated string server_targets = 1;
|
||||
ClientType client_type = 2;
|
||||
bool enable_ssl = 3;
|
||||
int32 outstanding_rpcs_per_channel = 4;
|
||||
int32 client_channels = 5;
|
||||
int32 payload_size = 6;
|
||||
// only for async client:
|
||||
int32 async_client_threads = 7;
|
||||
RpcType rpc_type = 8;
|
||||
}
|
||||
|
||||
// Request current stats
|
||||
message Mark {}
|
||||
|
||||
message ClientArgs {
|
||||
oneof argtype {
|
||||
ClientConfig setup = 1;
|
||||
Mark mark = 2;
|
||||
}
|
||||
}
|
||||
|
||||
message ClientStats {
|
||||
HistogramData latencies = 1;
|
||||
double time_elapsed = 3;
|
||||
double time_user = 4;
|
||||
double time_system = 5;
|
||||
}
|
||||
|
||||
message ClientStatus {
|
||||
ClientStats stats = 1;
|
||||
}
|
||||
|
||||
message ServerConfig {
|
||||
ServerType server_type = 1;
|
||||
int32 threads = 2;
|
||||
bool enable_ssl = 3;
|
||||
}
|
||||
|
||||
message ServerArgs {
|
||||
oneof argtype {
|
||||
ServerConfig setup = 1;
|
||||
Mark mark = 2;
|
||||
}
|
||||
}
|
||||
|
||||
message ServerStatus {
|
||||
ServerStats stats = 1;
|
||||
int32 port = 2;
|
||||
}
|
||||
|
||||
message SimpleRequest {
|
||||
// Desired payload type in the response from the server.
|
||||
// If response_type is RANDOM, server randomly chooses one from other formats.
|
||||
PayloadType response_type = 1;
|
||||
|
||||
// Desired payload size in the response from the server.
|
||||
// If response_type is COMPRESSABLE, this denotes the size before compression.
|
||||
int32 response_size = 2;
|
||||
|
||||
// Optional input payload sent along with the request.
|
||||
Payload payload = 3;
|
||||
}
|
||||
|
||||
message SimpleResponse {
|
||||
Payload payload = 1;
|
||||
}
|
||||
|
||||
service TestService {
|
||||
// One request followed by one response.
|
||||
// The server returns the client payload as-is.
|
||||
rpc UnaryCall(SimpleRequest) returns (SimpleResponse);
|
||||
|
||||
// One request followed by one response.
|
||||
// The server returns the client payload as-is.
|
||||
rpc StreamingCall(stream SimpleRequest) returns (stream SimpleResponse);
|
||||
}
|
||||
|
||||
service Worker {
|
||||
// Start test with specified workload
|
||||
rpc RunTest(stream ClientArgs) returns (stream ClientStatus);
|
||||
// Start test with specified workload
|
||||
rpc RunServer(stream ServerArgs) returns (stream ServerStatus);
|
||||
}
|
||||
|
|
@ -0,0 +1,75 @@
|
|||
// Copyright 2015-2016, Google Inc.
|
||||
// All rights reserved.
|
||||
//
|
||||
// Redistribution and use in source and binary forms, with or without
|
||||
// modification, are permitted provided that the following conditions are
|
||||
// met:
|
||||
//
|
||||
// * Redistributions of source code must retain the above copyright
|
||||
// notice, this list of conditions and the following disclaimer.
|
||||
// * Redistributions in binary form must reproduce the above
|
||||
// copyright notice, this list of conditions and the following disclaimer
|
||||
// in the documentation and/or other materials provided with the
|
||||
// distribution.
|
||||
// * Neither the name of Google Inc. nor the names of its
|
||||
// contributors may be used to endorse or promote products derived from
|
||||
// this software without specific prior written permission.
|
||||
//
|
||||
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
// An integration test service that covers all the method signature permutations
|
||||
// of unary/streaming requests/responses.
|
||||
syntax = "proto3";
|
||||
|
||||
import "messages.proto";
|
||||
import "control.proto";
|
||||
|
||||
package grpc.testing;
|
||||
|
||||
option java_package = "io.grpc.benchmarks.proto";
|
||||
option java_outer_classname = "Services";
|
||||
|
||||
|
||||
service BenchmarkService {
|
||||
// One request followed by one response.
|
||||
// The server returns the client payload as-is.
|
||||
rpc UnaryCall(SimpleRequest) returns (SimpleResponse);
|
||||
|
||||
// One request followed by one response.
|
||||
// The server returns the client payload as-is.
|
||||
rpc StreamingCall(stream SimpleRequest) returns (stream SimpleResponse);
|
||||
}
|
||||
|
||||
service WorkerService {
|
||||
// Start server with specified workload.
|
||||
// First request sent specifies the ServerConfig followed by ServerStatus
|
||||
// response. After that, a "Mark" can be sent anytime to request the latest
|
||||
// stats. Closing the stream will initiate shutdown of the test server
|
||||
// and once the shutdown has finished, the OK status is sent to terminate
|
||||
// this RPC.
|
||||
rpc RunServer(stream ServerArgs) returns (stream ServerStatus);
|
||||
|
||||
// Start client with specified workload.
|
||||
// First request sent specifies the ClientConfig followed by ClientStatus
|
||||
// response. After that, a "Mark" can be sent anytime to request the latest
|
||||
// stats. Closing the stream will initiate shutdown of the test client
|
||||
// and once the shutdown has finished, the OK status is sent to terminate
|
||||
// this RPC.
|
||||
rpc RunClient(stream ClientArgs) returns (stream ClientStatus);
|
||||
|
||||
// Just return the core count - unary call
|
||||
rpc CoreCount(CoreRequest) returns (CoreResponse);
|
||||
|
||||
// Quit this worker
|
||||
rpc QuitWorker(Void) returns (Void);
|
||||
}
|
||||
|
|
@ -0,0 +1,73 @@
|
|||
// Copyright 2015, Google Inc.
|
||||
// All rights reserved.
|
||||
//
|
||||
// Redistribution and use in source and binary forms, with or without
|
||||
// modification, are permitted provided that the following conditions are
|
||||
// met:
|
||||
//
|
||||
// * Redistributions of source code must retain the above copyright
|
||||
// notice, this list of conditions and the following disclaimer.
|
||||
// * Redistributions in binary form must reproduce the above
|
||||
// copyright notice, this list of conditions and the following disclaimer
|
||||
// in the documentation and/or other materials provided with the
|
||||
// distribution.
|
||||
// * Neither the name of Google Inc. nor the names of its
|
||||
// contributors may be used to endorse or promote products derived from
|
||||
// this software without specific prior written permission.
|
||||
//
|
||||
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
|
||||
// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
|
||||
// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
|
||||
// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
|
||||
// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
|
||||
// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
|
||||
// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
|
||||
// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
|
||||
// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
|
||||
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
|
||||
syntax = "proto3";
|
||||
|
||||
package grpc.testing;
|
||||
|
||||
option java_package = "io.grpc.benchmarks.proto";
|
||||
option java_outer_classname = "Stats";
|
||||
|
||||
message ServerStats {
|
||||
// wall clock time change in seconds since last reset
|
||||
double time_elapsed = 1;
|
||||
|
||||
// change in user time (in seconds) used by the server since last reset
|
||||
double time_user = 2;
|
||||
|
||||
// change in server time (in seconds) used by the server process and all
|
||||
// threads since last reset
|
||||
double time_system = 3;
|
||||
}
|
||||
|
||||
// Histogram params based on grpc/support/histogram.c
|
||||
message HistogramParams {
|
||||
double resolution = 1; // first bucket is [0, 1 + resolution)
|
||||
double max_possible = 2; // use enough buckets to allow this value
|
||||
}
|
||||
|
||||
// Histogram data based on grpc/support/histogram.c
|
||||
message HistogramData {
|
||||
repeated uint32 bucket = 1;
|
||||
double min_seen = 2;
|
||||
double max_seen = 3;
|
||||
double sum = 4;
|
||||
double sum_of_squares = 5;
|
||||
double count = 6;
|
||||
}
|
||||
|
||||
message ClientStats {
|
||||
// Latency histogram. Data points are in nanoseconds.
|
||||
HistogramData latencies = 1;
|
||||
|
||||
// See ServerStats for details.
|
||||
double time_elapsed = 2;
|
||||
double time_user = 3;
|
||||
double time_system = 4;
|
||||
}
|
||||
Loading…
Reference in New Issue