Build failure due to `Error injecting: org.eclipse.virgo.bundlor.maven.plugin.BundlorMojo java.lang.NoClassDefFoundError: org/eclipse/virgo/bundlor/support/manifestwriter/ManifestWriterFactory`
See original GitHub issueError trace is as following:
[INFO] --- org.eclipse.virgo.bundlor.maven:1.1.2.RELEASE:bundlor (bundlor) @ docker-java ---
[WARNING] Error injecting: org.eclipse.virgo.bundlor.maven.plugin.BundlorMojo
java.lang.NoClassDefFoundError: org/eclipse/virgo/bundlor/support/manifestwriter/ManifestWriterFactory
at java.lang.Class.getDeclaredConstructors0(Native Method)
at java.lang.Class.privateGetDeclaredConstructors(Class.java:2671)
at java.lang.Class.getDeclaredConstructors(Class.java:2020)
at com.google.inject.spi.InjectionPoint.forConstructorOf(InjectionPoint.java:245)
at com.google.inject.internal.ConstructorBindingImpl.create(ConstructorBindingImpl.java:99)
at com.google.inject.internal.InjectorImpl.createUninitializedBinding(InjectorImpl.java:658)
at com.google.inject.internal.InjectorImpl.createJustInTimeBinding(InjectorImpl.java:882)
at com.google.inject.internal.InjectorImpl.createJustInTimeBindingRecursive(InjectorImpl.java:805)
at com.google.inject.internal.InjectorImpl.getJustInTimeBinding(InjectorImpl.java:282)
at com.google.inject.internal.InjectorImpl.getBindingOrThrow(InjectorImpl.java:214)
at com.google.inject.internal.InjectorImpl.getProviderOrThrow(InjectorImpl.java:1006)
at com.google.inject.internal.InjectorImpl.getProvider(InjectorImpl.java:1038)
at com.google.inject.internal.InjectorImpl.getProvider(InjectorImpl.java:1001)
at com.google.inject.internal.InjectorImpl.getInstance(InjectorImpl.java:1051)
at org.eclipse.sisu.space.AbstractDeferredClass.get(AbstractDeferredClass.java:48)
at com.google.inject.internal.ProviderInternalFactory.provision(ProviderInternalFactory.java:81)
at com.google.inject.internal.InternalFactoryToInitializableAdapter.provision(InternalFactoryToInitializableAdapter.java:53)
at com.google.inject.internal.ProviderInternalFactory$1.call(ProviderInternalFactory.java:65)
at com.google.inject.internal.ProvisionListenerStackCallback$Provision.provision(ProvisionListenerStackCallback.java:115)
at org.eclipse.sisu.bean.BeanScheduler$Activator.onProvision(BeanScheduler.java:176)
at com.google.inject.internal.ProvisionListenerStackCallback$Provision.provision(ProvisionListenerStackCallback.java:126)
at com.google.inject.internal.ProvisionListenerStackCallback.provision(ProvisionListenerStackCallback.java:68)
at com.google.inject.internal.ProviderInternalFactory.circularGet(ProviderInternalFactory.java:63)
at com.google.inject.internal.InternalFactoryToInitializableAdapter.get(InternalFactoryToInitializableAdapter.java:45)
at com.google.inject.internal.InjectorImpl$2$1.call(InjectorImpl.java:1016)
at com.google.inject.internal.InjectorImpl.callInContext(InjectorImpl.java:1092)
at com.google.inject.internal.InjectorImpl$2.get(InjectorImpl.java:1012)
at org.eclipse.sisu.inject.Guice4$1.get(Guice4.java:162)
at org.eclipse.sisu.inject.LazyBeanEntry.getValue(LazyBeanEntry.java:81)
at org.eclipse.sisu.plexus.LazyPlexusBean.getValue(LazyPlexusBean.java:51)
at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:263)
at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:255)
at org.apache.maven.plugin.internal.DefaultMavenPluginManager.getConfiguredMojo(DefaultMavenPluginManager.java:517)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:121)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:207)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:153)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:145)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:116)
at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject(LifecycleModuleBuilder.java:80)
at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build(SingleThreadedBuilder.java:51)
at org.apache.maven.lifecycle.internal.LifecycleStarter.execute(LifecycleStarter.java:128)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:307)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:193)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:106)
at org.apache.maven.cli.MavenCli.execute(MavenCli.java:863)
at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:288)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:199)
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:289)
at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:229)
at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:415)
at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:356)
Caused by: java.lang.ClassNotFoundException: org.eclipse.virgo.bundlor.support.manifestwriter.ManifestWriterFactory
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)
... 55 more
[INFO] ------------------------------------------------------------------------
[INFO] BUILD FAILURE
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 6.873 s
[INFO] Finished at: 2017-12-08T11:55:39-08:00
[INFO] Final Memory: 36M/505M
[INFO] ------------------------------------------------------------------------
[ERROR] Failed to execute goal org.eclipse.virgo.bundlor:org.eclipse.virgo.bundlor.maven:1.1.2.RELEASE:bundlor (bundlor) on project docker-java: Execution bundlor of goal org.eclipse.virgo.bundlor:org.eclipse.virgo.bundlor.maven:1.1.2.RELEASE:bundlor failed: A required class was missing while executing org.eclipse.virgo.bundlor:org.eclipse.virgo.bundlor.maven:1.1.2.RELEASE:bundlor: org/eclipse/virgo/bundlor/support/manifestwriter/ManifestWriterFactory
[ERROR] -----------------------------------------------------
[ERROR] realm = plugin>org.eclipse.virgo.bundlor:org.eclipse.virgo.bundlor.maven:1.1.2.RELEASE
[ERROR] strategy = org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy
[ERROR] urls[0] = file:/Users/yuting/.m2/repository/org/eclipse/virgo/bundlor/org.eclipse.virgo.bundlor.maven/1.1.2.RELEASE/org.eclipse.virgo.bundlor.maven-1.1.2.RELEASE.jar
[ERROR] urls[1] = file:/Users/yuting/.m2/repository/org/eclipse/virgo/bundlor/org.eclipse.virgo.bundlor/1.1.2.RELEASE/org.eclipse.virgo.bundlor-1.1.2.RELEASE.jar
[ERROR] urls[2] = file:/Users/yuting/.m2/repository/org/objectweb/asm/com.springsource.org.objectweb.asm/3.1.0/com.springsource.org.objectweb.asm-3.1.0.jar
[ERROR] urls[3] = file:/Users/yuting/.m2/repository/org/objectweb/asm/com.springsource.org.objectweb.asm.tree/3.1.0/com.springsource.org.objectweb.asm.tree-3.1.0.jar
[ERROR] urls[4] = file:/Users/yuting/.m2/repository/org/objectweb/asm/com.springsource.org.objectweb.asm.commons/3.1.0/com.springsource.org.objectweb.asm.commons-3.1.0.jar
[ERROR] urls[5] = file:/Users/yuting/.m2/repository/org/osgi/org.osgi.core/4.3.0/org.osgi.core-4.3.0.jar
[ERROR] urls[6] = file:/Users/yuting/.m2/repository/org/eclipse/virgo/util/org.eclipse.virgo.util.common/3.5.0.RELEASE/org.eclipse.virgo.util.common-3.5.0.RELEASE.jar
[ERROR] urls[7] = file:/Users/yuting/.m2/repository/org/eclipse/virgo/util/org.eclipse.virgo.util.math/3.5.0.RELEASE/org.eclipse.virgo.util.math-3.5.0.RELEASE.jar
[ERROR] urls[8] = file:/Users/yuting/.m2/repository/org/eclipse/virgo/util/org.eclipse.virgo.util.osgi.manifest/3.5.0.RELEASE/org.eclipse.virgo.util.osgi.manifest-3.5.0.RELEASE.jar
[ERROR] urls[9] = file:/Users/yuting/.m2/repository/org/eclipse/virgo/bundlor/org.eclipse.virgo.bundlor.blint/1.1.2.RELEASE/org.eclipse.virgo.bundlor.blint-1.1.2.RELEASE.jar
[ERROR] urls[10] = file:/Users/yuting/.m2/repository/org/osgi/org.osgi.compendium/4.1.0/org.osgi.compendium-4.1.0.jar
[ERROR] urls[11] = file:/Users/yuting/.m2/repository/org/slf4j/com.springsource.slf4j.api/1.6.1/com.springsource.slf4j.api-1.6.1.jar
[ERROR] urls[12] = file:/Users/yuting/.m2/repository/org/slf4j/com.springsource.slf4j.nop/1.6.1/com.springsource.slf4j.nop-1.6.1.jar
[ERROR] urls[13] = file:/Users/yuting/.m2/repository/org/eclipse/virgo/util/org.eclipse.virgo.util.osgi/3.5.0.RELEASE/org.eclipse.virgo.util.osgi-3.5.0.RELEASE.jar
[ERROR] urls[14] = file:/Users/yuting/.m2/repository/org/eclipse/virgo/util/org.eclipse.virgo.util.parser.manifest/3.5.0.RELEASE/org.eclipse.virgo.util.parser.manifest-3.5.0.RELEASE.jar
[ERROR] urls[15] = file:/Users/yuting/.m2/repository/org/apache/maven/com.springsource.org.apache.maven.plugin-api/3.0.4/com.springsource.org.apache.maven.plugin-api-3.0.4.jar
[ERROR] urls[16] = file:/Users/yuting/.m2/repository/org/codehaus/plexus/plexus-utils/1.1/plexus-utils-1.1.jar
[ERROR] Number of foreign imports: 1
[ERROR] import: Entry[import from realm ClassRealm[project>com.github.docker-java:docker-java:3.1.0-SNAPSHOT, parent: ClassRealm[maven.api, parent: null]]]
[ERROR]
[ERROR] -----------------------------------------------------: org.eclipse.virgo.bundlor.support.manifestwriter.ManifestWriterFactory
[ERROR] -> [Help 1]
[ERROR]
[ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
[ERROR] Re-run Maven using the -X switch to enable full debug logging.
[ERROR]
[ERROR] For more information about the errors and possible solutions, please read the following articles:
[ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/PluginContainerException
I checked the previous issue (https://github.com/docker-java/docker-java/issues/948), but errors are still there after adding two more dependencies listed there. Anyone met this problem before or know how to solve this problem then?
Issue Analytics
- State:
- Created 6 years ago
- Comments:5 (4 by maintainers)
Top Results From Across the Web
Error injecting: org.apache.maven.plugin.war.WarMojo
I am using Eclipse Jun 2021 release. The problem got resolved after manually configuring one of the recent war plug-ins in POM.xml. <plugin> ......
Read more >[tycho-user] Fwd: Re: java.lang.NoClassDefFoundError: org ...
Re: [tycho-user] Fwd: Re: java.lang.NoClassDefFoundError: org/apache/maven/surefire/report/PojoStackTraceWriter ...
Read more >Errors in plugin version of com.springsource.bundlor in pom.xml
I'm closing this bug since the build system will remain on Maven 2.0 (potentially migrating to Gradle rather then Maven 2.2). Comment 3...
Read more >Exporting bundle project uses incorrect MANIFEST.MF - Virgo
Hi, This sounds like a bug in the exporter. Are you using Bundlor, if so you might need to update some settings names,...
Read more >539619 – [ERROR] Failed to execute goal org.apache.maven ...
I am receiving the following error executing maven builds on all of the Jakartaee-stable projects: mvn -e -ff clean install [ERROR] Failed ......
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
change the declaration of the bundlor plugin to have the following two dependencies
https://www.bountysource.com/issues/51395000-cannot-build-project-bundlor-class-manifestwriterfactory-not-found
@fuxinghua please note that @yuting-liu already tried this