You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@kudu.apache.org by "Adar Dembo (Code Review)" <ge...@cloudera.org> on 2016/02/23 23:39:31 UTC

[kudu-CR] threadpool: prohibit shutdown and wait calls from pool member threads

Adar Dembo has uploaded a new patch set (#3).

Change subject: threadpool: prohibit shutdown and wait calls from pool member threads
......................................................................

threadpool: prohibit shutdown and wait calls from pool member threads

If a thread pool thread calls a shutdown or wait function on its own pool,
it'll deadlock. This patch introduces some checks that will turn the
deadlock into a crash as well as a test to exercise it.

The solution isn't particularly elegant, though I think it's less overhead
than a TLS-based implementation.

Change-Id: I1e00b251e0b798648b29d75c5cd82a25307129b4
---
M src/kudu/util/threadpool-test.cc
M src/kudu/util/threadpool.cc
M src/kudu/util/threadpool.h
3 files changed, 56 insertions(+), 2 deletions(-)


  git pull ssh://gerrit.cloudera.org:29418/kudu refs/changes/13/2013/3
-- 
To view, visit http://gerrit.cloudera.org:8080/2013
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I1e00b251e0b798648b29d75c5cd82a25307129b4
Gerrit-PatchSet: 3
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-Owner: Adar Dembo <ad...@cloudera.com>
Gerrit-Reviewer: Adar Dembo <ad...@cloudera.com>
Gerrit-Reviewer: Todd Lipcon <to...@apache.org>