-
Bug
-
Resolution: Duplicate
-
Major
-
None
-
None
-
None
aslak@redhat.com and mjobanek this is the issue I told you about in Peagas about two weeks ago
We have a code like this in {{createDeployment() }}:
File[] libs = Maven.configureResolver().fromFile(shrinkwrapMavenSettings).loadPomFromFile("pom.xml") .resolve("org.hawkular.commons:hawkular-rest-status", "com.squareup.okhttp:okhttp") .withTransitivity().asFile();
If shrinkwrapMavenSettings points to a settings.xml file that contains something like the following
<servers> <server> <id>jboss-snapshots-repository</id> <username>${env.NEXUS_DEPLOY_USERNAME}</username> <password>${env.NEXUS_DEPLOY_PASSWORD}</password> </server> </servers>
then the above snippet fails with
java.lang.RuntimeException: Could not invoke deployment method: public static org.jboss.shrinkwrap.api.spec.WebArchive org.hawkular.commons.rest.status.itest.StatusEndpointITest.createDeployment() at org.hawkular.commons.rest.status.itest.StatusEndpointITest.createDeployment(StatusEndpointITest.java:52)
I admit the Exception of the message is not very helpful, but that's what I get from Maven.
We have a workaround in place https://github.com/hawkular/hawkular-commons/blob/8664a3ebb8920349396949e6cc4f5991b2469524/hawkular-nest/hawkular-nest-itest/pom.xml#L181
The commit in the following PR deactivates the workaround and shows the issue
https://github.com/hawkular/hawkular-commons/pull/48