-
Feature Request
-
Resolution: Done
-
Major
-
3.1.3
-
None
-
None
it seems that shrinkwrap-maven-plugin doesn't work with Maven 3.6+
It would be nice to have it compatible.
for instance when using it through syndesis extension maven plugin, there is this error:
[ERROR] Failed to execute goal io.syndesis.extension:extension-maven-plugin:1.3.12.fuse-000001-redhat-2:repackage-extension (default) on project custom-step-camel: Execution default of goal io.syndesis.extension:extension-maven-plugin:1.3.12.fuse-000001-redhat-2:repackage-extension failed: Unable to invoke onlyOne([Ljava.lang.Class;@57151b3a) on object org.jboss.shrinkwrap.resolver.spi.loader.ServiceRegistry with parameters [Ljava.lang.Object;@26457986: InvocationTargetException: Could not create new service instance: org/eclipse/aether/internal/impl/DefaultDependencyCollector: org.eclipse.aether.internal.impl.DefaultDependencyCollector -> [Help 1] org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal io.syndesis.extension:extension-maven-plugin:1.3.12.fuse-000001-redhat-2:repackage-extension (default) on project custom-step-camel: Execution default of goal io.syndesis.extension:extension-maven-plugin:1.3.12.fuse-000001-redhat-2:repackage-extension failed: Unable to invoke onlyOne([Ljava.lang.Class;@57151b3a) on object org.jboss.shrinkwrap.resolver.spi.loader.ServiceRegistry with parameters [Ljava.lang.Object;@26457986 at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:215) at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:156) at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:148) at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:117) at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:81) at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:56) at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:128) at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:305) at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:192) at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:105) at org.apache.maven.cli.MavenCli.execute(MavenCli.java:956) at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:288) at org.apache.maven.cli.MavenCli.main(MavenCli.java:192) at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:282) at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:225) at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:406) at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:347) Caused by: org.apache.maven.plugin.PluginExecutionException: Execution default of goal io.syndesis.extension:extension-maven-plugin:1.3.12.fuse-000001-redhat-2:repackage-extension failed: Unable to invoke onlyOne([Ljava.lang.Class;@57151b3a) on object org.jboss.shrinkwrap.resolver.spi.loader.ServiceRegistry with parameters [Ljava.lang.Object;@26457986 at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:148) at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:210) ... 20 more Caused by: org.jboss.shrinkwrap.resolver.api.Invokable$InvocationException: Unable to invoke onlyOne([Ljava.lang.Class;@57151b3a) on object org.jboss.shrinkwrap.resolver.spi.loader.ServiceRegistry with parameters [Ljava.lang.Object;@26457986 at org.jboss.shrinkwrap.resolver.api.Invokable.invokeMethod(Invokable.java:109) at org.jboss.shrinkwrap.resolver.api.ResolverSystemFactory.createFromUserView(ResolverSystemFactory.java:93) at org.jboss.shrinkwrap.resolver.api.ResolverSystemFactory.createFromUserView(ResolverSystemFactory.java:54) at org.jboss.shrinkwrap.resolver.api.Resolvers.use(Resolvers.java:75) at org.jboss.shrinkwrap.resolver.api.maven.Maven.resolver(Maven.java:36) at io.syndesis.extension.maven.plugin.RepackageExtensionMojo.obtainBomDependencies(RepackageExtensionMojo.java:262) at io.syndesis.extension.maven.plugin.RepackageExtensionMojo.addDefaultBOMs(RepackageExtensionMojo.java:218) at io.syndesis.extension.maven.plugin.RepackageExtensionMojo.getAdditionalFilters(RepackageExtensionMojo.java:133) at io.syndesis.extension.maven.plugin.SupportMojo.filterDependencies(SupportMojo.java:94) at org.springframework.boot.maven.RepackageMojo.repackage(RepackageMojo.java:211) at org.springframework.boot.maven.RepackageMojo.execute(RepackageMojo.java:204) at io.syndesis.extension.maven.plugin.SupportMojo.execute(SupportMojo.java:50) at io.syndesis.extension.maven.plugin.RepackageExtensionMojo.execute(RepackageExtensionMojo.java:113) at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:137) ... 21 more Caused by: java.lang.reflect.InvocationTargetException at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) at java.lang.reflect.Method.invoke(Method.java:498) at org.jboss.shrinkwrap.resolver.api.Invokable.invokeMethod(Invokable.java:100) ... 34 more Caused by: java.lang.RuntimeException: Could not create new service instance at org.jboss.shrinkwrap.resolver.spi.loader.SpiServiceLoader.createInstance(SpiServiceLoader.java:251) at org.jboss.shrinkwrap.resolver.spi.loader.SpiServiceLoader.createInstances(SpiServiceLoader.java:211) at org.jboss.shrinkwrap.resolver.spi.loader.SpiServiceLoader.all(SpiServiceLoader.java:79) at org.jboss.shrinkwrap.resolver.spi.loader.SpiServiceLoader.onlyOne(SpiServiceLoader.java:85) at org.jboss.shrinkwrap.resolver.spi.loader.ServiceRegistry.onlyOne(ServiceRegistry.java:102) ... 39 more Caused by: java.lang.reflect.InvocationTargetException at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:62) at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) at java.lang.reflect.Constructor.newInstance(Constructor.java:423) at org.jboss.shrinkwrap.resolver.spi.loader.SpiServiceLoader.createInstance(SpiServiceLoader.java:247) ... 43 more Caused by: java.lang.NoClassDefFoundError: org/eclipse/aether/internal/impl/DefaultDependencyCollector at org.jboss.shrinkwrap.resolver.impl.maven.bootstrap.ShrinkWrapResolverServiceLocator.<init>(ShrinkWrapResolverServiceLocator.java:157) at org.jboss.shrinkwrap.resolver.impl.maven.bootstrap.MavenRepositorySystem.getRepositorySystem(MavenRepositorySystem.java:162) at org.jboss.shrinkwrap.resolver.impl.maven.bootstrap.MavenRepositorySystem.<init>(MavenRepositorySystem.java:61) at org.jboss.shrinkwrap.resolver.impl.maven.ConfigurableMavenWorkingSessionImpl.<init>(ConfigurableMavenWorkingSessionImpl.java:58) at org.jboss.shrinkwrap.resolver.impl.maven.MavenWorkingSessionImpl.<init>(MavenWorkingSessionImpl.java:122) at org.jboss.shrinkwrap.resolver.impl.maven.MavenResolverSystemImpl.<init>(MavenResolverSystemImpl.java:43) ... 48 more Caused by: java.lang.ClassNotFoundException: org.eclipse.aether.internal.impl.DefaultDependencyCollector at org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy.loadClass(SelfFirstStrategy.java:50) at org.codehaus.plexus.classworlds.realm.ClassRealm.unsynchronizedLoadClass(ClassRealm.java:271) at org.codehaus.plexus.classworlds.realm.ClassRealm.loadClass(ClassRealm.java:247) at org.codehaus.plexus.classworlds.realm.ClassRealm.loadClass(ClassRealm.java:239) ... 54 more