summaryrefslogtreecommitdiffstats
path: root/src/main/java/com/googlesource/gerrit/plugins/replication/PushOne.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/com/googlesource/gerrit/plugins/replication/PushOne.java')
-rw-r--r--src/main/java/com/googlesource/gerrit/plugins/replication/PushOne.java6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/main/java/com/googlesource/gerrit/plugins/replication/PushOne.java b/src/main/java/com/googlesource/gerrit/plugins/replication/PushOne.java
index 8454246..64c8fa1 100644
--- a/src/main/java/com/googlesource/gerrit/plugins/replication/PushOne.java
+++ b/src/main/java/com/googlesource/gerrit/plugins/replication/PushOne.java
@@ -228,6 +228,10 @@ class PushOne implements ProjectRunnable, CanceledWhileRunning {
return maxRetries == 0 || retryCount <= maxRetries;
}
+ private void retryDone() {
+ this.retrying = false;
+ }
+
void canceledByReplication() {
canceled = true;
}
@@ -353,6 +357,7 @@ class PushOne implements ProjectRunnable, CanceledWhileRunning {
git = gitManager.openRepository(projectName);
runImpl();
long elapsed = NANOSECONDS.toMillis(context.stop());
+ retryDone();
repLog.info(
"Replication to {} completed in {}ms, {}ms delay, {} retries",
uri,
@@ -398,6 +403,7 @@ class PushOne implements ProjectRunnable, CanceledWhileRunning {
pool.reschedule(this, Destination.RetryReason.TRANSPORT_ERROR);
}
} else {
+ retryDone();
repLog.error(
"Giving up after {} '{}' failures during replication to {}",
updateRefRetryCount,