make the change in scenario config rather than c#

pull/9612/head
Alexander Polcyn 8 years ago
parent d1c2866968
commit f797c65160
  1. 3
      src/csharp/Grpc.IntegrationTesting/ServerRunners.cs
  2. 5
      src/proto/grpc/testing/control.proto
  3. 3
      tools/run_tests/performance/scenario_config.py

@ -79,7 +79,8 @@ namespace Grpc.IntegrationTesting
ServerServiceDefinition service = null;
if (config.ServerType == ServerType.AsyncServer)
{
Logger.Warning("ServerConfig.PayloadConfig is not supported for C# ServerType.AsyncServer. Ignoring the value");
GrpcPreconditions.CheckArgument(config.PayloadConfig == null,
"ServerConfig.PayloadConfig shouldn't be set for BenchmarkService based server.");
service = BenchmarkService.BindService(new BenchmarkServiceImpl());
}
else if (config.ServerType == ServerType.AsyncGenericServer)

@ -139,7 +139,10 @@ message ServerConfig {
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
// payload config, used in generic server.
// Note this must NOT be used in proto (non-generic) servers. For proto servers,
// 'response sizes' must be configured from the 'response_size' field of the
// 'SimpleRequest' objects in RPC requests.
PayloadConfig payload_config = 9;
// Specify the cores we should run the server on, if desired

@ -143,8 +143,9 @@ def _ping_pong_scenario(name, rpc_type,
if use_generic_payload:
if server_type != 'ASYNC_GENERIC_SERVER':
raise Exception('Use ASYNC_GENERIC_SERVER for generic payload.')
scenario['server_config']['payload_config'] = _payload_type(use_generic_payload, req_size, resp_size)
scenario['client_config']['payload_config'] = _payload_type(use_generic_payload, req_size, resp_size)
scenario['server_config']['payload_config'] = _payload_type(use_generic_payload, req_size, resp_size)
if unconstrained_client:
outstanding_calls = outstanding if outstanding is not None else OUTSTANDING_REQUESTS[unconstrained_client]

Loading…
Cancel
Save