Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Not A Problem
-
3.0.0-M1
-
None
-
None
Description
When trying to release a project that uses the maven site plugin v3.8 or greater, the "mvn site" step fails in the perform step, and the release fails.
The cause is that the maven release plugin is ignoring the plugin versions specified in the POM, and using versions of unknown origin.
The mixing of dependencies then triggers chaos.
In the pom, we pin the maven site plugin at 3.9.1:
<plugin> <groupId>org.apache.maven.plugins</groupId> <artifactId>maven-site-plugin</artifactId> <version>3.9.1</version> </plugin>
The release plugins ignores the POM, and uses maven-site-plugin v3.3:
[INFO] [INFO] --- maven-site-plugin:3.3:site (default-site) @ horizonmarine-httpd2.4-core-horizonmarine.co.za --- [INFO] [WARNING] Report plugin org.apache.maven.plugins:maven-project-info-reports-plugin has an empty version. [INFO] [WARNING] [INFO] [WARNING] It is highly recommended to fix these problems because they threaten the stability of your build. [INFO] [WARNING] [INFO] [WARNING] For this reason, future Maven versions might no longer support building such malformed projects. [INFO] [INFO] configuring report plugin org.apache.maven.plugins:maven-project-info-reports-plugin:3.1.0 [INFO] [WARNING] Error injecting: org.apache.maven.report.projectinfo.CiManagementReport [INFO] java.lang.NoClassDefFoundError: org/apache/maven/doxia/siterenderer/DocumentContent [INFO] at java.lang.Class.getDeclaredConstructors0 (Native Method) [INFO] at java.lang.Class.privateGetDeclaredConstructors (Class.java:2671) [INFO] at java.lang.Class.getDeclaredConstructors (Class.java:2020) [INFO] at com.google.inject.spi.InjectionPoint.forConstructorOf (InjectionPoint.java:245) [INFO] at com.google.inject.internal.ConstructorBindingImpl.create (ConstructorBindingImpl.java:115) [INFO] at com.google.inject.internal.InjectorImpl.createUninitializedBinding (InjectorImpl.java:706) [INFO] at com.google.inject.internal.InjectorImpl.createJustInTimeBinding (InjectorImpl.java:930) [INFO] at com.google.inject.internal.InjectorImpl.createJustInTimeBindingRecursive (InjectorImpl.java:852) [INFO] at com.google.inject.internal.InjectorImpl.getJustInTimeBinding (InjectorImpl.java:291) [INFO] at com.google.inject.internal.InjectorImpl.getBindingOrThrow (InjectorImpl.java:222) [INFO] at com.google.inject.internal.InjectorImpl.getProviderOrThrow (InjectorImpl.java:1040) [INFO] at com.google.inject.internal.InjectorImpl.getProvider (InjectorImpl.java:1071) [INFO] at com.google.inject.internal.InjectorImpl.getProvider (InjectorImpl.java:1034) [INFO] at com.google.inject.internal.InjectorImpl.getInstance (InjectorImpl.java:1086) [INFO] at org.eclipse.sisu.space.AbstractDeferredClass.get (AbstractDeferredClass.java:48) [INFO] at com.google.inject.internal.ProviderInternalFactory.provision (ProviderInternalFactory.java:85) [INFO] at com.google.inject.internal.InternalFactoryToInitializableAdapter.provision (InternalFactoryToInitializableAdapter.java:57) [INFO] at com.google.inject.internal.ProviderInternalFactory$1.call (ProviderInternalFactory.java:66) [INFO] at com.google.inject.internal.ProvisionListenerStackCallback$Provision.provision (ProvisionListenerStackCallback.java:112) [INFO] at com.google.inject.internal.ProvisionListenerStackCallback$Provision.provision (ProvisionListenerStackCallback.java:127) [INFO] at com.google.inject.internal.ProvisionListenerStackCallback.provision (ProvisionListenerStackCallback.java:66) [INFO] at com.google.inject.internal.ProviderInternalFactory.circularGet (ProviderInternalFactory.java:61) [INFO] at com.google.inject.internal.InternalFactoryToInitializableAdapter.get (InternalFactoryToInitializableAdapter.java:47) [INFO] at com.google.inject.internal.InjectorImpl$1.get (InjectorImpl.java:1050) [INFO] at org.eclipse.sisu.inject.Guice4$1.get (Guice4.java:162) [INFO] at org.eclipse.sisu.inject.LazyBeanEntry.getValue (LazyBeanEntry.java:81) [INFO] at org.eclipse.sisu.plexus.LazyPlexusBean.getValue (LazyPlexusBean.java:51) [INFO] at org.codehaus.plexus.DefaultPlexusContainer.lookup (DefaultPlexusContainer.java:263) [INFO] at org.codehaus.plexus.DefaultPlexusContainer.lookup (DefaultPlexusContainer.java:255) [INFO] at org.apache.maven.plugin.internal.DefaultMavenPluginManager.getConfiguredMojo (DefaultMavenPluginManager.java:520) [INFO] at org.apache.maven.reporting.exec.DefaultMavenReportExecutor.getConfiguredMavenReport (DefaultMavenReportExecutor.java:306) [INFO] at org.apache.maven.reporting.exec.DefaultMavenReportExecutor.buildReportPlugin (DefaultMavenReportExecutor.java:263) [INFO] at org.apache.maven.reporting.exec.DefaultMavenReportExecutor.buildMavenReports (DefaultMavenReportExecutor.java:154) [INFO] at org.apache.maven.plugins.site.AbstractSiteRenderingMojo.getReports (AbstractSiteRenderingMojo.java:235) [INFO] at org.apache.maven.plugins.site.SiteMojo.execute (SiteMojo.java:121) [INFO] at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo (DefaultBuildPluginManager.java:137) [INFO] at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:210) [INFO] at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:156) [INFO] at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:148) [INFO] at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:117) [INFO] at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:81) [INFO] at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build (SingleThreadedBuilder.java:56) [INFO] at org.apache.maven.lifecycle.internal.LifecycleStarter.execute (LifecycleStarter.java:128) [INFO] at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:305) [INFO] at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:192) [INFO] at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:105) [INFO] at org.apache.maven.cli.MavenCli.execute (MavenCli.java:956) [INFO] at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:288) [INFO] at org.apache.maven.cli.MavenCli.main (MavenCli.java:192) [INFO] at sun.reflect.NativeMethodAccessorImpl.invoke0 (Native Method) [INFO] at sun.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:62) [INFO] at sun.reflect.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAccessorImpl.java:43) [INFO] at java.lang.reflect.Method.invoke (Method.java:498) [INFO] at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced (Launcher.java:282) [INFO] at org.codehaus.plexus.classworlds.launcher.Launcher.launch (Launcher.java:225) [INFO] at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode (Launcher.java:406) [INFO] at org.codehaus.plexus.classworlds.launcher.Launcher.main (Launcher.java:347) [INFO] Caused by: java.lang.ClassNotFoundException: org.apache.maven.doxia.siterenderer.DocumentContent [INFO] at org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy.loadClass (SelfFirstStrategy.java:50) [INFO] at org.codehaus.plexus.classworlds.realm.ClassRealm.unsynchronizedLoadClass (ClassRealm.java:271) [INFO] at org.codehaus.plexus.classworlds.realm.ClassRealm.loadClass (ClassRealm.java:247) [INFO] at org.codehaus.plexus.classworlds.realm.ClassRealm.loadClass (ClassRealm.java:239) [INFO] at java.lang.Class.getDeclaredConstructors0 (Native Method) [INFO] at java.lang.Class.privateGetDeclaredConstructors (Class.java:2671) [INFO] at java.lang.Class.getDeclaredConstructors (Class.java:2020) [INFO] at com.google.inject.spi.InjectionPoint.forConstructorOf (InjectionPoint.java:245) [INFO] at com.google.inject.internal.ConstructorBindingImpl.create (ConstructorBindingImpl.java:115) [INFO] at com.google.inject.internal.InjectorImpl.createUninitializedBinding (InjectorImpl.java:706) [INFO] at com.google.inject.internal.InjectorImpl.createJustInTimeBinding (InjectorImpl.java:930) [INFO] at com.google.inject.internal.InjectorImpl.createJustInTimeBindingRecursive (InjectorImpl.java:852) [INFO] at com.google.inject.internal.InjectorImpl.getJustInTimeBinding (InjectorImpl.java:291) [INFO] at com.google.inject.internal.InjectorImpl.getBindingOrThrow (InjectorImpl.java:222) [INFO] at com.google.inject.internal.InjectorImpl.getProviderOrThrow (InjectorImpl.java:1040) [INFO] at com.google.inject.internal.InjectorImpl.getProvider (InjectorImpl.java:1071) [INFO] at com.google.inject.internal.InjectorImpl.getProvider (InjectorImpl.java:1034) [INFO] at com.google.inject.internal.InjectorImpl.getInstance (InjectorImpl.java:1086) [INFO] at org.eclipse.sisu.space.AbstractDeferredClass.get (AbstractDeferredClass.java:48) [INFO] at com.google.inject.internal.ProviderInternalFactory.provision (ProviderInternalFactory.java:85) [INFO] at com.google.inject.internal.InternalFactoryToInitializableAdapter.provision (InternalFactoryToInitializableAdapter.java:57) [INFO] at com.google.inject.internal.ProviderInternalFactory$1.call (ProviderInternalFactory.java:66) [INFO] at com.google.inject.internal.ProvisionListenerStackCallback$Provision.provision (ProvisionListenerStackCallback.java:112) [INFO] at com.google.inject.internal.ProvisionListenerStackCallback$Provision.provision (ProvisionListenerStackCallback.java:127) [INFO] at com.google.inject.internal.ProvisionListenerStackCallback.provision (ProvisionListenerStackCallback.java:66) [INFO] at com.google.inject.internal.ProviderInternalFactory.circularGet (ProviderInternalFactory.java:61) [INFO] at com.google.inject.internal.InternalFactoryToInitializableAdapter.get (InternalFactoryToInitializableAdapter.java:47) [INFO] at com.google.inject.internal.InjectorImpl$1.get (InjectorImpl.java:1050) [INFO] at org.eclipse.sisu.inject.Guice4$1.get (Guice4.java:162) [INFO] at org.eclipse.sisu.inject.LazyBeanEntry.getValue (LazyBeanEntry.java:81) [INFO] at org.eclipse.sisu.plexus.LazyPlexusBean.getValue (LazyPlexusBean.java:51) [INFO] at org.codehaus.plexus.DefaultPlexusContainer.lookup (DefaultPlexusContainer.java:263) [INFO] at org.codehaus.plexus.DefaultPlexusContainer.lookup (DefaultPlexusContainer.java:255) [INFO] at org.apache.maven.plugin.internal.DefaultMavenPluginManager.getConfiguredMojo (DefaultMavenPluginManager.java:520) [INFO] at org.apache.maven.reporting.exec.DefaultMavenReportExecutor.getConfiguredMavenReport (DefaultMavenReportExecutor.java:306) [INFO] at org.apache.maven.reporting.exec.DefaultMavenReportExecutor.buildReportPlugin (DefaultMavenReportExecutor.java:263) [INFO] at org.apache.maven.reporting.exec.DefaultMavenReportExecutor.buildMavenReports (DefaultMavenReportExecutor.java:154) [INFO] at org.apache.maven.plugins.site.AbstractSiteRenderingMojo.getReports (AbstractSiteRenderingMojo.java:235) [INFO] at org.apache.maven.plugins.site.SiteMojo.execute (SiteMojo.java:121) [INFO] at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo (DefaultBuildPluginManager.java:137) [INFO] at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:210) [INFO] at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:156) [INFO] at org.apache.maven.lifecycle.internal.MojoExecutor.execute (MojoExecutor.java:148) [INFO] at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:117) [INFO] at org.apache.maven.lifecycle.internal.LifecycleModuleBuilder.buildProject (LifecycleModuleBuilder.java:81) [INFO] at org.apache.maven.lifecycle.internal.builder.singlethreaded.SingleThreadedBuilder.build (SingleThreadedBuilder.java:56) [INFO] at org.apache.maven.lifecycle.internal.LifecycleStarter.execute (LifecycleStarter.java:128) [INFO] at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:305) [INFO] at org.apache.maven.DefaultMaven.doExecute (DefaultMaven.java:192) [INFO] at org.apache.maven.DefaultMaven.execute (DefaultMaven.java:105) [INFO] at org.apache.maven.cli.MavenCli.execute (MavenCli.java:956) [INFO] at org.apache.maven.cli.MavenCli.doMain (MavenCli.java:288) [INFO] at org.apache.maven.cli.MavenCli.main (MavenCli.java:192) [INFO] at sun.reflect.NativeMethodAccessorImpl.invoke0 (Native Method) [INFO] at sun.reflect.NativeMethodAccessorImpl.invoke (NativeMethodAccessorImpl.java:62) [INFO] at sun.reflect.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAccessorImpl.java:43) [INFO] at java.lang.reflect.Method.invoke (Method.java:498) [INFO] at org.codehaus.plexus.classworlds.launcher.Launcher.launchEnhanced (Launcher.java:282) [INFO] at org.codehaus.plexus.classworlds.launcher.Launcher.launch (Launcher.java:225) [INFO] at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode (Launcher.java:406)
It is currently impossible to release code with maven.