Skip to content

Commit

Permalink
Improve logging of server id
Browse files Browse the repository at this point in the history
  • Loading branch information
kwin committed Feb 2, 2024
1 parent 4433a8f commit 2979f9f
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ public ScmRepository getConfiguredRepository(String url, ReleaseDescriptor relea

if (passphrase == null && server.getPassphrase() != null) {
logger.debug(
"Using passphrase from server id {} found in Maven settings", releaseDescriptor.getScmId());
"Using passphrase from server id '{}' found in Maven settings", releaseDescriptor.getScmId());
passphrase = decrypt(server.getPassphrase(), server.getId());
}
}
Expand Down Expand Up @@ -190,11 +190,11 @@ public ScmRepository getConfiguredRepository(String url, ReleaseDescriptor relea
return repository;
}

private String decrypt(String str, String server) {
private String decrypt(String str, String serverId) {
try {
return mavenCrypto.decrypt(str);
} catch (MavenCryptoException e) {
String msg = "Failed to decrypt password/passphrase for server " + server + ", using auth token as is: "
String msg = "Failed to decrypt password/passphrase for server with id '" + serverId + "', using auth token as is: "
+ e.getMessage();
if (logger.isDebugEnabled()) {
logger.warn(msg, e);
Expand Down

0 comments on commit 2979f9f

Please sign in to comment.