aboutsummaryrefslogtreecommitdiffhomepage
path: root/test
diff options
context:
space:
mode:
authorGravatar Craig Tiller <ctiller@google.com>2015-07-10 10:07:53 -0700
committerGravatar Craig Tiller <ctiller@google.com>2015-07-18 20:39:34 -0700
commit0dc5e6cf163f1451dfb1677ce61966be3ab1f062 (patch)
tree725b142452f0235ad20d51ae5bebc8b90abcdc49 /test
parent8bf2dcab4e73a3cfb0138f1c6e2a9db7e1f7edef (diff)
User agent string support
Diffstat (limited to 'test')
-rw-r--r--test/core/end2end/dualstack_socket_test.c4
-rw-r--r--test/cpp/end2end/end2end_test.cc7
-rw-r--r--test/cpp/qps/qps_test.cc10
3 files changed, 13 insertions, 8 deletions
diff --git a/test/core/end2end/dualstack_socket_test.c b/test/core/end2end/dualstack_socket_test.c
index 7d3568c22e..05ad42ca1f 100644
--- a/test/core/end2end/dualstack_socket_test.c
+++ b/test/core/end2end/dualstack_socket_test.c
@@ -211,6 +211,10 @@ void test_connect(const char *server_host, const char *client_host, int port,
drain_cq(cq);
grpc_completion_queue_destroy(cq);
+ grpc_metadata_array_destroy(&initial_metadata_recv);
+ grpc_metadata_array_destroy(&trailing_metadata_recv);
+ grpc_metadata_array_destroy(&request_metadata_recv);
+
grpc_call_details_destroy(&call_details);
gpr_free(details);
}
diff --git a/test/cpp/end2end/end2end_test.cc b/test/cpp/end2end/end2end_test.cc
index 89d9d635af..00088cfb15 100644
--- a/test/cpp/end2end/end2end_test.cc
+++ b/test/cpp/end2end/end2end_test.cc
@@ -249,9 +249,10 @@ class End2endTest : public ::testing::Test {
void TearDown() GRPC_OVERRIDE { server_->Shutdown(); }
void ResetStub() {
- std::shared_ptr<ChannelInterface> channel =
- CreateChannel(server_address_.str(), FakeTransportSecurityCredentials(),
- ChannelArguments());
+ ChannelArguments args;
+ args.SetString(GRPC_ARG_SECONDARY_USER_AGENT_STRING, "end2end_test");
+ std::shared_ptr<ChannelInterface> channel = CreateChannel(
+ server_address_.str(), FakeTransportSecurityCredentials(), args);
stub_ = std::move(grpc::cpp::test::util::TestService::NewStub(channel));
}
diff --git a/test/cpp/qps/qps_test.cc b/test/cpp/qps/qps_test.cc
index 07b4834cc0..7b93443f7c 100644
--- a/test/cpp/qps/qps_test.cc
+++ b/test/cpp/qps/qps_test.cc
@@ -44,8 +44,8 @@
namespace grpc {
namespace testing {
-static const int WARMUP = 5;
-static const int BENCHMARK = 10;
+static const int WARMUP = 20;
+static const int BENCHMARK = 40;
static void RunQPS() {
gpr_log(GPR_INFO, "Running QPS test");
@@ -53,8 +53,8 @@ static void RunQPS() {
ClientConfig client_config;
client_config.set_client_type(ASYNC_CLIENT);
client_config.set_enable_ssl(false);
- client_config.set_outstanding_rpcs_per_channel(1000);
- client_config.set_client_channels(8);
+ client_config.set_outstanding_rpcs_per_channel(10);
+ client_config.set_client_channels(800);
client_config.set_payload_size(1);
client_config.set_async_client_threads(8);
client_config.set_rpc_type(UNARY);
@@ -62,7 +62,7 @@ static void RunQPS() {
ServerConfig server_config;
server_config.set_server_type(ASYNC_SERVER);
server_config.set_enable_ssl(false);
- server_config.set_threads(4);
+ server_config.set_threads(8);
const auto result =
RunScenario(client_config, 1, server_config, 1, WARMUP, BENCHMARK, -2);