You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@bookkeeper.apache.org by zh...@apache.org on 2018/01/17 15:07:19 UTC
[bookkeeper] branch master updated: ISSUE #988: more log lines for
replication status changes
This is an automated email from the ASF dual-hosted git repository.
zhaijia pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/bookkeeper.git
The following commit(s) were added to refs/heads/master by this push:
new 1f0d153 ISSUE #988: more log lines for replication status changes
1f0d153 is described below
commit 1f0d15356ef10c8ebb14dfb3048b66dbec6c0260
Author: cguttapalem <cg...@salesforce.com>
AuthorDate: Wed Jan 17 23:07:10 2018 +0800
ISSUE #988: more log lines for replication status changes
Descriptions of the changes in this PR:
more log lines for replication status changes
Master Issue: #988
Author: cguttapalem <cg...@salesforce.com>
Reviewers: Enrico Olivelli <eo...@gmail.com>, Jia Zhai <None>, Sijie Guo <si...@apache.org>
This closes #989 from reddycharan/replicatorlogs, closes #988
---
.../org/apache/bookkeeper/meta/ZkLedgerUnderreplicationManager.java | 4 ++++
.../src/main/java/org/apache/bookkeeper/replication/Auditor.java | 2 ++
2 files changed, 6 insertions(+)
diff --git a/bookkeeper-server/src/main/java/org/apache/bookkeeper/meta/ZkLedgerUnderreplicationManager.java b/bookkeeper-server/src/main/java/org/apache/bookkeeper/meta/ZkLedgerUnderreplicationManager.java
index 35b76d5..3fa0daf 100644
--- a/bookkeeper-server/src/main/java/org/apache/bookkeeper/meta/ZkLedgerUnderreplicationManager.java
+++ b/bookkeeper-server/src/main/java/org/apache/bookkeeper/meta/ZkLedgerUnderreplicationManager.java
@@ -672,6 +672,8 @@ public class ZkLedgerUnderreplicationManager implements LedgerUnderreplicationMa
Watcher w = new Watcher() {
public void process(WatchedEvent e) {
if (e.getType() == Watcher.Event.EventType.NodeDeleted) {
+ LOG.info("LedgerReplication is enabled externally through Zookeeper, "
+ + "since DISABLE_NODE ZNode is deleted");
cb.operationComplete(0, null);
}
}
@@ -679,6 +681,8 @@ public class ZkLedgerUnderreplicationManager implements LedgerUnderreplicationMa
try {
if (null == zkc.exists(basePath + '/'
+ BookKeeperConstants.DISABLE_NODE, w)) {
+ LOG.info("LedgerReplication is enabled externally through Zookeeper, "
+ + "since DISABLE_NODE ZNode is deleted");
cb.operationComplete(0, null);
return;
}
diff --git a/bookkeeper-server/src/main/java/org/apache/bookkeeper/replication/Auditor.java b/bookkeeper-server/src/main/java/org/apache/bookkeeper/replication/Auditor.java
index 453afdc..188ce71 100644
--- a/bookkeeper-server/src/main/java/org/apache/bookkeeper/replication/Auditor.java
+++ b/bookkeeper-server/src/main/java/org/apache/bookkeeper/replication/Auditor.java
@@ -419,6 +419,8 @@ public class Auditor {
InterruptedException {
ReplicationEnableCb cb = new ReplicationEnableCb();
if (!ledgerUnderreplicationManager.isLedgerReplicationEnabled()) {
+ LOG.info("LedgerReplication is disabled externally through Zookeeper, "
+ + "since DISABLE_NODE ZNode is created, so waiting untill it is enabled");
ledgerUnderreplicationManager.notifyLedgerReplicationEnabled(cb);
cb.await();
}
--
To stop receiving notification emails like this one, please contact
['"commits@bookkeeper.apache.org" <co...@bookkeeper.apache.org>'].