You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@sling.apache.org by GitBox <gi...@apache.org> on 2022/08/15 17:48:12 UTC
[GitHub] [sling-maven-plugin] kwin commented on a diff in pull request #16: SLING-11543 improve exception handling for invalid bundle files
kwin commented on code in PR #16:
URL: https://github.com/apache/sling-maven-plugin/pull/16#discussion_r945986084
##########
src/main/java/org/apache/sling/maven/bundlesupport/BundleInstallMojo.java:
##########
@@ -65,7 +65,7 @@ protected File getBundleFileName() {
getLog().debug("No bundle found in secondary artifact " + file);
}
}
- return null;
+ throw new MojoExecutionException("No attached bundle found for this Maven project, for standalone usage use goal 'install-file' instead!");
Review Comment:
Not sure if we need to more more lenient for backwards-compatibility reasons. OTOH calling this goal should either succeed or fail the build in case the bundle cannot be installed for whatever reason (this is crucial particularly for non-interactive e.g. CI builds where no one is checking the logs). Just silently (i.e. with just some log message) skipping is bad behaviour for a Maven plugin.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: dev-unsubscribe@sling.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org