Adar Dembo has posted comments on this change. ( http://gerrit.cloudera.org:8080/11271 )
Change subject: KUDU-2059 fix race in ThreadPool while updating metrics ...................................................................... Patch Set 1: (1 comment) http://gerrit.cloudera.org:8080/#/c/11271/1/src/kudu/util/threadpool.cc File src/kudu/util/threadpool.cc: http://gerrit.cloudera.org:8080/#/c/11271/1/src/kudu/util/threadpool.cc@553 PS1, Line 553: guard.Unlock(); > How is this a race? I believe metrics_ is immutable once set, as are its me Oh, I missed that you're publishing this as a fix for KUDU-2059. I don't think this fixes that bug. The TSAN data race shows a KuduClient that's being destroyed alongside an outstanding task in DnsResolver (belonging to that client). The log shows a test fixture going out of scope, causing the last ref to a KuduClient to be dropped. This begins the teardown process for KuduClient, which will destroy its DnsResolver, which destroys its ThreadPool. Importantly, the KuduClient's Messenger is NOT destroyed, because its reactor threads each have an "internal" ref to it, and one of them is initializing a proxy, thus accessing the destroyed DnsResolver. So, the root cause is that we're destroying the KuduClient even though it has active threads that are accessing internal KuduClient state. KUDU-2439 talks about this problem in more detail. -- To view, visit http://gerrit.cloudera.org:8080/11271 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-Project: kudu Gerrit-Branch: master Gerrit-MessageType: comment Gerrit-Change-Id: I930c7e388001446e67b244a2b3e71d5afdcaf516 Gerrit-Change-Number: 11271 Gerrit-PatchSet: 1 Gerrit-Owner: Alexey Serbin <[email protected]> Gerrit-Reviewer: Adar Dembo <[email protected]> Gerrit-Reviewer: Kudu Jenkins Gerrit-Comment-Date: Mon, 20 Aug 2018 19:02:25 +0000 Gerrit-HasComments: Yes
