You are viewing a plain text version of this content. The canonical link for it is here.
Posted to reviews@kudu.apache.org by "Alexey Serbin (Code Review)" <ge...@cloudera.org> on 2020/01/29 05:13:05 UTC
[kudu-CR] [master] fix race in MiniMaster-based scenarios
Alexey Serbin has uploaded this change for review. ( http://gerrit.cloudera.org:8080/15125
Change subject: [master] fix race in MiniMaster-based scenarios
......................................................................
[master] fix race in MiniMaster-based scenarios
I saw a warning from the ThreadSanitizer while running the
TsTabletManagerITest.TestTableStats scenario (TSAN build). It turned
to be a test-only race in scenarios where MiniMaster is involved in
single-master test mini-cluster if calling MiniMaster::Shutdown()
after MiniMaster::Start() but before the catalog manager has completed
its initialization.
The relevant snippet from the warning:
WARNING: ThreadSanitizer: data race (pid=6972)
Write of size 8 at 0x7b7000000c70 by main thread:
#0 pthread_cond_destroy
#1 ConditionVariable::~ConditionVariable()
#2 CountDownLatch::~CountDownLatch()
#3 Promise<Status>::~Promise()
#4 Master::~Master() src/kudu/master/master.cc:129
#5 Master::~Master() src/kudu/master/master.cc:127
#6 std::__1::default_delete<Master>::operator(Master*)
#7 std::__1::unique_ptr<Master, std::__1::default_delete<Master>>::reset(Master*)
#8 MiniMaster::Shutdown() src/kudu/master/mini_master.cc:118
...
Previous read of size 8 at 0x7b7000000c70 by thread T20 (mutexes: write M50614):
#0 pthread_cond_broadcast
#1 ConditionVariable::Broadcast()
#2 CountDownLatch::CountDown(int)
#3 CountDownLatch::CountDown()
#4 Promise<Status>::Set(Status const&)
#5 Master::InitCatalogManagerTask() src/kudu/master/master.cc:206
...
Change-Id: If5122a16bb04f089fe1ec4a0d0ff157164ebfdc4
---
M src/kudu/master/master.cc
M src/kudu/master/master.h
2 files changed, 4 insertions(+), 3 deletions(-)
git pull ssh://gerrit.cloudera.org:29418/kudu refs/changes/25/15125/1
--
To view, visit http://gerrit.cloudera.org:8080/15125
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: newchange
Gerrit-Change-Id: If5122a16bb04f089fe1ec4a0d0ff157164ebfdc4
Gerrit-Change-Number: 15125
Gerrit-PatchSet: 1
Gerrit-Owner: Alexey Serbin <as...@cloudera.com>
[kudu-CR] [master] fix race in MiniMaster-based scenarios
Posted by "Alexey Serbin (Code Review)" <ge...@cloudera.org>.
Alexey Serbin has submitted this change and it was merged. ( http://gerrit.cloudera.org:8080/15125 )
Change subject: [master] fix race in MiniMaster-based scenarios
......................................................................
[master] fix race in MiniMaster-based scenarios
I saw a warning from the ThreadSanitizer while running the
TsTabletManagerITest.TestTableStats scenario (TSAN build). It turned
to be a test-only race in scenarios where MiniMaster is involved in
single-master test mini-cluster if calling MiniMaster::Shutdown()
after MiniMaster::Start() but before the catalog manager has completed
its initialization.
The relevant snippet from the warning:
WARNING: ThreadSanitizer: data race (pid=6972)
Write of size 8 at 0x7b7000000c70 by main thread:
#0 pthread_cond_destroy
#1 ConditionVariable::~ConditionVariable()
#2 CountDownLatch::~CountDownLatch()
#3 Promise<Status>::~Promise()
#4 Master::~Master() src/kudu/master/master.cc:129
#5 Master::~Master() src/kudu/master/master.cc:127
#6 std::__1::default_delete<Master>::operator(Master*)
#7 std::__1::unique_ptr<Master, std::__1::default_delete<Master>>::reset(Master*)
#8 MiniMaster::Shutdown() src/kudu/master/mini_master.cc:118
...
Previous read of size 8 at 0x7b7000000c70 by thread T20 (mutexes: write M50614):
#0 pthread_cond_broadcast
#1 ConditionVariable::Broadcast()
#2 CountDownLatch::CountDown(int)
#3 CountDownLatch::CountDown()
#4 Promise<Status>::Set(Status const&)
#5 Master::InitCatalogManagerTask() src/kudu/master/master.cc:206
...
Change-Id: If5122a16bb04f089fe1ec4a0d0ff157164ebfdc4
Reviewed-on: http://gerrit.cloudera.org:8080/15125
Tested-by: Kudu Jenkins
Reviewed-by: Adar Dembo <ad...@cloudera.com>
---
M src/kudu/master/master.cc
M src/kudu/master/master.h
2 files changed, 4 insertions(+), 3 deletions(-)
Approvals:
Kudu Jenkins: Verified
Adar Dembo: Looks good to me, approved
--
To view, visit http://gerrit.cloudera.org:8080/15125
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: merged
Gerrit-Change-Id: If5122a16bb04f089fe1ec4a0d0ff157164ebfdc4
Gerrit-Change-Number: 15125
Gerrit-PatchSet: 2
Gerrit-Owner: Alexey Serbin <as...@cloudera.com>
Gerrit-Reviewer: Adar Dembo <ad...@cloudera.com>
Gerrit-Reviewer: Alexey Serbin <as...@cloudera.com>
Gerrit-Reviewer: Kudu Jenkins (120)
Gerrit-Reviewer: Volodymyr Verovkin <ve...@cloudera.com>
[kudu-CR] [master] fix race in MiniMaster-based scenarios
Posted by "Adar Dembo (Code Review)" <ge...@cloudera.org>.
Adar Dembo has posted comments on this change. ( http://gerrit.cloudera.org:8080/15125 )
Change subject: [master] fix race in MiniMaster-based scenarios
......................................................................
Patch Set 1: Code-Review+2
--
To view, visit http://gerrit.cloudera.org:8080/15125
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: comment
Gerrit-Change-Id: If5122a16bb04f089fe1ec4a0d0ff157164ebfdc4
Gerrit-Change-Number: 15125
Gerrit-PatchSet: 1
Gerrit-Owner: Alexey Serbin <as...@cloudera.com>
Gerrit-Reviewer: Adar Dembo <ad...@cloudera.com>
Gerrit-Reviewer: Kudu Jenkins (120)
Gerrit-Reviewer: Volodymyr Verovkin <ve...@cloudera.com>
Gerrit-Comment-Date: Wed, 29 Jan 2020 18:21:32 +0000
Gerrit-HasComments: No