diff options
author | Saša Živkov <sasa.zivkov@sap.com> | 2018-11-21 17:03:35 +0100 |
---|---|---|
committer | David Pursehouse <dpursehouse@collab.net> | 2019-07-19 11:44:15 +0900 |
commit | 9b4b786ffdbbe855fe44f8f371e5660b64d94f3e (patch) | |
tree | 0ac9ea286b924b2233c60e7b8613f922b952da5c | |
parent | 3b1b656d09eb2dd73f94f50772bbeb39d167b540 (diff) |
Fix creation of missing repository when replicating to a Gerrit serverv2.15.16
When replicating to a Gerrit server over http, non-existence of a
repository is reported as:
<repo-name> unavailable
This message wasn't among expected messages and creation of the missing
repository wasn't executed.
Bug: Issue 11204
Change-Id: I3d6c3e14573b638b17d54d1777a606b8f356f1f9
-rw-r--r-- | src/main/java/com/googlesource/gerrit/plugins/replication/PushOne.java | 3 |
1 files changed, 2 insertions, 1 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 9fe497b..5f0c066 100644 --- a/src/main/java/com/googlesource/gerrit/plugins/replication/PushOne.java +++ b/src/main/java/com/googlesource/gerrit/plugins/replication/PushOne.java @@ -343,7 +343,8 @@ class PushOne implements ProjectRunnable, CanceledWhileRunning { String msg = e.getMessage(); if (msg.contains("access denied") || msg.contains("no such repository") - || msg.contains("Git repository not found")) { + || msg.contains("Git repository not found") + || msg.contains("unavailable")) { createRepository(); } else { repLog.error("Cannot replicate {}; Remote repository error: {}", projectName, msg); |