diff options
author | Raghavendra Gowdappa <rgowdapp@redhat.com> | 2018-10-31 16:10:58 +0530 |
---|---|---|
committer | Raghavendra G <rgowdapp@redhat.com> | 2018-11-29 01:19:12 +0000 |
commit | 95e380eca19b9f0d03a53429535f15556e5724ad (patch) | |
tree | be32fca4fbfa7d29e8571545af26e784d34e294c /xlators | |
parent | f0232d07f7e6543b56830be28f6e80f9085e6241 (diff) |
rpcsvc: provide each request handler thread its own queue
A single global per program queue is contended by all request handler
threads and event threads. This can lead to high contention. So,
reduce the contention by providing each request handler thread its own
private queue.
Thanks to "Manoj Pillai"<mpillai@redhat.com> for the idea of pairing a
single queue with a fixed request-handler-thread and event-thread,
which brought down the performance regression due to overhead of
queuing significantly.
Thanks to "Xavi Hernandez"<xhernandez@redhat.com> for discussion on
how to communicate the event-thread death to request-handler-thread.
Thanks to "Karan Sandha"<ksandha@redhat.com> for voluntarily running
the perf benchmarks to qualify that performance regression introduced
by ping-timer-fixes is fixed with this patch and patiently running
many iterations of regression tests while RCAing the issue.
Thanks to "Milind Changire"<mchangir@redhat.com> for patiently running
the many iterations of perf benchmarking tests while RCAing the
regression caused by ping-timer-expiry fixes.
Change-Id: I578c3fc67713f4234bd3abbec5d3fbba19059ea5
Fixes: bz#1644629
Signed-off-by: Raghavendra Gowdappa <rgowdapp@redhat.com>
Diffstat (limited to 'xlators')
-rw-r--r-- | xlators/protocol/server/src/server.c | 9 |
1 files changed, 3 insertions, 6 deletions
diff --git a/xlators/protocol/server/src/server.c b/xlators/protocol/server/src/server.c index 8d8e8fc5718..77e5d74e7c5 100644 --- a/xlators/protocol/server/src/server.c +++ b/xlators/protocol/server/src/server.c @@ -929,12 +929,6 @@ do_rpc: if (ret) goto out; - /* rpcsvc thread reconfigure should be after events thread - * reconfigure - */ - new_nthread = ((struct event_pool *)(this->ctx->event_pool)) - ->eventthreadcount; - ret = rpcsvc_ownthread_reconf(rpc_conf, new_nthread); out: THIS = oldTHIS; gf_msg_debug("", 0, "returning %d", ret); @@ -1133,6 +1127,9 @@ server_init(xlator_t *this) ret = -1; goto out; } + + ret = dict_set_int32(this->options, "notify-poller-death", 1); + ret = rpcsvc_create_listeners(conf->rpc, this->options, this->name); if (ret < 1) { gf_msg(this->name, GF_LOG_WARNING, 0, |