Merge "Debug logging when replication is scheduled"
diff --git a/src/main/java/com/googlesource/gerrit/plugins/replication/Destination.java b/src/main/java/com/googlesource/gerrit/plugins/replication/Destination.java
index d55e334..3dcf0e1 100644
--- a/src/main/java/com/googlesource/gerrit/plugins/replication/Destination.java
+++ b/src/main/java/com/googlesource/gerrit/plugins/replication/Destination.java
@@ -202,6 +202,7 @@
void schedule(final Project.NameKey project, final String ref,
final URIish uri, ReplicationState state) {
try {
+ repLog.debug("scheduling replication {}:{} => {}", project, ref, uri);
boolean visible = threadScoper.scope(new Callable<Boolean>(){
@Override
public Boolean call() throws NoSuchProjectException {
@@ -209,6 +210,8 @@
}
}).call();
if (!visible) {
+ stateLog.warn(String.format("project %s is not visible", project),
+ state);
return;
}
} catch (NoSuchProjectException err) {
@@ -260,6 +263,8 @@
e.addRef(ref);
state.increasePushTaskCount(project.get(), ref);
e.addState(ref, state);
+ repLog.debug("scheduled {}:{} => {} to run after {}s", project, ref,
+ e, delay);
}
}