Hello Adar Dembo, Todd Lipcon,

I'd like you to do a code review. Please visit

    http://gerrit.cloudera.org:8080/9049

to review the following change.


Change subject: Fix bug causing undercounting of thread count metric
......................................................................

Fix bug causing undercounting of thread count metric

Early in tserver startup a handful (~5) threads are created before
StartThreadInstrumentation is called, which causes the thread manager
not to count them in the thread count metrics.

I found this bug because it would cause the thread count metric to dip
below zero on tserver shutdown, since the uncounted threads would still
decrement the metric. The fix is straightfoward and simplifies the code:
threads should always update the thread count metrics, even if the
thread pool is not yet registered with the metric handler.

Change-Id: Icd36b5c7d0ed1e157c0960011e0d8e44e143c205
---
M src/kudu/util/thread.cc
1 file changed, 6 insertions(+), 17 deletions(-)



  git pull ssh://gerrit.cloudera.org:29418/kudu refs/changes/49/9049/1
--
To view, visit http://gerrit.cloudera.org:8080/9049
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: Icd36b5c7d0ed1e157c0960011e0d8e44e143c205
Gerrit-Change-Number: 9049
Gerrit-PatchSet: 1
Gerrit-Owner: Dan Burkert <[email protected]>
Gerrit-Reviewer: Adar Dembo <[email protected]>
Gerrit-Reviewer: Todd Lipcon <[email protected]>

Reply via email to