diff --git a/src/csharp/Grpc.IntegrationTesting/Control.cs b/src/csharp/Grpc.IntegrationTesting/Control.cs
index 6c0176fb43f..d62b5a1c5b4 100644
--- a/src/csharp/Grpc.IntegrationTesting/Control.cs
+++ b/src/csharp/Grpc.IntegrationTesting/Control.cs
@@ -32,7 +32,7 @@ namespace Grpc.Testing {
"U2VjdXJpdHlQYXJhbXMSEwoLdXNlX3Rlc3RfY2EYASABKAgSHAoUc2VydmVy",
"X2hvc3Rfb3ZlcnJpZGUYAiABKAkiTQoKQ2hhbm5lbEFyZxIMCgRuYW1lGAEg",
"ASgJEhMKCXN0cl92YWx1ZRgCIAEoCUgAEhMKCWludF92YWx1ZRgDIAEoBUgA",
- "QgcKBXZhbHVlIqAECgxDbGllbnRDb25maWcSFgoOc2VydmVyX3RhcmdldHMY",
+ "QgcKBXZhbHVlItUECgxDbGllbnRDb25maWcSFgoOc2VydmVyX3RhcmdldHMY",
"ASADKAkSLQoLY2xpZW50X3R5cGUYAiABKA4yGC5ncnBjLnRlc3RpbmcuQ2xp",
"ZW50VHlwZRI1Cg9zZWN1cml0eV9wYXJhbXMYAyABKAsyHC5ncnBjLnRlc3Rp",
"bmcuU2VjdXJpdHlQYXJhbXMSJAocb3V0c3RhbmRpbmdfcnBjc19wZXJfY2hh",
@@ -44,52 +44,57 @@ namespace Grpc.Testing {
"cxgMIAEoCzIdLmdycGMudGVzdGluZy5IaXN0b2dyYW1QYXJhbXMSEQoJY29y",
"ZV9saXN0GA0gAygFEhIKCmNvcmVfbGltaXQYDiABKAUSGAoQb3RoZXJfY2xp",
"ZW50X2FwaRgPIAEoCRIuCgxjaGFubmVsX2FyZ3MYECADKAsyGC5ncnBjLnRl",
- "c3RpbmcuQ2hhbm5lbEFyZyI4CgxDbGllbnRTdGF0dXMSKAoFc3RhdHMYASAB",
- "KAsyGS5ncnBjLnRlc3RpbmcuQ2xpZW50U3RhdHMiFQoETWFyaxINCgVyZXNl",
- "dBgBIAEoCCJoCgpDbGllbnRBcmd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l9zdGF0cxgEIAMoCzIZLmdycGMudGVzdGluZy5TZXJ2ZXJT",
+ "dGF0cxIUCgxzZXJ2ZXJfY29yZXMYBSADKAUSNAoHc3VtbWFyeRgGIAEoCzIj",
+ "LmdycGMudGVzdGluZy5TY2VuYXJpb1Jlc3VsdFN1bW1hcnkSFgoOY2xpZW50",
+ "X3N1Y2Nlc3MYByADKAgSFgoOc2VydmVyX3N1Y2Nlc3MYCCADKAgSOQoPcmVx",
+ "dWVzdF9yZXN1bHRzGAkgAygLMiAuZ3JwYy50ZXN0aW5nLlJlcXVlc3RSZXN1",
+ "bHRDb3VudCpBCgpDbGllbnRUeXBlEg8KC1NZTkNfQ0xJRU5UEAASEAoMQVNZ",
+ "TkNfQ0xJRU5UEAESEAoMT1RIRVJfQ0xJRU5UEAIqWwoKU2VydmVyVHlwZRIP",
+ "CgtTWU5DX1NFUlZFUhAAEhAKDEFTWU5DX1NFUlZFUhABEhgKFEFTWU5DX0dF",
+ "TkVSSUNfU0VSVkVSEAISEAoMT1RIRVJfU0VSVkVSEAMqcgoHUnBjVHlwZRIJ",
+ "CgVVTkFSWRAAEg0KCVNUUkVBTUlORxABEhkKFVNUUkVBTUlOR19GUk9NX0NM",
+ "SUVOVBACEhkKFVNUUkVBTUlOR19GUk9NX1NFUlZFUhADEhcKE1NUUkVBTUlO",
+ "R19CT1RIX1dBWVMQBGIGcHJvdG8z"));
descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData,
new pbr::FileDescriptor[] { global::Grpc.Testing.PayloadsReflection.Descriptor, global::Grpc.Testing.StatsReflection.Descriptor, },
new pbr::GeneratedClrTypeInfo(new[] {typeof(global::Grpc.Testing.ClientType), typeof(global::Grpc.Testing.ServerType), typeof(global::Grpc.Testing.RpcType), }, new pbr::GeneratedClrTypeInfo[] {
@@ -98,11 +103,11 @@ namespace Grpc.Testing {
new pbr::GeneratedClrTypeInfo(typeof(global::Grpc.Testing.LoadParams), global::Grpc.Testing.LoadParams.Parser, new[]{ "ClosedLoop", "Poisson" }, new[]{ "Load" }, null, null),
new pbr::GeneratedClrTypeInfo(typeof(global::Grpc.Testing.SecurityParams), global::Grpc.Testing.SecurityParams.Parser, new[]{ "UseTestCa", "ServerHostOverride" }, null, null, null),
new pbr::GeneratedClrTypeInfo(typeof(global::Grpc.Testing.ChannelArg), global::Grpc.Testing.ChannelArg.Parser, new[]{ "Name", "StrValue", "IntValue" }, new[]{ "Value" }, null, null),
- new pbr::GeneratedClrTypeInfo(typeof(global::Grpc.Testing.ClientConfig), global::Grpc.Testing.ClientConfig.Parser, new[]{ "ServerTargets", "ClientType", "SecurityParams", "OutstandingRpcsPerChannel", "ClientChannels", "AsyncClientThreads", "RpcType", "LoadParams", "PayloadConfig", "HistogramParams", "CoreList", "CoreLimit", "OtherClientApi", "ChannelArgs" }, null, null, null),
+ new pbr::GeneratedClrTypeInfo(typeof(global::Grpc.Testing.ClientConfig), global::Grpc.Testing.ClientConfig.Parser, new[]{ "ServerTargets", "ClientType", "SecurityParams", "OutstandingRpcsPerChannel", "ClientChannels", "AsyncClientThreads", "RpcType", "LoadParams", "PayloadConfig", "HistogramParams", "CoreList", "CoreLimit", "OtherClientApi", "ChannelArgs", "ThreadsPerCq", "MessagesPerStream" }, null, null, null),
new pbr::GeneratedClrTypeInfo(typeof(global::Grpc.Testing.ClientStatus), global::Grpc.Testing.ClientStatus.Parser, new[]{ "Stats" }, null, null, null),
new pbr::GeneratedClrTypeInfo(typeof(global::Grpc.Testing.Mark), global::Grpc.Testing.Mark.Parser, new[]{ "Reset" }, null, null, null),
new pbr::GeneratedClrTypeInfo(typeof(global::Grpc.Testing.ClientArgs), global::Grpc.Testing.ClientArgs.Parser, new[]{ "Setup", "Mark" }, new[]{ "Argtype" }, null, null),
- new pbr::GeneratedClrTypeInfo(typeof(global::Grpc.Testing.ServerConfig), global::Grpc.Testing.ServerConfig.Parser, new[]{ "ServerType", "SecurityParams", "Port", "AsyncServerThreads", "CoreLimit", "PayloadConfig", "CoreList", "OtherServerApi", "ResourceQuotaSize" }, null, null, null),
+ new pbr::GeneratedClrTypeInfo(typeof(global::Grpc.Testing.ServerConfig), global::Grpc.Testing.ServerConfig.Parser, new[]{ "ServerType", "SecurityParams", "Port", "AsyncServerThreads", "CoreLimit", "PayloadConfig", "CoreList", "OtherServerApi", "ThreadsPerCq", "ResourceQuotaSize" }, null, null, null),
new pbr::GeneratedClrTypeInfo(typeof(global::Grpc.Testing.ServerArgs), global::Grpc.Testing.ServerArgs.Parser, new[]{ "Setup", "Mark" }, new[]{ "Argtype" }, null, null),
new pbr::GeneratedClrTypeInfo(typeof(global::Grpc.Testing.ServerStatus), global::Grpc.Testing.ServerStatus.Parser, new[]{ "Stats", "Port", "Cores" }, null, null, null),
new pbr::GeneratedClrTypeInfo(typeof(global::Grpc.Testing.CoreRequest), global::Grpc.Testing.CoreRequest.Parser, null, null, null, null),
@@ -110,7 +115,7 @@ namespace Grpc.Testing {
new pbr::GeneratedClrTypeInfo(typeof(global::Grpc.Testing.Void), global::Grpc.Testing.Void.Parser, null, null, null, null),
new pbr::GeneratedClrTypeInfo(typeof(global::Grpc.Testing.Scenario), global::Grpc.Testing.Scenario.Parser, new[]{ "Name", "ClientConfig", "NumClients", "ServerConfig", "NumServers", "WarmupSeconds", "BenchmarkSeconds", "SpawnLocalWorkerCount" }, null, null, null),
new pbr::GeneratedClrTypeInfo(typeof(global::Grpc.Testing.Scenarios), global::Grpc.Testing.Scenarios.Parser, new[]{ "Scenarios_" }, null, null, null),
- new pbr::GeneratedClrTypeInfo(typeof(global::Grpc.Testing.ScenarioResultSummary), global::Grpc.Testing.ScenarioResultSummary.Parser, new[]{ "Qps", "QpsPerServerCore", "ServerSystemTime", "ServerUserTime", "ClientSystemTime", "ClientUserTime", "Latency50", "Latency90", "Latency95", "Latency99", "Latency999", "ServerCpuUsage", "SuccessfulRequestsPerSecond", "FailedRequestsPerSecond" }, null, null, null),
+ new pbr::GeneratedClrTypeInfo(typeof(global::Grpc.Testing.ScenarioResultSummary), global::Grpc.Testing.ScenarioResultSummary.Parser, new[]{ "Qps", "QpsPerServerCore", "ServerSystemTime", "ServerUserTime", "ClientSystemTime", "ClientUserTime", "Latency50", "Latency90", "Latency95", "Latency99", "Latency999", "ServerCpuUsage", "SuccessfulRequestsPerSecond", "FailedRequestsPerSecond", "ClientPollsPerRequest", "ServerPollsPerRequest" }, null, null, null),
new pbr::GeneratedClrTypeInfo(typeof(global::Grpc.Testing.ScenarioResult), global::Grpc.Testing.ScenarioResult.Parser, new[]{ "Scenario", "Latencies", "ClientStats", "ServerStats", "ServerCores", "Summary", "ClientSuccess", "ServerSuccess", "RequestResults" }, null, null, null)
}));
}
@@ -144,6 +149,9 @@ namespace Grpc.Testing {
public enum RpcType {
[pbr::OriginalName("UNARY")] Unary = 0,
[pbr::OriginalName("STREAMING")] Streaming = 1,
+ [pbr::OriginalName("STREAMING_FROM_CLIENT")] StreamingFromClient = 2,
+ [pbr::OriginalName("STREAMING_FROM_SERVER")] StreamingFromServer = 3,
+ [pbr::OriginalName("STREAMING_BOTH_WAYS")] StreamingBothWays = 4,
}
#endregion
@@ -942,6 +950,8 @@ namespace Grpc.Testing {
coreLimit_ = other.coreLimit_;
otherClientApi_ = other.otherClientApi_;
channelArgs_ = other.channelArgs_.Clone();
+ threadsPerCq_ = other.threadsPerCq_;
+ messagesPerStream_ = other.messagesPerStream_;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute]
@@ -1123,6 +1133,34 @@ namespace Grpc.Testing {
get { return channelArgs_; }
}
+ /// Field number for the "threads_per_cq" field.
+ public const int ThreadsPerCqFieldNumber = 17;
+ private int threadsPerCq_;
+ ///
+ /// Number of threads that share each completion queue
+ ///
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public int ThreadsPerCq {
+ get { return threadsPerCq_; }
+ set {
+ threadsPerCq_ = value;
+ }
+ }
+
+ /// Field number for the "messages_per_stream" field.
+ public const int MessagesPerStreamFieldNumber = 18;
+ private int messagesPerStream_;
+ ///
+ /// Number of messages on a stream before it gets finished/restarted
+ ///
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public int MessagesPerStream {
+ get { return messagesPerStream_; }
+ set {
+ messagesPerStream_ = value;
+ }
+ }
+
[global::System.Diagnostics.DebuggerNonUserCodeAttribute]
public override bool Equals(object other) {
return Equals(other as ClientConfig);
@@ -1150,6 +1188,8 @@ namespace Grpc.Testing {
if (CoreLimit != other.CoreLimit) return false;
if (OtherClientApi != other.OtherClientApi) return false;
if(!channelArgs_.Equals(other.channelArgs_)) return false;
+ if (ThreadsPerCq != other.ThreadsPerCq) return false;
+ if (MessagesPerStream != other.MessagesPerStream) return false;
return true;
}
@@ -1170,6 +1210,8 @@ namespace Grpc.Testing {
if (CoreLimit != 0) hash ^= CoreLimit.GetHashCode();
if (OtherClientApi.Length != 0) hash ^= OtherClientApi.GetHashCode();
hash ^= channelArgs_.GetHashCode();
+ if (ThreadsPerCq != 0) hash ^= ThreadsPerCq.GetHashCode();
+ if (MessagesPerStream != 0) hash ^= MessagesPerStream.GetHashCode();
return hash;
}
@@ -1227,6 +1269,14 @@ namespace Grpc.Testing {
output.WriteString(OtherClientApi);
}
channelArgs_.WriteTo(output, _repeated_channelArgs_codec);
+ if (ThreadsPerCq != 0) {
+ output.WriteRawTag(136, 1);
+ output.WriteInt32(ThreadsPerCq);
+ }
+ if (MessagesPerStream != 0) {
+ output.WriteRawTag(144, 1);
+ output.WriteInt32(MessagesPerStream);
+ }
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute]
@@ -1268,6 +1318,12 @@ namespace Grpc.Testing {
size += 1 + pb::CodedOutputStream.ComputeStringSize(OtherClientApi);
}
size += channelArgs_.CalculateSize(_repeated_channelArgs_codec);
+ if (ThreadsPerCq != 0) {
+ size += 2 + pb::CodedOutputStream.ComputeInt32Size(ThreadsPerCq);
+ }
+ if (MessagesPerStream != 0) {
+ size += 2 + pb::CodedOutputStream.ComputeInt32Size(MessagesPerStream);
+ }
return size;
}
@@ -1324,6 +1380,12 @@ namespace Grpc.Testing {
OtherClientApi = other.OtherClientApi;
}
channelArgs_.Add(other.channelArgs_);
+ if (other.ThreadsPerCq != 0) {
+ ThreadsPerCq = other.ThreadsPerCq;
+ }
+ if (other.MessagesPerStream != 0) {
+ MessagesPerStream = other.MessagesPerStream;
+ }
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute]
@@ -1403,6 +1465,14 @@ namespace Grpc.Testing {
channelArgs_.AddEntriesFrom(input, _repeated_channelArgs_codec);
break;
}
+ case 136: {
+ ThreadsPerCq = input.ReadInt32();
+ break;
+ }
+ case 144: {
+ MessagesPerStream = input.ReadInt32();
+ break;
+ }
}
}
}
@@ -1873,6 +1943,7 @@ namespace Grpc.Testing {
PayloadConfig = other.payloadConfig_ != null ? other.PayloadConfig.Clone() : null;
coreList_ = other.coreList_.Clone();
otherServerApi_ = other.otherServerApi_;
+ threadsPerCq_ = other.threadsPerCq_;
resourceQuotaSize_ = other.resourceQuotaSize_;
}
@@ -1989,6 +2060,20 @@ namespace Grpc.Testing {
}
}
+ /// Field number for the "threads_per_cq" field.
+ public const int ThreadsPerCqFieldNumber = 12;
+ private int threadsPerCq_;
+ ///
+ /// Number of threads that share each completion queue
+ ///
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public int ThreadsPerCq {
+ get { return threadsPerCq_; }
+ set {
+ threadsPerCq_ = value;
+ }
+ }
+
/// Field number for the "resource_quota_size" field.
public const int ResourceQuotaSizeFieldNumber = 1001;
private int resourceQuotaSize_;
@@ -2024,6 +2109,7 @@ namespace Grpc.Testing {
if (!object.Equals(PayloadConfig, other.PayloadConfig)) return false;
if(!coreList_.Equals(other.coreList_)) return false;
if (OtherServerApi != other.OtherServerApi) return false;
+ if (ThreadsPerCq != other.ThreadsPerCq) return false;
if (ResourceQuotaSize != other.ResourceQuotaSize) return false;
return true;
}
@@ -2039,6 +2125,7 @@ namespace Grpc.Testing {
if (payloadConfig_ != null) hash ^= PayloadConfig.GetHashCode();
hash ^= coreList_.GetHashCode();
if (OtherServerApi.Length != 0) hash ^= OtherServerApi.GetHashCode();
+ if (ThreadsPerCq != 0) hash ^= ThreadsPerCq.GetHashCode();
if (ResourceQuotaSize != 0) hash ^= ResourceQuotaSize.GetHashCode();
return hash;
}
@@ -2079,6 +2166,10 @@ namespace Grpc.Testing {
output.WriteRawTag(90);
output.WriteString(OtherServerApi);
}
+ if (ThreadsPerCq != 0) {
+ output.WriteRawTag(96);
+ output.WriteInt32(ThreadsPerCq);
+ }
if (ResourceQuotaSize != 0) {
output.WriteRawTag(200, 62);
output.WriteInt32(ResourceQuotaSize);
@@ -2110,6 +2201,9 @@ namespace Grpc.Testing {
if (OtherServerApi.Length != 0) {
size += 1 + pb::CodedOutputStream.ComputeStringSize(OtherServerApi);
}
+ if (ThreadsPerCq != 0) {
+ size += 1 + pb::CodedOutputStream.ComputeInt32Size(ThreadsPerCq);
+ }
if (ResourceQuotaSize != 0) {
size += 2 + pb::CodedOutputStream.ComputeInt32Size(ResourceQuotaSize);
}
@@ -2149,6 +2243,9 @@ namespace Grpc.Testing {
if (other.OtherServerApi.Length != 0) {
OtherServerApi = other.OtherServerApi;
}
+ if (other.ThreadsPerCq != 0) {
+ ThreadsPerCq = other.ThreadsPerCq;
+ }
if (other.ResourceQuotaSize != 0) {
ResourceQuotaSize = other.ResourceQuotaSize;
}
@@ -2201,6 +2298,10 @@ namespace Grpc.Testing {
OtherServerApi = input.ReadString();
break;
}
+ case 96: {
+ ThreadsPerCq = input.ReadInt32();
+ break;
+ }
case 8008: {
ResourceQuotaSize = input.ReadInt32();
break;
@@ -3386,6 +3487,8 @@ namespace Grpc.Testing {
serverCpuUsage_ = other.serverCpuUsage_;
successfulRequestsPerSecond_ = other.successfulRequestsPerSecond_;
failedRequestsPerSecond_ = other.failedRequestsPerSecond_;
+ clientPollsPerRequest_ = other.clientPollsPerRequest_;
+ serverPollsPerRequest_ = other.serverPollsPerRequest_;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute]
@@ -3574,6 +3677,31 @@ namespace Grpc.Testing {
}
}
+ /// Field number for the "client_polls_per_request" field.
+ public const int ClientPollsPerRequestFieldNumber = 15;
+ private double clientPollsPerRequest_;
+ ///
+ /// Number of polls called inside completion queue per request
+ ///
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public double ClientPollsPerRequest {
+ get { return clientPollsPerRequest_; }
+ set {
+ clientPollsPerRequest_ = value;
+ }
+ }
+
+ /// Field number for the "server_polls_per_request" field.
+ public const int ServerPollsPerRequestFieldNumber = 16;
+ private double serverPollsPerRequest_;
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public double ServerPollsPerRequest {
+ get { return serverPollsPerRequest_; }
+ set {
+ serverPollsPerRequest_ = value;
+ }
+ }
+
[global::System.Diagnostics.DebuggerNonUserCodeAttribute]
public override bool Equals(object other) {
return Equals(other as ScenarioResultSummary);
@@ -3601,6 +3729,8 @@ namespace Grpc.Testing {
if (ServerCpuUsage != other.ServerCpuUsage) return false;
if (SuccessfulRequestsPerSecond != other.SuccessfulRequestsPerSecond) return false;
if (FailedRequestsPerSecond != other.FailedRequestsPerSecond) return false;
+ if (ClientPollsPerRequest != other.ClientPollsPerRequest) return false;
+ if (ServerPollsPerRequest != other.ServerPollsPerRequest) return false;
return true;
}
@@ -3621,6 +3751,8 @@ namespace Grpc.Testing {
if (ServerCpuUsage != 0D) hash ^= ServerCpuUsage.GetHashCode();
if (SuccessfulRequestsPerSecond != 0D) hash ^= SuccessfulRequestsPerSecond.GetHashCode();
if (FailedRequestsPerSecond != 0D) hash ^= FailedRequestsPerSecond.GetHashCode();
+ if (ClientPollsPerRequest != 0D) hash ^= ClientPollsPerRequest.GetHashCode();
+ if (ServerPollsPerRequest != 0D) hash ^= ServerPollsPerRequest.GetHashCode();
return hash;
}
@@ -3687,6 +3819,14 @@ namespace Grpc.Testing {
output.WriteRawTag(113);
output.WriteDouble(FailedRequestsPerSecond);
}
+ if (ClientPollsPerRequest != 0D) {
+ output.WriteRawTag(121);
+ output.WriteDouble(ClientPollsPerRequest);
+ }
+ if (ServerPollsPerRequest != 0D) {
+ output.WriteRawTag(129, 1);
+ output.WriteDouble(ServerPollsPerRequest);
+ }
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute]
@@ -3734,6 +3874,12 @@ namespace Grpc.Testing {
if (FailedRequestsPerSecond != 0D) {
size += 1 + 8;
}
+ if (ClientPollsPerRequest != 0D) {
+ size += 1 + 8;
+ }
+ if (ServerPollsPerRequest != 0D) {
+ size += 2 + 8;
+ }
return size;
}
@@ -3784,6 +3930,12 @@ namespace Grpc.Testing {
if (other.FailedRequestsPerSecond != 0D) {
FailedRequestsPerSecond = other.FailedRequestsPerSecond;
}
+ if (other.ClientPollsPerRequest != 0D) {
+ ClientPollsPerRequest = other.ClientPollsPerRequest;
+ }
+ if (other.ServerPollsPerRequest != 0D) {
+ ServerPollsPerRequest = other.ServerPollsPerRequest;
+ }
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute]
@@ -3850,6 +4002,14 @@ namespace Grpc.Testing {
FailedRequestsPerSecond = input.ReadDouble();
break;
}
+ case 121: {
+ ClientPollsPerRequest = input.ReadDouble();
+ break;
+ }
+ case 129: {
+ ServerPollsPerRequest = input.ReadDouble();
+ break;
+ }
}
}
}
diff --git a/src/csharp/Grpc.IntegrationTesting/EchoMessages.cs b/src/csharp/Grpc.IntegrationTesting/EchoMessages.cs
new file mode 100644
index 00000000000..b2fe73acdf4
--- /dev/null
+++ b/src/csharp/Grpc.IntegrationTesting/EchoMessages.cs
@@ -0,0 +1,1354 @@
+// Generated by the protocol buffer compiler. DO NOT EDIT!
+// source: src/proto/grpc/testing/echo_messages.proto
+#pragma warning disable 1591, 0612, 3021
+#region Designer generated code
+
+using pb = global::Google.Protobuf;
+using pbc = global::Google.Protobuf.Collections;
+using pbr = global::Google.Protobuf.Reflection;
+using scg = global::System.Collections.Generic;
+namespace Grpc.Testing {
+
+ /// Holder for reflection information generated from src/proto/grpc/testing/echo_messages.proto
+ public static partial class EchoMessagesReflection {
+
+ #region Descriptor
+ /// File descriptor for src/proto/grpc/testing/echo_messages.proto
+ public static pbr::FileDescriptor Descriptor {
+ get { return descriptor; }
+ }
+ private static pbr::FileDescriptor descriptor;
+
+ static EchoMessagesReflection() {
+ byte[] descriptorData = global::System.Convert.FromBase64String(
+ string.Concat(
+ "CipzcmMvcHJvdG8vZ3JwYy90ZXN0aW5nL2VjaG9fbWVzc2FnZXMucHJvdG8S",
+ "DGdycGMudGVzdGluZyIyCglEZWJ1Z0luZm8SFQoNc3RhY2tfZW50cmllcxgB",
+ "IAMoCRIOCgZkZXRhaWwYAiABKAkiUAoLRXJyb3JTdGF0dXMSDAoEY29kZRgB",
+ "IAEoBRIVCg1lcnJvcl9tZXNzYWdlGAIgASgJEhwKFGJpbmFyeV9lcnJvcl9k",
+ "ZXRhaWxzGAMgASgJIskDCg1SZXF1ZXN0UGFyYW1zEhUKDWVjaG9fZGVhZGxp",
+ "bmUYASABKAgSHgoWY2xpZW50X2NhbmNlbF9hZnRlcl91cxgCIAEoBRIeChZz",
+ "ZXJ2ZXJfY2FuY2VsX2FmdGVyX3VzGAMgASgFEhUKDWVjaG9fbWV0YWRhdGEY",
+ "BCABKAgSGgoSY2hlY2tfYXV0aF9jb250ZXh0GAUgASgIEh8KF3Jlc3BvbnNl",
+ "X21lc3NhZ2VfbGVuZ3RoGAYgASgFEhEKCWVjaG9fcGVlchgHIAEoCBIgChhl",
+ "eHBlY3RlZF9jbGllbnRfaWRlbnRpdHkYCCABKAkSHAoUc2tpcF9jYW5jZWxs",
+ "ZWRfY2hlY2sYCSABKAgSKAogZXhwZWN0ZWRfdHJhbnNwb3J0X3NlY3VyaXR5",
+ "X3R5cGUYCiABKAkSKwoKZGVidWdfaW5mbxgLIAEoCzIXLmdycGMudGVzdGlu",
+ "Zy5EZWJ1Z0luZm8SEgoKc2VydmVyX2RpZRgMIAEoCBIcChRiaW5hcnlfZXJy",
+ "b3JfZGV0YWlscxgNIAEoCRIxCg5leHBlY3RlZF9lcnJvchgOIAEoCzIZLmdy",
+ "cGMudGVzdGluZy5FcnJvclN0YXR1cyJKCgtFY2hvUmVxdWVzdBIPCgdtZXNz",
+ "YWdlGAEgASgJEioKBXBhcmFtGAIgASgLMhsuZ3JwYy50ZXN0aW5nLlJlcXVl",
+ "c3RQYXJhbXMiRgoOUmVzcG9uc2VQYXJhbXMSGAoQcmVxdWVzdF9kZWFkbGlu",
+ "ZRgBIAEoAxIMCgRob3N0GAIgASgJEgwKBHBlZXIYAyABKAkiTAoMRWNob1Jl",
+ "c3BvbnNlEg8KB21lc3NhZ2UYASABKAkSKwoFcGFyYW0YAiABKAsyHC5ncnBj",
+ "LnRlc3RpbmcuUmVzcG9uc2VQYXJhbXNiBnByb3RvMw=="));
+ descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData,
+ new pbr::FileDescriptor[] { },
+ new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] {
+ new pbr::GeneratedClrTypeInfo(typeof(global::Grpc.Testing.DebugInfo), global::Grpc.Testing.DebugInfo.Parser, new[]{ "StackEntries", "Detail" }, null, null, null),
+ new pbr::GeneratedClrTypeInfo(typeof(global::Grpc.Testing.ErrorStatus), global::Grpc.Testing.ErrorStatus.Parser, new[]{ "Code", "ErrorMessage", "BinaryErrorDetails" }, null, null, null),
+ new pbr::GeneratedClrTypeInfo(typeof(global::Grpc.Testing.RequestParams), global::Grpc.Testing.RequestParams.Parser, new[]{ "EchoDeadline", "ClientCancelAfterUs", "ServerCancelAfterUs", "EchoMetadata", "CheckAuthContext", "ResponseMessageLength", "EchoPeer", "ExpectedClientIdentity", "SkipCancelledCheck", "ExpectedTransportSecurityType", "DebugInfo", "ServerDie", "BinaryErrorDetails", "ExpectedError" }, null, null, null),
+ new pbr::GeneratedClrTypeInfo(typeof(global::Grpc.Testing.EchoRequest), global::Grpc.Testing.EchoRequest.Parser, new[]{ "Message", "Param" }, null, null, null),
+ new pbr::GeneratedClrTypeInfo(typeof(global::Grpc.Testing.ResponseParams), global::Grpc.Testing.ResponseParams.Parser, new[]{ "RequestDeadline", "Host", "Peer" }, null, null, null),
+ new pbr::GeneratedClrTypeInfo(typeof(global::Grpc.Testing.EchoResponse), global::Grpc.Testing.EchoResponse.Parser, new[]{ "Message", "Param" }, null, null, null)
+ }));
+ }
+ #endregion
+
+ }
+ #region Messages
+ ///
+ /// Message to be echoed back serialized in trailer.
+ ///
+ public sealed partial class DebugInfo : pb::IMessage {
+ private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new DebugInfo());
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public static pb::MessageParser Parser { get { return _parser; } }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public static pbr::MessageDescriptor Descriptor {
+ get { return global::Grpc.Testing.EchoMessagesReflection.Descriptor.MessageTypes[0]; }
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ pbr::MessageDescriptor pb::IMessage.Descriptor {
+ get { return Descriptor; }
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public DebugInfo() {
+ OnConstruction();
+ }
+
+ partial void OnConstruction();
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public DebugInfo(DebugInfo other) : this() {
+ stackEntries_ = other.stackEntries_.Clone();
+ detail_ = other.detail_;
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public DebugInfo Clone() {
+ return new DebugInfo(this);
+ }
+
+ /// Field number for the "stack_entries" field.
+ public const int StackEntriesFieldNumber = 1;
+ private static readonly pb::FieldCodec _repeated_stackEntries_codec
+ = pb::FieldCodec.ForString(10);
+ private readonly pbc::RepeatedField stackEntries_ = new pbc::RepeatedField();
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public pbc::RepeatedField StackEntries {
+ get { return stackEntries_; }
+ }
+
+ /// Field number for the "detail" field.
+ public const int DetailFieldNumber = 2;
+ private string detail_ = "";
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public string Detail {
+ get { return detail_; }
+ set {
+ detail_ = pb::ProtoPreconditions.CheckNotNull(value, "value");
+ }
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public override bool Equals(object other) {
+ return Equals(other as DebugInfo);
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public bool Equals(DebugInfo other) {
+ if (ReferenceEquals(other, null)) {
+ return false;
+ }
+ if (ReferenceEquals(other, this)) {
+ return true;
+ }
+ if(!stackEntries_.Equals(other.stackEntries_)) return false;
+ if (Detail != other.Detail) return false;
+ return true;
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public override int GetHashCode() {
+ int hash = 1;
+ hash ^= stackEntries_.GetHashCode();
+ if (Detail.Length != 0) hash ^= Detail.GetHashCode();
+ return hash;
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public override string ToString() {
+ return pb::JsonFormatter.ToDiagnosticString(this);
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public void WriteTo(pb::CodedOutputStream output) {
+ stackEntries_.WriteTo(output, _repeated_stackEntries_codec);
+ if (Detail.Length != 0) {
+ output.WriteRawTag(18);
+ output.WriteString(Detail);
+ }
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public int CalculateSize() {
+ int size = 0;
+ size += stackEntries_.CalculateSize(_repeated_stackEntries_codec);
+ if (Detail.Length != 0) {
+ size += 1 + pb::CodedOutputStream.ComputeStringSize(Detail);
+ }
+ return size;
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public void MergeFrom(DebugInfo other) {
+ if (other == null) {
+ return;
+ }
+ stackEntries_.Add(other.stackEntries_);
+ if (other.Detail.Length != 0) {
+ Detail = other.Detail;
+ }
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public void MergeFrom(pb::CodedInputStream input) {
+ uint tag;
+ while ((tag = input.ReadTag()) != 0) {
+ switch(tag) {
+ default:
+ input.SkipLastField();
+ break;
+ case 10: {
+ stackEntries_.AddEntriesFrom(input, _repeated_stackEntries_codec);
+ break;
+ }
+ case 18: {
+ Detail = input.ReadString();
+ break;
+ }
+ }
+ }
+ }
+
+ }
+
+ ///
+ /// Error status client expects to see.
+ ///
+ public sealed partial class ErrorStatus : pb::IMessage {
+ private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ErrorStatus());
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public static pb::MessageParser Parser { get { return _parser; } }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public static pbr::MessageDescriptor Descriptor {
+ get { return global::Grpc.Testing.EchoMessagesReflection.Descriptor.MessageTypes[1]; }
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ pbr::MessageDescriptor pb::IMessage.Descriptor {
+ get { return Descriptor; }
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public ErrorStatus() {
+ OnConstruction();
+ }
+
+ partial void OnConstruction();
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public ErrorStatus(ErrorStatus other) : this() {
+ code_ = other.code_;
+ errorMessage_ = other.errorMessage_;
+ binaryErrorDetails_ = other.binaryErrorDetails_;
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public ErrorStatus Clone() {
+ return new ErrorStatus(this);
+ }
+
+ /// Field number for the "code" field.
+ public const int CodeFieldNumber = 1;
+ private int code_;
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public int Code {
+ get { return code_; }
+ set {
+ code_ = value;
+ }
+ }
+
+ /// Field number for the "error_message" field.
+ public const int ErrorMessageFieldNumber = 2;
+ private string errorMessage_ = "";
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public string ErrorMessage {
+ get { return errorMessage_; }
+ set {
+ errorMessage_ = pb::ProtoPreconditions.CheckNotNull(value, "value");
+ }
+ }
+
+ /// Field number for the "binary_error_details" field.
+ public const int BinaryErrorDetailsFieldNumber = 3;
+ private string binaryErrorDetails_ = "";
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public string BinaryErrorDetails {
+ get { return binaryErrorDetails_; }
+ set {
+ binaryErrorDetails_ = pb::ProtoPreconditions.CheckNotNull(value, "value");
+ }
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public override bool Equals(object other) {
+ return Equals(other as ErrorStatus);
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public bool Equals(ErrorStatus other) {
+ if (ReferenceEquals(other, null)) {
+ return false;
+ }
+ if (ReferenceEquals(other, this)) {
+ return true;
+ }
+ if (Code != other.Code) return false;
+ if (ErrorMessage != other.ErrorMessage) return false;
+ if (BinaryErrorDetails != other.BinaryErrorDetails) return false;
+ return true;
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public override int GetHashCode() {
+ int hash = 1;
+ if (Code != 0) hash ^= Code.GetHashCode();
+ if (ErrorMessage.Length != 0) hash ^= ErrorMessage.GetHashCode();
+ if (BinaryErrorDetails.Length != 0) hash ^= BinaryErrorDetails.GetHashCode();
+ return hash;
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public override string ToString() {
+ return pb::JsonFormatter.ToDiagnosticString(this);
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public void WriteTo(pb::CodedOutputStream output) {
+ if (Code != 0) {
+ output.WriteRawTag(8);
+ output.WriteInt32(Code);
+ }
+ if (ErrorMessage.Length != 0) {
+ output.WriteRawTag(18);
+ output.WriteString(ErrorMessage);
+ }
+ if (BinaryErrorDetails.Length != 0) {
+ output.WriteRawTag(26);
+ output.WriteString(BinaryErrorDetails);
+ }
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public int CalculateSize() {
+ int size = 0;
+ if (Code != 0) {
+ size += 1 + pb::CodedOutputStream.ComputeInt32Size(Code);
+ }
+ if (ErrorMessage.Length != 0) {
+ size += 1 + pb::CodedOutputStream.ComputeStringSize(ErrorMessage);
+ }
+ if (BinaryErrorDetails.Length != 0) {
+ size += 1 + pb::CodedOutputStream.ComputeStringSize(BinaryErrorDetails);
+ }
+ return size;
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public void MergeFrom(ErrorStatus other) {
+ if (other == null) {
+ return;
+ }
+ if (other.Code != 0) {
+ Code = other.Code;
+ }
+ if (other.ErrorMessage.Length != 0) {
+ ErrorMessage = other.ErrorMessage;
+ }
+ if (other.BinaryErrorDetails.Length != 0) {
+ BinaryErrorDetails = other.BinaryErrorDetails;
+ }
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public void MergeFrom(pb::CodedInputStream input) {
+ uint tag;
+ while ((tag = input.ReadTag()) != 0) {
+ switch(tag) {
+ default:
+ input.SkipLastField();
+ break;
+ case 8: {
+ Code = input.ReadInt32();
+ break;
+ }
+ case 18: {
+ ErrorMessage = input.ReadString();
+ break;
+ }
+ case 26: {
+ BinaryErrorDetails = input.ReadString();
+ break;
+ }
+ }
+ }
+ }
+
+ }
+
+ public sealed partial class RequestParams : pb::IMessage {
+ private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new RequestParams());
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public static pb::MessageParser Parser { get { return _parser; } }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public static pbr::MessageDescriptor Descriptor {
+ get { return global::Grpc.Testing.EchoMessagesReflection.Descriptor.MessageTypes[2]; }
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ pbr::MessageDescriptor pb::IMessage.Descriptor {
+ get { return Descriptor; }
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public RequestParams() {
+ OnConstruction();
+ }
+
+ partial void OnConstruction();
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public RequestParams(RequestParams other) : this() {
+ echoDeadline_ = other.echoDeadline_;
+ clientCancelAfterUs_ = other.clientCancelAfterUs_;
+ serverCancelAfterUs_ = other.serverCancelAfterUs_;
+ echoMetadata_ = other.echoMetadata_;
+ checkAuthContext_ = other.checkAuthContext_;
+ responseMessageLength_ = other.responseMessageLength_;
+ echoPeer_ = other.echoPeer_;
+ expectedClientIdentity_ = other.expectedClientIdentity_;
+ skipCancelledCheck_ = other.skipCancelledCheck_;
+ expectedTransportSecurityType_ = other.expectedTransportSecurityType_;
+ DebugInfo = other.debugInfo_ != null ? other.DebugInfo.Clone() : null;
+ serverDie_ = other.serverDie_;
+ binaryErrorDetails_ = other.binaryErrorDetails_;
+ ExpectedError = other.expectedError_ != null ? other.ExpectedError.Clone() : null;
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public RequestParams Clone() {
+ return new RequestParams(this);
+ }
+
+ /// Field number for the "echo_deadline" field.
+ public const int EchoDeadlineFieldNumber = 1;
+ private bool echoDeadline_;
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public bool EchoDeadline {
+ get { return echoDeadline_; }
+ set {
+ echoDeadline_ = value;
+ }
+ }
+
+ /// Field number for the "client_cancel_after_us" field.
+ public const int ClientCancelAfterUsFieldNumber = 2;
+ private int clientCancelAfterUs_;
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public int ClientCancelAfterUs {
+ get { return clientCancelAfterUs_; }
+ set {
+ clientCancelAfterUs_ = value;
+ }
+ }
+
+ /// Field number for the "server_cancel_after_us" field.
+ public const int ServerCancelAfterUsFieldNumber = 3;
+ private int serverCancelAfterUs_;
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public int ServerCancelAfterUs {
+ get { return serverCancelAfterUs_; }
+ set {
+ serverCancelAfterUs_ = value;
+ }
+ }
+
+ /// Field number for the "echo_metadata" field.
+ public const int EchoMetadataFieldNumber = 4;
+ private bool echoMetadata_;
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public bool EchoMetadata {
+ get { return echoMetadata_; }
+ set {
+ echoMetadata_ = value;
+ }
+ }
+
+ /// Field number for the "check_auth_context" field.
+ public const int CheckAuthContextFieldNumber = 5;
+ private bool checkAuthContext_;
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public bool CheckAuthContext {
+ get { return checkAuthContext_; }
+ set {
+ checkAuthContext_ = value;
+ }
+ }
+
+ /// Field number for the "response_message_length" field.
+ public const int ResponseMessageLengthFieldNumber = 6;
+ private int responseMessageLength_;
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public int ResponseMessageLength {
+ get { return responseMessageLength_; }
+ set {
+ responseMessageLength_ = value;
+ }
+ }
+
+ /// Field number for the "echo_peer" field.
+ public const int EchoPeerFieldNumber = 7;
+ private bool echoPeer_;
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public bool EchoPeer {
+ get { return echoPeer_; }
+ set {
+ echoPeer_ = value;
+ }
+ }
+
+ /// Field number for the "expected_client_identity" field.
+ public const int ExpectedClientIdentityFieldNumber = 8;
+ private string expectedClientIdentity_ = "";
+ ///
+ /// will force check_auth_context.
+ ///
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public string ExpectedClientIdentity {
+ get { return expectedClientIdentity_; }
+ set {
+ expectedClientIdentity_ = pb::ProtoPreconditions.CheckNotNull(value, "value");
+ }
+ }
+
+ /// Field number for the "skip_cancelled_check" field.
+ public const int SkipCancelledCheckFieldNumber = 9;
+ private bool skipCancelledCheck_;
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public bool SkipCancelledCheck {
+ get { return skipCancelledCheck_; }
+ set {
+ skipCancelledCheck_ = value;
+ }
+ }
+
+ /// Field number for the "expected_transport_security_type" field.
+ public const int ExpectedTransportSecurityTypeFieldNumber = 10;
+ private string expectedTransportSecurityType_ = "";
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public string ExpectedTransportSecurityType {
+ get { return expectedTransportSecurityType_; }
+ set {
+ expectedTransportSecurityType_ = pb::ProtoPreconditions.CheckNotNull(value, "value");
+ }
+ }
+
+ /// Field number for the "debug_info" field.
+ public const int DebugInfoFieldNumber = 11;
+ private global::Grpc.Testing.DebugInfo debugInfo_;
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public global::Grpc.Testing.DebugInfo DebugInfo {
+ get { return debugInfo_; }
+ set {
+ debugInfo_ = value;
+ }
+ }
+
+ /// Field number for the "server_die" field.
+ public const int ServerDieFieldNumber = 12;
+ private bool serverDie_;
+ ///
+ /// Server should not see a request with this set.
+ ///
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public bool ServerDie {
+ get { return serverDie_; }
+ set {
+ serverDie_ = value;
+ }
+ }
+
+ /// Field number for the "binary_error_details" field.
+ public const int BinaryErrorDetailsFieldNumber = 13;
+ private string binaryErrorDetails_ = "";
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public string BinaryErrorDetails {
+ get { return binaryErrorDetails_; }
+ set {
+ binaryErrorDetails_ = pb::ProtoPreconditions.CheckNotNull(value, "value");
+ }
+ }
+
+ /// Field number for the "expected_error" field.
+ public const int ExpectedErrorFieldNumber = 14;
+ private global::Grpc.Testing.ErrorStatus expectedError_;
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public global::Grpc.Testing.ErrorStatus ExpectedError {
+ get { return expectedError_; }
+ set {
+ expectedError_ = value;
+ }
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public override bool Equals(object other) {
+ return Equals(other as RequestParams);
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public bool Equals(RequestParams other) {
+ if (ReferenceEquals(other, null)) {
+ return false;
+ }
+ if (ReferenceEquals(other, this)) {
+ return true;
+ }
+ if (EchoDeadline != other.EchoDeadline) return false;
+ if (ClientCancelAfterUs != other.ClientCancelAfterUs) return false;
+ if (ServerCancelAfterUs != other.ServerCancelAfterUs) return false;
+ if (EchoMetadata != other.EchoMetadata) return false;
+ if (CheckAuthContext != other.CheckAuthContext) return false;
+ if (ResponseMessageLength != other.ResponseMessageLength) return false;
+ if (EchoPeer != other.EchoPeer) return false;
+ if (ExpectedClientIdentity != other.ExpectedClientIdentity) return false;
+ if (SkipCancelledCheck != other.SkipCancelledCheck) return false;
+ if (ExpectedTransportSecurityType != other.ExpectedTransportSecurityType) return false;
+ if (!object.Equals(DebugInfo, other.DebugInfo)) return false;
+ if (ServerDie != other.ServerDie) return false;
+ if (BinaryErrorDetails != other.BinaryErrorDetails) return false;
+ if (!object.Equals(ExpectedError, other.ExpectedError)) return false;
+ return true;
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public override int GetHashCode() {
+ int hash = 1;
+ if (EchoDeadline != false) hash ^= EchoDeadline.GetHashCode();
+ if (ClientCancelAfterUs != 0) hash ^= ClientCancelAfterUs.GetHashCode();
+ if (ServerCancelAfterUs != 0) hash ^= ServerCancelAfterUs.GetHashCode();
+ if (EchoMetadata != false) hash ^= EchoMetadata.GetHashCode();
+ if (CheckAuthContext != false) hash ^= CheckAuthContext.GetHashCode();
+ if (ResponseMessageLength != 0) hash ^= ResponseMessageLength.GetHashCode();
+ if (EchoPeer != false) hash ^= EchoPeer.GetHashCode();
+ if (ExpectedClientIdentity.Length != 0) hash ^= ExpectedClientIdentity.GetHashCode();
+ if (SkipCancelledCheck != false) hash ^= SkipCancelledCheck.GetHashCode();
+ if (ExpectedTransportSecurityType.Length != 0) hash ^= ExpectedTransportSecurityType.GetHashCode();
+ if (debugInfo_ != null) hash ^= DebugInfo.GetHashCode();
+ if (ServerDie != false) hash ^= ServerDie.GetHashCode();
+ if (BinaryErrorDetails.Length != 0) hash ^= BinaryErrorDetails.GetHashCode();
+ if (expectedError_ != null) hash ^= ExpectedError.GetHashCode();
+ return hash;
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public override string ToString() {
+ return pb::JsonFormatter.ToDiagnosticString(this);
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public void WriteTo(pb::CodedOutputStream output) {
+ if (EchoDeadline != false) {
+ output.WriteRawTag(8);
+ output.WriteBool(EchoDeadline);
+ }
+ if (ClientCancelAfterUs != 0) {
+ output.WriteRawTag(16);
+ output.WriteInt32(ClientCancelAfterUs);
+ }
+ if (ServerCancelAfterUs != 0) {
+ output.WriteRawTag(24);
+ output.WriteInt32(ServerCancelAfterUs);
+ }
+ if (EchoMetadata != false) {
+ output.WriteRawTag(32);
+ output.WriteBool(EchoMetadata);
+ }
+ if (CheckAuthContext != false) {
+ output.WriteRawTag(40);
+ output.WriteBool(CheckAuthContext);
+ }
+ if (ResponseMessageLength != 0) {
+ output.WriteRawTag(48);
+ output.WriteInt32(ResponseMessageLength);
+ }
+ if (EchoPeer != false) {
+ output.WriteRawTag(56);
+ output.WriteBool(EchoPeer);
+ }
+ if (ExpectedClientIdentity.Length != 0) {
+ output.WriteRawTag(66);
+ output.WriteString(ExpectedClientIdentity);
+ }
+ if (SkipCancelledCheck != false) {
+ output.WriteRawTag(72);
+ output.WriteBool(SkipCancelledCheck);
+ }
+ if (ExpectedTransportSecurityType.Length != 0) {
+ output.WriteRawTag(82);
+ output.WriteString(ExpectedTransportSecurityType);
+ }
+ if (debugInfo_ != null) {
+ output.WriteRawTag(90);
+ output.WriteMessage(DebugInfo);
+ }
+ if (ServerDie != false) {
+ output.WriteRawTag(96);
+ output.WriteBool(ServerDie);
+ }
+ if (BinaryErrorDetails.Length != 0) {
+ output.WriteRawTag(106);
+ output.WriteString(BinaryErrorDetails);
+ }
+ if (expectedError_ != null) {
+ output.WriteRawTag(114);
+ output.WriteMessage(ExpectedError);
+ }
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public int CalculateSize() {
+ int size = 0;
+ if (EchoDeadline != false) {
+ size += 1 + 1;
+ }
+ if (ClientCancelAfterUs != 0) {
+ size += 1 + pb::CodedOutputStream.ComputeInt32Size(ClientCancelAfterUs);
+ }
+ if (ServerCancelAfterUs != 0) {
+ size += 1 + pb::CodedOutputStream.ComputeInt32Size(ServerCancelAfterUs);
+ }
+ if (EchoMetadata != false) {
+ size += 1 + 1;
+ }
+ if (CheckAuthContext != false) {
+ size += 1 + 1;
+ }
+ if (ResponseMessageLength != 0) {
+ size += 1 + pb::CodedOutputStream.ComputeInt32Size(ResponseMessageLength);
+ }
+ if (EchoPeer != false) {
+ size += 1 + 1;
+ }
+ if (ExpectedClientIdentity.Length != 0) {
+ size += 1 + pb::CodedOutputStream.ComputeStringSize(ExpectedClientIdentity);
+ }
+ if (SkipCancelledCheck != false) {
+ size += 1 + 1;
+ }
+ if (ExpectedTransportSecurityType.Length != 0) {
+ size += 1 + pb::CodedOutputStream.ComputeStringSize(ExpectedTransportSecurityType);
+ }
+ if (debugInfo_ != null) {
+ size += 1 + pb::CodedOutputStream.ComputeMessageSize(DebugInfo);
+ }
+ if (ServerDie != false) {
+ size += 1 + 1;
+ }
+ if (BinaryErrorDetails.Length != 0) {
+ size += 1 + pb::CodedOutputStream.ComputeStringSize(BinaryErrorDetails);
+ }
+ if (expectedError_ != null) {
+ size += 1 + pb::CodedOutputStream.ComputeMessageSize(ExpectedError);
+ }
+ return size;
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public void MergeFrom(RequestParams other) {
+ if (other == null) {
+ return;
+ }
+ if (other.EchoDeadline != false) {
+ EchoDeadline = other.EchoDeadline;
+ }
+ if (other.ClientCancelAfterUs != 0) {
+ ClientCancelAfterUs = other.ClientCancelAfterUs;
+ }
+ if (other.ServerCancelAfterUs != 0) {
+ ServerCancelAfterUs = other.ServerCancelAfterUs;
+ }
+ if (other.EchoMetadata != false) {
+ EchoMetadata = other.EchoMetadata;
+ }
+ if (other.CheckAuthContext != false) {
+ CheckAuthContext = other.CheckAuthContext;
+ }
+ if (other.ResponseMessageLength != 0) {
+ ResponseMessageLength = other.ResponseMessageLength;
+ }
+ if (other.EchoPeer != false) {
+ EchoPeer = other.EchoPeer;
+ }
+ if (other.ExpectedClientIdentity.Length != 0) {
+ ExpectedClientIdentity = other.ExpectedClientIdentity;
+ }
+ if (other.SkipCancelledCheck != false) {
+ SkipCancelledCheck = other.SkipCancelledCheck;
+ }
+ if (other.ExpectedTransportSecurityType.Length != 0) {
+ ExpectedTransportSecurityType = other.ExpectedTransportSecurityType;
+ }
+ if (other.debugInfo_ != null) {
+ if (debugInfo_ == null) {
+ debugInfo_ = new global::Grpc.Testing.DebugInfo();
+ }
+ DebugInfo.MergeFrom(other.DebugInfo);
+ }
+ if (other.ServerDie != false) {
+ ServerDie = other.ServerDie;
+ }
+ if (other.BinaryErrorDetails.Length != 0) {
+ BinaryErrorDetails = other.BinaryErrorDetails;
+ }
+ if (other.expectedError_ != null) {
+ if (expectedError_ == null) {
+ expectedError_ = new global::Grpc.Testing.ErrorStatus();
+ }
+ ExpectedError.MergeFrom(other.ExpectedError);
+ }
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public void MergeFrom(pb::CodedInputStream input) {
+ uint tag;
+ while ((tag = input.ReadTag()) != 0) {
+ switch(tag) {
+ default:
+ input.SkipLastField();
+ break;
+ case 8: {
+ EchoDeadline = input.ReadBool();
+ break;
+ }
+ case 16: {
+ ClientCancelAfterUs = input.ReadInt32();
+ break;
+ }
+ case 24: {
+ ServerCancelAfterUs = input.ReadInt32();
+ break;
+ }
+ case 32: {
+ EchoMetadata = input.ReadBool();
+ break;
+ }
+ case 40: {
+ CheckAuthContext = input.ReadBool();
+ break;
+ }
+ case 48: {
+ ResponseMessageLength = input.ReadInt32();
+ break;
+ }
+ case 56: {
+ EchoPeer = input.ReadBool();
+ break;
+ }
+ case 66: {
+ ExpectedClientIdentity = input.ReadString();
+ break;
+ }
+ case 72: {
+ SkipCancelledCheck = input.ReadBool();
+ break;
+ }
+ case 82: {
+ ExpectedTransportSecurityType = input.ReadString();
+ break;
+ }
+ case 90: {
+ if (debugInfo_ == null) {
+ debugInfo_ = new global::Grpc.Testing.DebugInfo();
+ }
+ input.ReadMessage(debugInfo_);
+ break;
+ }
+ case 96: {
+ ServerDie = input.ReadBool();
+ break;
+ }
+ case 106: {
+ BinaryErrorDetails = input.ReadString();
+ break;
+ }
+ case 114: {
+ if (expectedError_ == null) {
+ expectedError_ = new global::Grpc.Testing.ErrorStatus();
+ }
+ input.ReadMessage(expectedError_);
+ break;
+ }
+ }
+ }
+ }
+
+ }
+
+ public sealed partial class EchoRequest : pb::IMessage {
+ private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new EchoRequest());
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public static pb::MessageParser Parser { get { return _parser; } }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public static pbr::MessageDescriptor Descriptor {
+ get { return global::Grpc.Testing.EchoMessagesReflection.Descriptor.MessageTypes[3]; }
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ pbr::MessageDescriptor pb::IMessage.Descriptor {
+ get { return Descriptor; }
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public EchoRequest() {
+ OnConstruction();
+ }
+
+ partial void OnConstruction();
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public EchoRequest(EchoRequest other) : this() {
+ message_ = other.message_;
+ Param = other.param_ != null ? other.Param.Clone() : null;
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public EchoRequest Clone() {
+ return new EchoRequest(this);
+ }
+
+ /// Field number for the "message" field.
+ public const int MessageFieldNumber = 1;
+ private string message_ = "";
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public string Message {
+ get { return message_; }
+ set {
+ message_ = pb::ProtoPreconditions.CheckNotNull(value, "value");
+ }
+ }
+
+ /// Field number for the "param" field.
+ public const int ParamFieldNumber = 2;
+ private global::Grpc.Testing.RequestParams param_;
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public global::Grpc.Testing.RequestParams Param {
+ get { return param_; }
+ set {
+ param_ = value;
+ }
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public override bool Equals(object other) {
+ return Equals(other as EchoRequest);
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public bool Equals(EchoRequest other) {
+ if (ReferenceEquals(other, null)) {
+ return false;
+ }
+ if (ReferenceEquals(other, this)) {
+ return true;
+ }
+ if (Message != other.Message) return false;
+ if (!object.Equals(Param, other.Param)) return false;
+ return true;
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public override int GetHashCode() {
+ int hash = 1;
+ if (Message.Length != 0) hash ^= Message.GetHashCode();
+ if (param_ != null) hash ^= Param.GetHashCode();
+ return hash;
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public override string ToString() {
+ return pb::JsonFormatter.ToDiagnosticString(this);
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public void WriteTo(pb::CodedOutputStream output) {
+ if (Message.Length != 0) {
+ output.WriteRawTag(10);
+ output.WriteString(Message);
+ }
+ if (param_ != null) {
+ output.WriteRawTag(18);
+ output.WriteMessage(Param);
+ }
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public int CalculateSize() {
+ int size = 0;
+ if (Message.Length != 0) {
+ size += 1 + pb::CodedOutputStream.ComputeStringSize(Message);
+ }
+ if (param_ != null) {
+ size += 1 + pb::CodedOutputStream.ComputeMessageSize(Param);
+ }
+ return size;
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public void MergeFrom(EchoRequest other) {
+ if (other == null) {
+ return;
+ }
+ if (other.Message.Length != 0) {
+ Message = other.Message;
+ }
+ if (other.param_ != null) {
+ if (param_ == null) {
+ param_ = new global::Grpc.Testing.RequestParams();
+ }
+ Param.MergeFrom(other.Param);
+ }
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public void MergeFrom(pb::CodedInputStream input) {
+ uint tag;
+ while ((tag = input.ReadTag()) != 0) {
+ switch(tag) {
+ default:
+ input.SkipLastField();
+ break;
+ case 10: {
+ Message = input.ReadString();
+ break;
+ }
+ case 18: {
+ if (param_ == null) {
+ param_ = new global::Grpc.Testing.RequestParams();
+ }
+ input.ReadMessage(param_);
+ break;
+ }
+ }
+ }
+ }
+
+ }
+
+ public sealed partial class ResponseParams : pb::IMessage {
+ private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new ResponseParams());
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public static pb::MessageParser Parser { get { return _parser; } }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public static pbr::MessageDescriptor Descriptor {
+ get { return global::Grpc.Testing.EchoMessagesReflection.Descriptor.MessageTypes[4]; }
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ pbr::MessageDescriptor pb::IMessage.Descriptor {
+ get { return Descriptor; }
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public ResponseParams() {
+ OnConstruction();
+ }
+
+ partial void OnConstruction();
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public ResponseParams(ResponseParams other) : this() {
+ requestDeadline_ = other.requestDeadline_;
+ host_ = other.host_;
+ peer_ = other.peer_;
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public ResponseParams Clone() {
+ return new ResponseParams(this);
+ }
+
+ /// Field number for the "request_deadline" field.
+ public const int RequestDeadlineFieldNumber = 1;
+ private long requestDeadline_;
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public long RequestDeadline {
+ get { return requestDeadline_; }
+ set {
+ requestDeadline_ = value;
+ }
+ }
+
+ /// Field number for the "host" field.
+ public const int HostFieldNumber = 2;
+ private string host_ = "";
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public string Host {
+ get { return host_; }
+ set {
+ host_ = pb::ProtoPreconditions.CheckNotNull(value, "value");
+ }
+ }
+
+ /// Field number for the "peer" field.
+ public const int PeerFieldNumber = 3;
+ private string peer_ = "";
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public string Peer {
+ get { return peer_; }
+ set {
+ peer_ = pb::ProtoPreconditions.CheckNotNull(value, "value");
+ }
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public override bool Equals(object other) {
+ return Equals(other as ResponseParams);
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public bool Equals(ResponseParams other) {
+ if (ReferenceEquals(other, null)) {
+ return false;
+ }
+ if (ReferenceEquals(other, this)) {
+ return true;
+ }
+ if (RequestDeadline != other.RequestDeadline) return false;
+ if (Host != other.Host) return false;
+ if (Peer != other.Peer) return false;
+ return true;
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public override int GetHashCode() {
+ int hash = 1;
+ if (RequestDeadline != 0L) hash ^= RequestDeadline.GetHashCode();
+ if (Host.Length != 0) hash ^= Host.GetHashCode();
+ if (Peer.Length != 0) hash ^= Peer.GetHashCode();
+ return hash;
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public override string ToString() {
+ return pb::JsonFormatter.ToDiagnosticString(this);
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public void WriteTo(pb::CodedOutputStream output) {
+ if (RequestDeadline != 0L) {
+ output.WriteRawTag(8);
+ output.WriteInt64(RequestDeadline);
+ }
+ if (Host.Length != 0) {
+ output.WriteRawTag(18);
+ output.WriteString(Host);
+ }
+ if (Peer.Length != 0) {
+ output.WriteRawTag(26);
+ output.WriteString(Peer);
+ }
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public int CalculateSize() {
+ int size = 0;
+ if (RequestDeadline != 0L) {
+ size += 1 + pb::CodedOutputStream.ComputeInt64Size(RequestDeadline);
+ }
+ if (Host.Length != 0) {
+ size += 1 + pb::CodedOutputStream.ComputeStringSize(Host);
+ }
+ if (Peer.Length != 0) {
+ size += 1 + pb::CodedOutputStream.ComputeStringSize(Peer);
+ }
+ return size;
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public void MergeFrom(ResponseParams other) {
+ if (other == null) {
+ return;
+ }
+ if (other.RequestDeadline != 0L) {
+ RequestDeadline = other.RequestDeadline;
+ }
+ if (other.Host.Length != 0) {
+ Host = other.Host;
+ }
+ if (other.Peer.Length != 0) {
+ Peer = other.Peer;
+ }
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public void MergeFrom(pb::CodedInputStream input) {
+ uint tag;
+ while ((tag = input.ReadTag()) != 0) {
+ switch(tag) {
+ default:
+ input.SkipLastField();
+ break;
+ case 8: {
+ RequestDeadline = input.ReadInt64();
+ break;
+ }
+ case 18: {
+ Host = input.ReadString();
+ break;
+ }
+ case 26: {
+ Peer = input.ReadString();
+ break;
+ }
+ }
+ }
+ }
+
+ }
+
+ public sealed partial class EchoResponse : pb::IMessage {
+ private static readonly pb::MessageParser _parser = new pb::MessageParser(() => new EchoResponse());
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public static pb::MessageParser Parser { get { return _parser; } }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public static pbr::MessageDescriptor Descriptor {
+ get { return global::Grpc.Testing.EchoMessagesReflection.Descriptor.MessageTypes[5]; }
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ pbr::MessageDescriptor pb::IMessage.Descriptor {
+ get { return Descriptor; }
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public EchoResponse() {
+ OnConstruction();
+ }
+
+ partial void OnConstruction();
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public EchoResponse(EchoResponse other) : this() {
+ message_ = other.message_;
+ Param = other.param_ != null ? other.Param.Clone() : null;
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public EchoResponse Clone() {
+ return new EchoResponse(this);
+ }
+
+ /// Field number for the "message" field.
+ public const int MessageFieldNumber = 1;
+ private string message_ = "";
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public string Message {
+ get { return message_; }
+ set {
+ message_ = pb::ProtoPreconditions.CheckNotNull(value, "value");
+ }
+ }
+
+ /// Field number for the "param" field.
+ public const int ParamFieldNumber = 2;
+ private global::Grpc.Testing.ResponseParams param_;
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public global::Grpc.Testing.ResponseParams Param {
+ get { return param_; }
+ set {
+ param_ = value;
+ }
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public override bool Equals(object other) {
+ return Equals(other as EchoResponse);
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public bool Equals(EchoResponse other) {
+ if (ReferenceEquals(other, null)) {
+ return false;
+ }
+ if (ReferenceEquals(other, this)) {
+ return true;
+ }
+ if (Message != other.Message) return false;
+ if (!object.Equals(Param, other.Param)) return false;
+ return true;
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public override int GetHashCode() {
+ int hash = 1;
+ if (Message.Length != 0) hash ^= Message.GetHashCode();
+ if (param_ != null) hash ^= Param.GetHashCode();
+ return hash;
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public override string ToString() {
+ return pb::JsonFormatter.ToDiagnosticString(this);
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public void WriteTo(pb::CodedOutputStream output) {
+ if (Message.Length != 0) {
+ output.WriteRawTag(10);
+ output.WriteString(Message);
+ }
+ if (param_ != null) {
+ output.WriteRawTag(18);
+ output.WriteMessage(Param);
+ }
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public int CalculateSize() {
+ int size = 0;
+ if (Message.Length != 0) {
+ size += 1 + pb::CodedOutputStream.ComputeStringSize(Message);
+ }
+ if (param_ != null) {
+ size += 1 + pb::CodedOutputStream.ComputeMessageSize(Param);
+ }
+ return size;
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public void MergeFrom(EchoResponse other) {
+ if (other == null) {
+ return;
+ }
+ if (other.Message.Length != 0) {
+ Message = other.Message;
+ }
+ if (other.param_ != null) {
+ if (param_ == null) {
+ param_ = new global::Grpc.Testing.ResponseParams();
+ }
+ Param.MergeFrom(other.Param);
+ }
+ }
+
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public void MergeFrom(pb::CodedInputStream input) {
+ uint tag;
+ while ((tag = input.ReadTag()) != 0) {
+ switch(tag) {
+ default:
+ input.SkipLastField();
+ break;
+ case 10: {
+ Message = input.ReadString();
+ break;
+ }
+ case 18: {
+ if (param_ == null) {
+ param_ = new global::Grpc.Testing.ResponseParams();
+ }
+ input.ReadMessage(param_);
+ break;
+ }
+ }
+ }
+ }
+
+ }
+
+ #endregion
+
+}
+
+#endregion Designer generated code
diff --git a/src/csharp/Grpc.IntegrationTesting/Services.cs b/src/csharp/Grpc.IntegrationTesting/Services.cs
index bf36a0253b5..7a0845dffb0 100644
--- a/src/csharp/Grpc.IntegrationTesting/Services.cs
+++ b/src/csharp/Grpc.IntegrationTesting/Services.cs
@@ -24,20 +24,28 @@ namespace Grpc.Testing {
string.Concat(
"CiVzcmMvcHJvdG8vZ3JwYy90ZXN0aW5nL3NlcnZpY2VzLnByb3RvEgxncnBj",
"LnRlc3RpbmcaJXNyYy9wcm90by9ncnBjL3Rlc3RpbmcvbWVzc2FnZXMucHJv",
- "dG8aJHNyYy9wcm90by9ncnBjL3Rlc3RpbmcvY29udHJvbC5wcm90bzKqAQoQ",
- "Qm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nRlc3RpbmcuU2ltcGxlUmVxdWVzdBocLmdycGMudGVzdGlu",
+ "Zy5TaW1wbGVSZXNwb25zZSgBElIKE1N0cmVhbWluZ0Zyb21TZXJ2ZXISGy5n",
+ "cnBjLnRlc3RpbmcuU2ltcGxlUmVxdWVzdBocLmdycGMudGVzdGluZy5TaW1w",
+ "bGVSZXNwb25zZTABElIKEVN0cmVhbWluZ0JvdGhXYXlzEhsuZ3JwYy50ZXN0",
+ "aW5nLlNpbXBsZVJlcXVlc3QaHC5ncnBjLnRlc3RpbmcuU2ltcGxlUmVzcG9u",
+ "c2UoATABMpcCCg1Xb3JrZXJTZXJ2aWNlEkUKCVJ1blNlcnZlchIYLmdycGMu",
+ "dGVzdGluZy5TZXJ2ZXJBcmdzGhouZ3JwYy50ZXN0aW5nLlNlcnZlclN0YXR1",
+ "cygBMAESRQoJUnVuQ2xpZW50EhguZ3JwYy50ZXN0aW5nLkNsaWVudEFyZ3Ma",
+ "Gi5ncnBjLnRlc3RpbmcuQ2xpZW50U3RhdHVzKAEwARJCCglDb3JlQ291bnQS",
+ "GS5ncnBjLnRlc3RpbmcuQ29yZVJlcXVlc3QaGi5ncnBjLnRlc3RpbmcuQ29y",
+ "ZVJlc3BvbnNlEjQKClF1aXRXb3JrZXISEi5ncnBjLnRlc3RpbmcuVm9pZBoS",
+ "LmdycGMudGVzdGluZy5Wb2lkMl4KGFJlcG9ydFFwc1NjZW5hcmlvU2Vydmlj",
+ "ZRJCCg5SZXBvcnRTY2VuYXJpbxIcLmdycGMudGVzdGluZy5TY2VuYXJpb1Jl",
+ "c3VsdBoSLmdycGMudGVzdGluZy5Wb2lkYgZwcm90bzM="));
descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData,
- new pbr::FileDescriptor[] { global::Grpc.Testing.MessagesReflection.Descriptor, global::Grpc.Testing.ControlReflection.Descriptor, },
+ new pbr::FileDescriptor[] { global::Grpc.Testing.MessagesReflection.Descriptor, global::Grpc.Testing.ControlReflection.Descriptor, global::Grpc.Testing.StatsReflection.Descriptor, },
new pbr::GeneratedClrTypeInfo(null, null));
}
#endregion
diff --git a/src/csharp/Grpc.IntegrationTesting/ServicesGrpc.cs b/src/csharp/Grpc.IntegrationTesting/ServicesGrpc.cs
index 143c9ac9fcc..bd5971e296f 100644
--- a/src/csharp/Grpc.IntegrationTesting/ServicesGrpc.cs
+++ b/src/csharp/Grpc.IntegrationTesting/ServicesGrpc.cs
@@ -46,6 +46,27 @@ namespace Grpc.Testing {
__Marshaller_SimpleRequest,
__Marshaller_SimpleResponse);
+ static readonly grpc::Method __Method_StreamingFromClient = new grpc::Method(
+ grpc::MethodType.ClientStreaming,
+ __ServiceName,
+ "StreamingFromClient",
+ __Marshaller_SimpleRequest,
+ __Marshaller_SimpleResponse);
+
+ static readonly grpc::Method __Method_StreamingFromServer = new grpc::Method(
+ grpc::MethodType.ServerStreaming,
+ __ServiceName,
+ "StreamingFromServer",
+ __Marshaller_SimpleRequest,
+ __Marshaller_SimpleResponse);
+
+ static readonly grpc::Method __Method_StreamingBothWays = new grpc::Method(
+ grpc::MethodType.DuplexStreaming,
+ __ServiceName,
+ "StreamingBothWays",
+ __Marshaller_SimpleRequest,
+ __Marshaller_SimpleResponse);
+
/// Service descriptor
public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor
{
@@ -68,8 +89,9 @@ namespace Grpc.Testing {
}
///
- /// One request followed by one response.
- /// The server returns the client payload as-is.
+ /// Repeated sequence of one request followed by one response.
+ /// Should be called streaming ping-pong
+ /// The server returns the client payload as-is on each response
///
/// Used for reading requests from the client.
/// Used for sending responses back to the client.
@@ -80,6 +102,44 @@ namespace Grpc.Testing {
throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
}
+ ///
+ /// Single-sided unbounded streaming from client to server
+ /// The server returns the client payload as-is once the client does WritesDone
+ ///
+ /// Used for reading requests from the client.
+ /// The context of the server-side call handler being invoked.
+ /// The response to send back to the client (wrapped by a task).
+ public virtual global::System.Threading.Tasks.Task StreamingFromClient(grpc::IAsyncStreamReader requestStream, grpc::ServerCallContext context)
+ {
+ throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
+ }
+
+ ///
+ /// Single-sided unbounded streaming from server to client
+ /// The server repeatedly returns the client payload as-is
+ ///
+ /// The request received from the client.
+ /// Used for sending responses back to the client.
+ /// The context of the server-side call handler being invoked.
+ /// A task indicating completion of the handler.
+ public virtual global::System.Threading.Tasks.Task StreamingFromServer(global::Grpc.Testing.SimpleRequest request, grpc::IServerStreamWriter responseStream, grpc::ServerCallContext context)
+ {
+ throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
+ }
+
+ ///
+ /// Two-sided unbounded streaming between server to client
+ /// Both sides send the content of their own choice to the other
+ ///
+ /// Used for reading requests from the client.
+ /// Used for sending responses back to the client.
+ /// The context of the server-side call handler being invoked.
+ /// A task indicating completion of the handler.
+ public virtual global::System.Threading.Tasks.Task StreamingBothWays(grpc::IAsyncStreamReader requestStream, grpc::IServerStreamWriter responseStream, grpc::ServerCallContext context)
+ {
+ throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
+ }
+
}
/// Client for BenchmarkService
@@ -154,8 +214,9 @@ namespace Grpc.Testing {
return CallInvoker.AsyncUnaryCall(__Method_UnaryCall, null, options, request);
}
///
- /// One request followed by one response.
- /// The server returns the client payload as-is.
+ /// Repeated sequence of one request followed by one response.
+ /// Should be called streaming ping-pong
+ /// The server returns the client payload as-is on each response
///
/// The initial metadata to send with the call. This parameter is optional.
/// An optional deadline for the call. The call will be cancelled if deadline is hit.
@@ -166,8 +227,9 @@ namespace Grpc.Testing {
return StreamingCall(new grpc::CallOptions(headers, deadline, cancellationToken));
}
///
- /// One request followed by one response.
- /// The server returns the client payload as-is.
+ /// Repeated sequence of one request followed by one response.
+ /// Should be called streaming ping-pong
+ /// The server returns the client payload as-is on each response
///
/// The options for the call.
/// The call object.
@@ -175,6 +237,74 @@ namespace Grpc.Testing {
{
return CallInvoker.AsyncDuplexStreamingCall(__Method_StreamingCall, null, options);
}
+ ///
+ /// Single-sided unbounded streaming from client to server
+ /// The server returns the client payload as-is once the client does WritesDone
+ ///
+ /// The initial metadata to send with the call. This parameter is optional.
+ /// An optional deadline for the call. The call will be cancelled if deadline is hit.
+ /// An optional token for canceling the call.
+ /// The call object.
+ public virtual grpc::AsyncClientStreamingCall StreamingFromClient(grpc::Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
+ {
+ return StreamingFromClient(new grpc::CallOptions(headers, deadline, cancellationToken));
+ }
+ ///
+ /// Single-sided unbounded streaming from client to server
+ /// The server returns the client payload as-is once the client does WritesDone
+ ///
+ /// The options for the call.
+ /// The call object.
+ public virtual grpc::AsyncClientStreamingCall StreamingFromClient(grpc::CallOptions options)
+ {
+ return CallInvoker.AsyncClientStreamingCall(__Method_StreamingFromClient, null, options);
+ }
+ ///
+ /// Single-sided unbounded streaming from server to client
+ /// The server repeatedly returns the client payload as-is
+ ///
+ /// The request to send to the server.
+ /// The initial metadata to send with the call. This parameter is optional.
+ /// An optional deadline for the call. The call will be cancelled if deadline is hit.
+ /// An optional token for canceling the call.
+ /// The call object.
+ public virtual grpc::AsyncServerStreamingCall StreamingFromServer(global::Grpc.Testing.SimpleRequest request, grpc::Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
+ {
+ return StreamingFromServer(request, new grpc::CallOptions(headers, deadline, cancellationToken));
+ }
+ ///
+ /// Single-sided unbounded streaming from server to client
+ /// The server repeatedly returns the client payload as-is
+ ///
+ /// The request to send to the server.
+ /// The options for the call.
+ /// The call object.
+ public virtual grpc::AsyncServerStreamingCall StreamingFromServer(global::Grpc.Testing.SimpleRequest request, grpc::CallOptions options)
+ {
+ return CallInvoker.AsyncServerStreamingCall(__Method_StreamingFromServer, null, options, request);
+ }
+ ///
+ /// Two-sided unbounded streaming between server to client
+ /// Both sides send the content of their own choice to the other
+ ///
+ /// The initial metadata to send with the call. This parameter is optional.
+ /// An optional deadline for the call. The call will be cancelled if deadline is hit.
+ /// An optional token for canceling the call.
+ /// The call object.
+ public virtual grpc::AsyncDuplexStreamingCall StreamingBothWays(grpc::Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
+ {
+ return StreamingBothWays(new grpc::CallOptions(headers, deadline, cancellationToken));
+ }
+ ///
+ /// Two-sided unbounded streaming between server to client
+ /// Both sides send the content of their own choice to the other
+ ///
+ /// The options for the call.
+ /// The call object.
+ public virtual grpc::AsyncDuplexStreamingCall StreamingBothWays(grpc::CallOptions options)
+ {
+ return CallInvoker.AsyncDuplexStreamingCall(__Method_StreamingBothWays, null, options);
+ }
/// Creates a new instance of client from given ClientBaseConfiguration.
protected override BenchmarkServiceClient NewInstance(ClientBaseConfiguration configuration)
{
@@ -188,7 +318,10 @@ namespace Grpc.Testing {
{
return grpc::ServerServiceDefinition.CreateBuilder()
.AddMethod(__Method_UnaryCall, serviceImpl.UnaryCall)
- .AddMethod(__Method_StreamingCall, serviceImpl.StreamingCall).Build();
+ .AddMethod(__Method_StreamingCall, serviceImpl.StreamingCall)
+ .AddMethod(__Method_StreamingFromClient, serviceImpl.StreamingFromClient)
+ .AddMethod(__Method_StreamingFromServer, serviceImpl.StreamingFromServer)
+ .AddMethod(__Method_StreamingBothWays, serviceImpl.StreamingBothWays).Build();
}
}
@@ -489,5 +622,124 @@ namespace Grpc.Testing {
}
}
+ public static partial class ReportQpsScenarioService
+ {
+ static readonly string __ServiceName = "grpc.testing.ReportQpsScenarioService";
+
+ static readonly grpc::Marshaller __Marshaller_ScenarioResult = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Grpc.Testing.ScenarioResult.Parser.ParseFrom);
+ static readonly grpc::Marshaller __Marshaller_Void = grpc::Marshallers.Create((arg) => global::Google.Protobuf.MessageExtensions.ToByteArray(arg), global::Grpc.Testing.Void.Parser.ParseFrom);
+
+ static readonly grpc::Method __Method_ReportScenario = new grpc::Method(
+ grpc::MethodType.Unary,
+ __ServiceName,
+ "ReportScenario",
+ __Marshaller_ScenarioResult,
+ __Marshaller_Void);
+
+ /// Service descriptor
+ public static global::Google.Protobuf.Reflection.ServiceDescriptor Descriptor
+ {
+ get { return global::Grpc.Testing.ServicesReflection.Descriptor.Services[2]; }
+ }
+
+ /// Base class for server-side implementations of ReportQpsScenarioService
+ public abstract partial class ReportQpsScenarioServiceBase
+ {
+ ///
+ /// Report results of a QPS test benchmark scenario.
+ ///
+ /// The request received from the client.
+ /// The context of the server-side call handler being invoked.
+ /// The response to send back to the client (wrapped by a task).
+ public virtual global::System.Threading.Tasks.Task ReportScenario(global::Grpc.Testing.ScenarioResult request, grpc::ServerCallContext context)
+ {
+ throw new grpc::RpcException(new grpc::Status(grpc::StatusCode.Unimplemented, ""));
+ }
+
+ }
+
+ /// Client for ReportQpsScenarioService
+ public partial class ReportQpsScenarioServiceClient : grpc::ClientBase
+ {
+ /// Creates a new client for ReportQpsScenarioService
+ /// The channel to use to make remote calls.
+ public ReportQpsScenarioServiceClient(grpc::Channel channel) : base(channel)
+ {
+ }
+ /// Creates a new client for ReportQpsScenarioService that uses a custom CallInvoker.
+ /// The callInvoker to use to make remote calls.
+ public ReportQpsScenarioServiceClient(grpc::CallInvoker callInvoker) : base(callInvoker)
+ {
+ }
+ /// Protected parameterless constructor to allow creation of test doubles.
+ protected ReportQpsScenarioServiceClient() : base()
+ {
+ }
+ /// Protected constructor to allow creation of configured clients.
+ /// The client configuration.
+ protected ReportQpsScenarioServiceClient(ClientBaseConfiguration configuration) : base(configuration)
+ {
+ }
+
+ ///
+ /// Report results of a QPS test benchmark scenario.
+ ///
+ /// The request to send to the server.
+ /// The initial metadata to send with the call. This parameter is optional.
+ /// An optional deadline for the call. The call will be cancelled if deadline is hit.
+ /// An optional token for canceling the call.
+ /// The response received from the server.
+ public virtual global::Grpc.Testing.Void ReportScenario(global::Grpc.Testing.ScenarioResult request, grpc::Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
+ {
+ return ReportScenario(request, new grpc::CallOptions(headers, deadline, cancellationToken));
+ }
+ ///
+ /// Report results of a QPS test benchmark scenario.
+ ///
+ /// The request to send to the server.
+ /// The options for the call.
+ /// The response received from the server.
+ public virtual global::Grpc.Testing.Void ReportScenario(global::Grpc.Testing.ScenarioResult request, grpc::CallOptions options)
+ {
+ return CallInvoker.BlockingUnaryCall(__Method_ReportScenario, null, options, request);
+ }
+ ///
+ /// Report results of a QPS test benchmark scenario.
+ ///
+ /// The request to send to the server.
+ /// The initial metadata to send with the call. This parameter is optional.
+ /// An optional deadline for the call. The call will be cancelled if deadline is hit.
+ /// An optional token for canceling the call.
+ /// The call object.
+ public virtual grpc::AsyncUnaryCall ReportScenarioAsync(global::Grpc.Testing.ScenarioResult request, grpc::Metadata headers = null, DateTime? deadline = null, CancellationToken cancellationToken = default(CancellationToken))
+ {
+ return ReportScenarioAsync(request, new grpc::CallOptions(headers, deadline, cancellationToken));
+ }
+ ///
+ /// Report results of a QPS test benchmark scenario.
+ ///
+ /// The request to send to the server.
+ /// The options for the call.
+ /// The call object.
+ public virtual grpc::AsyncUnaryCall ReportScenarioAsync(global::Grpc.Testing.ScenarioResult request, grpc::CallOptions options)
+ {
+ return CallInvoker.AsyncUnaryCall(__Method_ReportScenario, null, options, request);
+ }
+ /// Creates a new instance of client from given ClientBaseConfiguration.
+ protected override ReportQpsScenarioServiceClient NewInstance(ClientBaseConfiguration configuration)
+ {
+ return new ReportQpsScenarioServiceClient(configuration);
+ }
+ }
+
+ /// Creates service definition that can be registered with a server
+ /// An object implementing the server-side handling logic.
+ public static grpc::ServerServiceDefinition BindService(ReportQpsScenarioServiceBase serviceImpl)
+ {
+ return grpc::ServerServiceDefinition.CreateBuilder()
+ .AddMethod(__Method_ReportScenario, serviceImpl.ReportScenario).Build();
+ }
+
+ }
}
#endregion
diff --git a/src/csharp/Grpc.IntegrationTesting/Stats.cs b/src/csharp/Grpc.IntegrationTesting/Stats.cs
index 79ff220436a..23b56df6bdb 100644
--- a/src/csharp/Grpc.IntegrationTesting/Stats.cs
+++ b/src/csharp/Grpc.IntegrationTesting/Stats.cs
@@ -23,27 +23,28 @@ namespace Grpc.Testing {
byte[] descriptorData = global::System.Convert.FromBase64String(
string.Concat(
"CiJzcmMvcHJvdG8vZ3JwYy90ZXN0aW5nL3N0YXRzLnByb3RvEgxncnBjLnRl",
- "c3RpbmciegoLU2VydmVyU3RhdHMSFAoMdGltZV9lbGFwc2VkGAEgASgBEhEK",
- "CXRpbWVfdXNlchgCIAEoARITCgt0aW1lX3N5c3RlbRgDIAEoARIWCg50b3Rh",
- "bF9jcHVfdGltZRgEIAEoBBIVCg1pZGxlX2NwdV90aW1lGAUgASgEIjsKD0hp",
- "c3RvZ3JhbVBhcmFtcxISCgpyZXNvbHV0aW9uGAEgASgBEhQKDG1heF9wb3Nz",
- "aWJsZRgCIAEoASJ3Cg1IaXN0b2dyYW1EYXRhEg4KBmJ1Y2tldBgBIAMoDRIQ",
- "CghtaW5fc2VlbhgCIAEoARIQCghtYXhfc2VlbhgDIAEoARILCgNzdW0YBCAB",
- "KAESFgoOc3VtX29mX3NxdWFyZXMYBSABKAESDQoFY291bnQYBiABKAEiOAoS",
- "UmVxdWVzdFJlc3VsdENvdW50EhMKC3N0YXR1c19jb2RlGAEgASgFEg0KBWNv",
- "dW50GAIgASgDIrYBCgtDbGllbnRTdGF0cxIuCglsYXRlbmNpZXMYASABKAsy",
- "Gy5ncnBjLnRlc3RpbmcuSGlzdG9ncmFtRGF0YRIUCgx0aW1lX2VsYXBzZWQY",
- "AiABKAESEQoJdGltZV91c2VyGAMgASgBEhMKC3RpbWVfc3lzdGVtGAQgASgB",
- "EjkKD3JlcXVlc3RfcmVzdWx0cxgFIAMoCzIgLmdycGMudGVzdGluZy5SZXF1",
- "ZXN0UmVzdWx0Q291bnRiBnByb3RvMw=="));
+ "c3RpbmcikQEKC1NlcnZlclN0YXRzEhQKDHRpbWVfZWxhcHNlZBgBIAEoARIR",
+ "Cgl0aW1lX3VzZXIYAiABKAESEwoLdGltZV9zeXN0ZW0YAyABKAESFgoOdG90",
+ "YWxfY3B1X3RpbWUYBCABKAQSFQoNaWRsZV9jcHVfdGltZRgFIAEoBBIVCg1j",
+ "cV9wb2xsX2NvdW50GAYgASgEIjsKD0hpc3RvZ3JhbVBhcmFtcxISCgpyZXNv",
+ "bHV0aW9uGAEgASgBEhQKDG1heF9wb3NzaWJsZRgCIAEoASJ3Cg1IaXN0b2dy",
+ "YW1EYXRhEg4KBmJ1Y2tldBgBIAMoDRIQCghtaW5fc2VlbhgCIAEoARIQCght",
+ "YXhfc2VlbhgDIAEoARILCgNzdW0YBCABKAESFgoOc3VtX29mX3NxdWFyZXMY",
+ "BSABKAESDQoFY291bnQYBiABKAEiOAoSUmVxdWVzdFJlc3VsdENvdW50EhMK",
+ "C3N0YXR1c19jb2RlGAEgASgFEg0KBWNvdW50GAIgASgDIs0BCgtDbGllbnRT",
+ "dGF0cxIuCglsYXRlbmNpZXMYASABKAsyGy5ncnBjLnRlc3RpbmcuSGlzdG9n",
+ "cmFtRGF0YRIUCgx0aW1lX2VsYXBzZWQYAiABKAESEQoJdGltZV91c2VyGAMg",
+ "ASgBEhMKC3RpbWVfc3lzdGVtGAQgASgBEjkKD3JlcXVlc3RfcmVzdWx0cxgF",
+ "IAMoCzIgLmdycGMudGVzdGluZy5SZXF1ZXN0UmVzdWx0Q291bnQSFQoNY3Ff",
+ "cG9sbF9jb3VudBgGIAEoBGIGcHJvdG8z"));
descriptor = pbr::FileDescriptor.FromGeneratedCode(descriptorData,
new pbr::FileDescriptor[] { },
new pbr::GeneratedClrTypeInfo(null, new pbr::GeneratedClrTypeInfo[] {
- new pbr::GeneratedClrTypeInfo(typeof(global::Grpc.Testing.ServerStats), global::Grpc.Testing.ServerStats.Parser, new[]{ "TimeElapsed", "TimeUser", "TimeSystem", "TotalCpuTime", "IdleCpuTime" }, null, null, null),
+ new pbr::GeneratedClrTypeInfo(typeof(global::Grpc.Testing.ServerStats), global::Grpc.Testing.ServerStats.Parser, new[]{ "TimeElapsed", "TimeUser", "TimeSystem", "TotalCpuTime", "IdleCpuTime", "CqPollCount" }, null, null, null),
new pbr::GeneratedClrTypeInfo(typeof(global::Grpc.Testing.HistogramParams), global::Grpc.Testing.HistogramParams.Parser, new[]{ "Resolution", "MaxPossible" }, null, null, null),
new pbr::GeneratedClrTypeInfo(typeof(global::Grpc.Testing.HistogramData), global::Grpc.Testing.HistogramData.Parser, new[]{ "Bucket", "MinSeen", "MaxSeen", "Sum", "SumOfSquares", "Count" }, null, null, null),
new pbr::GeneratedClrTypeInfo(typeof(global::Grpc.Testing.RequestResultCount), global::Grpc.Testing.RequestResultCount.Parser, new[]{ "StatusCode", "Count" }, null, null, null),
- new pbr::GeneratedClrTypeInfo(typeof(global::Grpc.Testing.ClientStats), global::Grpc.Testing.ClientStats.Parser, new[]{ "Latencies", "TimeElapsed", "TimeUser", "TimeSystem", "RequestResults" }, null, null, null)
+ new pbr::GeneratedClrTypeInfo(typeof(global::Grpc.Testing.ClientStats), global::Grpc.Testing.ClientStats.Parser, new[]{ "Latencies", "TimeElapsed", "TimeUser", "TimeSystem", "RequestResults", "CqPollCount" }, null, null, null)
}));
}
#endregion
@@ -79,6 +80,7 @@ namespace Grpc.Testing {
timeSystem_ = other.timeSystem_;
totalCpuTime_ = other.totalCpuTime_;
idleCpuTime_ = other.idleCpuTime_;
+ cqPollCount_ = other.cqPollCount_;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute]
@@ -157,6 +159,20 @@ namespace Grpc.Testing {
}
}
+ /// Field number for the "cq_poll_count" field.
+ public const int CqPollCountFieldNumber = 6;
+ private ulong cqPollCount_;
+ ///
+ /// Number of polls called inside completion queue
+ ///
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public ulong CqPollCount {
+ get { return cqPollCount_; }
+ set {
+ cqPollCount_ = value;
+ }
+ }
+
[global::System.Diagnostics.DebuggerNonUserCodeAttribute]
public override bool Equals(object other) {
return Equals(other as ServerStats);
@@ -175,6 +191,7 @@ namespace Grpc.Testing {
if (TimeSystem != other.TimeSystem) return false;
if (TotalCpuTime != other.TotalCpuTime) return false;
if (IdleCpuTime != other.IdleCpuTime) return false;
+ if (CqPollCount != other.CqPollCount) return false;
return true;
}
@@ -186,6 +203,7 @@ namespace Grpc.Testing {
if (TimeSystem != 0D) hash ^= TimeSystem.GetHashCode();
if (TotalCpuTime != 0UL) hash ^= TotalCpuTime.GetHashCode();
if (IdleCpuTime != 0UL) hash ^= IdleCpuTime.GetHashCode();
+ if (CqPollCount != 0UL) hash ^= CqPollCount.GetHashCode();
return hash;
}
@@ -216,6 +234,10 @@ namespace Grpc.Testing {
output.WriteRawTag(40);
output.WriteUInt64(IdleCpuTime);
}
+ if (CqPollCount != 0UL) {
+ output.WriteRawTag(48);
+ output.WriteUInt64(CqPollCount);
+ }
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute]
@@ -236,6 +258,9 @@ namespace Grpc.Testing {
if (IdleCpuTime != 0UL) {
size += 1 + pb::CodedOutputStream.ComputeUInt64Size(IdleCpuTime);
}
+ if (CqPollCount != 0UL) {
+ size += 1 + pb::CodedOutputStream.ComputeUInt64Size(CqPollCount);
+ }
return size;
}
@@ -259,6 +284,9 @@ namespace Grpc.Testing {
if (other.IdleCpuTime != 0UL) {
IdleCpuTime = other.IdleCpuTime;
}
+ if (other.CqPollCount != 0UL) {
+ CqPollCount = other.CqPollCount;
+ }
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute]
@@ -289,6 +317,10 @@ namespace Grpc.Testing {
IdleCpuTime = input.ReadUInt64();
break;
}
+ case 48: {
+ CqPollCount = input.ReadUInt64();
+ break;
+ }
}
}
}
@@ -876,6 +908,7 @@ namespace Grpc.Testing {
timeUser_ = other.timeUser_;
timeSystem_ = other.timeSystem_;
requestResults_ = other.requestResults_.Clone();
+ cqPollCount_ = other.cqPollCount_;
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute]
@@ -946,6 +979,20 @@ namespace Grpc.Testing {
get { return requestResults_; }
}
+ /// Field number for the "cq_poll_count" field.
+ public const int CqPollCountFieldNumber = 6;
+ private ulong cqPollCount_;
+ ///
+ /// Number of polls called inside completion queue
+ ///
+ [global::System.Diagnostics.DebuggerNonUserCodeAttribute]
+ public ulong CqPollCount {
+ get { return cqPollCount_; }
+ set {
+ cqPollCount_ = value;
+ }
+ }
+
[global::System.Diagnostics.DebuggerNonUserCodeAttribute]
public override bool Equals(object other) {
return Equals(other as ClientStats);
@@ -964,6 +1011,7 @@ namespace Grpc.Testing {
if (TimeUser != other.TimeUser) return false;
if (TimeSystem != other.TimeSystem) return false;
if(!requestResults_.Equals(other.requestResults_)) return false;
+ if (CqPollCount != other.CqPollCount) return false;
return true;
}
@@ -975,6 +1023,7 @@ namespace Grpc.Testing {
if (TimeUser != 0D) hash ^= TimeUser.GetHashCode();
if (TimeSystem != 0D) hash ^= TimeSystem.GetHashCode();
hash ^= requestResults_.GetHashCode();
+ if (CqPollCount != 0UL) hash ^= CqPollCount.GetHashCode();
return hash;
}
@@ -1002,6 +1051,10 @@ namespace Grpc.Testing {
output.WriteDouble(TimeSystem);
}
requestResults_.WriteTo(output, _repeated_requestResults_codec);
+ if (CqPollCount != 0UL) {
+ output.WriteRawTag(48);
+ output.WriteUInt64(CqPollCount);
+ }
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute]
@@ -1020,6 +1073,9 @@ namespace Grpc.Testing {
size += 1 + 8;
}
size += requestResults_.CalculateSize(_repeated_requestResults_codec);
+ if (CqPollCount != 0UL) {
+ size += 1 + pb::CodedOutputStream.ComputeUInt64Size(CqPollCount);
+ }
return size;
}
@@ -1044,6 +1100,9 @@ namespace Grpc.Testing {
TimeSystem = other.TimeSystem;
}
requestResults_.Add(other.requestResults_);
+ if (other.CqPollCount != 0UL) {
+ CqPollCount = other.CqPollCount;
+ }
}
[global::System.Diagnostics.DebuggerNonUserCodeAttribute]
@@ -1077,6 +1136,10 @@ namespace Grpc.Testing {
requestResults_.AddEntriesFrom(input, _repeated_requestResults_codec);
break;
}
+ case 48: {
+ CqPollCount = input.ReadUInt64();
+ break;
+ }
}
}
}