Todd Lipcon has submitted this change and it was merged.

Change subject: KUDU-1513. consensus: improve log messages for lagging or 
tablet-copying peers
......................................................................


KUDU-1513. consensus: improve log messages for lagging or tablet-copying peers

This patch improves the log throttling utility code so that it supports
a user-defined "throttler" instance. It then uses a throttler for each
consensus peer in order to improve the logging:

- we used to spew "Successfully read <N> ops from disk" messages out of
  log_cache.cc when we were reading messages for a lagging peer. This
  message was not that useful, considering it didn't tell us which peer
  was lagging. This is now replaced by a specific (and throttled)
  message letting us know which peer is lagging and how far behind they
  are.

  Unfortunately the "how far behind" is only in terms of op indexes and
  not time, since we don't attach any wall time to ReplicateMsgs. Still,
  this is better than we had before.

- we used to spew "Sending request to start Tablet Copy" if a peer was
  already in the process of copying. This log message is relocated and
  also now throttled to once every few seconds.

Change-Id: I4dd560309841ba738b031ea87b12f8f612e6c674
Reviewed-on: http://gerrit.cloudera.org:8080/4184
Reviewed-by: Todd Lipcon <t...@apache.org>
Tested-by: Todd Lipcon <t...@apache.org>
---
M src/kudu/consensus/consensus_peers.cc
M src/kudu/consensus/consensus_queue.cc
M src/kudu/consensus/consensus_queue.h
M src/kudu/consensus/log_cache.cc
M src/kudu/util/logging-test.cc
M src/kudu/util/logging.h
M src/kudu/util/logging_test_util.h
7 files changed, 116 insertions(+), 16 deletions(-)

Approvals:
  Todd Lipcon: Looks good to me, approved; Verified



-- 
To view, visit http://gerrit.cloudera.org:8080/4184
To unsubscribe, visit http://gerrit.cloudera.org:8080/settings

Gerrit-MessageType: merged
Gerrit-Change-Id: I4dd560309841ba738b031ea87b12f8f612e6c674
Gerrit-PatchSet: 3
Gerrit-Project: kudu
Gerrit-Branch: master
Gerrit-Owner: Todd Lipcon <t...@apache.org>
Gerrit-Reviewer: Dan Burkert <d...@cloudera.com>
Gerrit-Reviewer: Kudu Jenkins
Gerrit-Reviewer: Todd Lipcon <t...@apache.org>
Gerrit-Reviewer: Will Berkeley <wdberke...@gmail.com>

Reply via email to