Skip to content

Commit

Permalink
Merge pull request #436 from jamezp/WFMP-230-4.2
Browse files Browse the repository at this point in the history
[WFMP-230] Log fallback channel resolution messages as debug instead …
  • Loading branch information
jamezp authored Dec 7, 2023
2 parents c1f769f + 17434f1 commit bf2c71c
Showing 1 changed file with 9 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -119,18 +119,22 @@ public void resolve(MavenArtifact artifact) throws MavenUniverseException {
}
}
if (!requireChannel) {
log.warn("Resolution of artifact " + artifact.getGroupId() + ":" +
artifact.getArtifactId() + " failed using configured channels. Using original version.");
if (log.isDebugEnabled()) {
log.debug("Resolution of artifact " + artifact.getGroupId() + ":" +
artifact.getArtifactId() + " failed using configured channels. Using original version.");
}
// unable to resolve the artifact through the channel.
// if the version is defined, let's resolve it directly
if (artifact.getVersion() == null) {
log.error("No version provided.");
throw new MavenUniverseException(ex.getLocalizedMessage(), ex);
}
try {
log.warn("Using version " + artifact.getVersion() +
" to resolve artifact " + artifact.getGroupId() + ":" +
artifact.getArtifactId());
if (log.isDebugEnabled()) {
log.debug("Using version " + artifact.getVersion() +
" to resolve artifact " + artifact.getGroupId() + ":" +
artifact.getArtifactId());
}
org.wildfly.channel.MavenArtifact mavenArtifact = channelSession.resolveDirectMavenArtifact(
artifact.getGroupId(), artifact.getArtifactId(), artifact.getExtension(), artifact.getClassifier(),
artifact.getVersion());
Expand Down

0 comments on commit bf2c71c

Please sign in to comment.