aboutsummaryrefslogtreecommitdiffhomepage
path: root/test/cpp/qps/worker.cc
diff options
context:
space:
mode:
authorGravatar vjpai <vpai@google.com>2016-02-02 09:36:36 -0800
committerGravatar vjpai <vpai@google.com>2016-02-02 09:36:36 -0800
commit21e5d2b2f10bc6d175caf7ad44d729517528a78a (patch)
tree6058ebb5815554e3850b3a5f289e599fd9425b80 /test/cpp/qps/worker.cc
parent0727180da8891485168fbe39b4c9ebb859b6b390 (diff)
Add a Quit RPC so that we can conveniently shut down the workers from the driver.
Diffstat (limited to 'test/cpp/qps/worker.cc')
-rw-r--r--test/cpp/qps/worker.cc2
1 files changed, 1 insertions, 1 deletions
diff --git a/test/cpp/qps/worker.cc b/test/cpp/qps/worker.cc
index a1e73e9abe..f42cfe3255 100644
--- a/test/cpp/qps/worker.cc
+++ b/test/cpp/qps/worker.cc
@@ -56,7 +56,7 @@ namespace testing {
static void RunServer() {
QpsWorker worker(FLAGS_driver_port, FLAGS_server_port);
- while (!got_sigint) {
+ while (!got_sigint && !worker.Done()) {
gpr_sleep_until(gpr_time_add(gpr_now(GPR_CLOCK_REALTIME),
gpr_time_from_seconds(5, GPR_TIMESPAN)));
}