Will Berkeley has uploaded a new patch set (#2) to the change originally
created by Todd Lipcon. ( http://gerrit.cloudera.org:8080/12614 )
Change subject: KUDU-2711 (part 2): use a RWMutex for TSDescriptor
......................................................................
KUDU-2711 (part 2): use a RWMutex for TSDescriptor
One reason that GetTableLocations can end up slow is contention on the
TSDescriptor object.
This patch changes the spinlock to an rw_spinlock.
The benchmark improves throughput by about 77%:
table_locations-itest --gtest_filter=\*Bench\* \
--benchmark_num_tablets 300 --benchmark_num_threads 30 \
--benchmark_runtime_secs=10
before fix:
Count: 10555
Mean: 8567.29
Percentiles:
0% (min) = 68
25% = 7712
50% (med) = 8320
75% = 9152
95% = 10880
99% = 12224
99.9% = 17024
99.99% = 27776
100% (max) = 30384
with rwlock:
Count: 18758
Mean: 4024.09
Percentiles:
0% (min) = 136
25% = 3472
50% (med) = 4032
75% = 4512
95% = 5248
99% = 6048
99.9% = 7712
99.99% = 13440
100% (max) = 13976
Change-Id: Id48635e49f11d20fa1802b17a3ff5771632dfd01
---
M src/kudu/master/ts_descriptor.cc
M src/kudu/master/ts_descriptor.h
2 files changed, 20 insertions(+), 19 deletions(-)
git pull ssh://gerrit.cloudera.org:29418/kudu refs/changes/14/12614/2
--
To view, visit http://gerrit.cloudera.org:8080/12614
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: Id48635e49f11d20fa1802b17a3ff5771632dfd01
Gerrit-Change-Number: 12614
Gerrit-PatchSet: 2
Gerrit-Owner: Todd Lipcon <[email protected]>
Gerrit-Reviewer: Adar Dembo <[email protected]>
Gerrit-Reviewer: Kudu Jenkins (120)
Gerrit-Reviewer: Will Berkeley <[email protected]>