Alexey Serbin has posted comments on this change. Change subject: [consensus_queue] fix race in UpdateLagMetrics() ......................................................................
Patch Set 1: (1 comment) http://gerrit.cloudera.org:8080/#/c/7032/1/src/kudu/consensus/consensus_queue.cc File src/kudu/consensus/consensus_queue.cc: Line 603: std::lock_guard<simple_spinlock> l(queue_lock_); > Right, that should be the only call in a non-test. Yep, the not-so-obvious thing was accessing that last_idx_appended_to_leader from multiple places, and that's exactly where the race happened. -- To view, visit http://gerrit.cloudera.org:8080/7032 To unsubscribe, visit http://gerrit.cloudera.org:8080/settings Gerrit-MessageType: comment Gerrit-Change-Id: I25feb676619cc1f3a94fb8e631bffd8ca02ead49 Gerrit-PatchSet: 1 Gerrit-Project: kudu Gerrit-Branch: master Gerrit-Owner: Alexey Serbin <aser...@cloudera.com> Gerrit-Reviewer: Adar Dembo <a...@cloudera.com> Gerrit-Reviewer: Alexey Serbin <aser...@cloudera.com> Gerrit-Reviewer: Andrew Wong <aw...@cloudera.com> Gerrit-Reviewer: Kudu Jenkins Gerrit-Reviewer: Todd Lipcon <t...@apache.org> Gerrit-HasComments: Yes