commit | de411d4c3bc6825f7d40b8e6d0478c6019c62eb8 | [log] [tgz] |
---|---|---|
author | Luca Milanesio <luca.milanesio@gmail.com> | Wed Nov 22 22:01:37 2023 +0000 |
committer | Luca Milanesio <luca.milanesio@gmail.com> | Wed Nov 22 22:01:37 2023 +0000 |
tree | 537c655e77e272a12111b0a67538207c36a01e82 | |
parent | 5e8ebfa33a09f48de781c78bc3d09b590baac02d [diff] |
Do not swallow the cause exception when repository is not found When a repository is not found during the ApplyObject, the source exception should be used as cause and now swallowed. Change-Id: I40ecbc69310669c5960d19a4beaa8df25bb84de7
diff --git a/src/main/java/com/googlesource/gerrit/plugins/replication/pull/fetch/ApplyObject.java b/src/main/java/com/googlesource/gerrit/plugins/replication/pull/fetch/ApplyObject.java index 5a4c92f..dc90c7f 100644 --- a/src/main/java/com/googlesource/gerrit/plugins/replication/pull/fetch/ApplyObject.java +++ b/src/main/java/com/googlesource/gerrit/plugins/replication/pull/fetch/ApplyObject.java
@@ -94,7 +94,7 @@ return new RefUpdateState(refSpec.getSource(), result); } } catch (RepositoryNotFoundException e) { - throw new ResourceNotFoundException(IdString.fromDecoded(name.get())); + throw new ResourceNotFoundException(IdString.fromDecoded(name.get()), e); } } }