Hello Mike Percy, Kudu Jenkins, Todd Lipcon,
I'd like you to reexamine a change. Please visit
http://gerrit.cloudera.org:8080/10879
to look at the new patch set (#2).
Change subject: consensus: release lock before doing DNS lookups in leader
elections
......................................................................
consensus: release lock before doing DNS lookups in leader elections
Noticed this while poring over a ~60k thread pstack dump from an overloaded
cluster. Ignoring for a minute that the consensus lock isn't actually needed
to serialize this work, taking a spinlock during a potentially blocking
operation is a no-no. As is doing substantive work in a class constructor;
that's a violation of POLA [1] in our codebase.
1. https://en.wikipedia.org/wiki/Principle_of_least_astonishment
Change-Id: I8403ed74d3199ef90779b86bb7d9727a3c4af876
---
M src/kudu/consensus/leader_election.cc
M src/kudu/consensus/leader_election.h
M src/kudu/consensus/raft_consensus.cc
3 files changed, 59 insertions(+), 46 deletions(-)
git pull ssh://gerrit.cloudera.org:29418/kudu refs/changes/79/10879/2
--
To view, visit http://gerrit.cloudera.org:8080/10879
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-MessageType: newpatchset
Gerrit-Change-Id: I8403ed74d3199ef90779b86bb7d9727a3c4af876
Gerrit-Change-Number: 10879
Gerrit-PatchSet: 2
Gerrit-Owner: Adar Dembo <[email protected]>
Gerrit-Reviewer: Kudu Jenkins
Gerrit-Reviewer: Mike Percy <[email protected]>
Gerrit-Reviewer: Todd Lipcon <[email protected]>