I am building my project using Apache Maven-2.2.1.
Earlier I run maven steps it download maven repository successfully. Then I was using jdk1.6.0_10, my JAVA_HOME environment variable have same entry of jdk1.6.0_10.
Now I have updated my Java version from 6 to 7, building application in JavaFX using jdk1.7.0_09, so I have set my JAVAFX_HOME pointing jdk1.7.0_09, but JAVA_HOME still points to jdk1.6.0_10. This time maven is downloading successully, giving me following error on build -
[INFO] ------------------------------------------------------------------------
[ERROR] BUILD ERROR
[INFO] ------------------------------------------------------------------------
[INFO] Internal error in the plugin manager executing goal 'com.sun.enterprise:osgiversion-maven-plugin:0.4.11:compute-osgi-version': Unable to load the mojo 'com.sun.enterprise:osgiversion-maven-plugin:0.4.11:compute-osgi-version' in the plugin 'com.sun.enterprise:osgiversion-maven-plugin'. A required class is missing: Lorg/apache/maven/shared/osgi/Maven2OsgiConverter;
org.apache.maven.shared.osgi.Maven2OsgiConverter
[INFO] ------------------------------------------------------------------------
[INFO] Trace
org.apache.maven.lifecycle.LifecycleExecutionException: Internal error in the plugin manager executing goal 'com.sun.enterprise:osgiversion-maven-plugin:0.4.11:compute-osgi-version': Unable to load the mojo 'com.sun.enterprise:osgiversion-maven-plugin:0.4.11:compute-osgi-version' in the plugin 'com.sun.enterprise:osgiversion-maven-plugin'. A required class is missing: Lorg/apache/maven/shared/osgi/Maven2OsgiConverter;
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:698)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle(DefaultLifecycleExecutor.java:556)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:535)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:387)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:348)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:180)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:362)
at org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:60)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
Caused by: org.apache.maven.plugin.PluginManagerException: Unable to load the mojo 'com.sun.enterprise:osgiversion-maven-plugin:0.4.11:compute-osgi-version' in the plugin 'com.sun.enterprise:osgiversion-maven-plugin'. A required class is missing: Lorg/apache/maven/shared/osgi/Maven2OsgiConverter;
at org.apache.maven.plugin.DefaultPluginManager.getConfiguredMojo(DefaultPluginManager.java:679)
at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:468)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:694)
... 17 more
Caused by: java.lang.NoClassDefFoundError: Lorg/apache/maven/shared/osgi/Maven2OsgiConverter;
at java.lang.Class.getDeclaredFields0(Native Method)
at java.lang.Class.privateGetDeclaredFields(Class.java:2291)
at java.lang.Class.getDeclaredField(Class.java:1880)
at hidden.org.codehaus.plexus.util.ReflectionUtils.getFieldByNameIncludingSuperclasses(ReflectionUtils.java:47)
at org.codehaus.plexus.component.composition.FieldComponentComposer.getFieldByName(FieldComponentComposer.java:212)
at org.codehaus.plexus.component.composition.FieldComponentComposer.findMatchingField(FieldComponentComposer.java:171)
at org.codehaus.plexus.component.composition.FieldComponentComposer.assembleComponent(FieldComponentComposer.java:62)
at org.codehaus.plexus.component.composition.DefaultComponentComposerManager.assembleComponent(DefaultComponentComposerManager.java:68)
at org.codehaus.plexus.DefaultPlexusContainer.composeComponent(DefaultPlexusContainer.java:1486)
at org.codehaus.plexus.personality.plexus.lifecycle.phase.CompositionPhase.execute(CompositionPhase.java:29)
at org.codehaus.plexus.lifecycle.AbstractLifecycleHandler.start(AbstractLifecycleHandler.java:101)
at org.codehaus.plexus.component.manager.AbstractComponentManager.startComponentLifecycle(AbstractComponentManager.java:105)
at org.codehaus.plexus.component.manager.AbstractComponentManager.createComponentInstance(AbstractComponentManager.java:95)
at org.codehaus.plexus.component.manager.PerLookupComponentManager.getComponent(PerLookupComponentManager.java:48)
at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:331)
at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:440)
at org.apache.maven.plugin.DefaultPluginManager.getConfiguredMojo(DefaultPluginManager.java:652)
... 19 more
Caused by: java.lang.ClassNotFoundException: org.apache.maven.shared.osgi.Maven2OsgiConverter
at java.net.URLClassLoader$1.run(URLClassLoader.java:200)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:307)
at org.codehaus.classworlds.RealmClassLoader.loadClassDirect(RealmClassLoader.java:195)
at org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:255)
at org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:274)
at org.codehaus.classworlds.RealmClassLoader.loadClass(RealmClassLoader.java:214)
at java.lang.ClassLoader.loadClass(ClassLoader.java:252)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:320)
... 36 more
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 29 minutes 36 seconds
[INFO] Finished at: Fri Dec 21 13:07:49 IST 2012
[INFO] Final Memory: 13M/23M
[INFO] ------------------------------------------------------------------------
Is this an issue of Java or any changes have been done in Maven-2.2.1 version. I downloaded this version of maven and compared with old but no changes found. Can anyone sort out this issue?
I have tried to download Maven-3.0.3 (also tried Maven-2.2.1 but getting same above error) with JAVA_HOME to jdk1.7.0_09, I have clarify the usage of JAVAFX_HOME, it is not used for maven downloading. Still I am getting same issues, exception of downloading Maven-3.0.3 is -
[INFO] ------------------------------------------------------------------------
[ERROR] BUILD ERROR
[INFO] ------------------------------------------------------------------------
[INFO] Internal error in the plugin manager executing goal 'com.sun.enterprise:osgiversion-maven-plugin:0.4.11:compute-osgi-version': Unable to load the mojo 'com.sun.enterprise:osgiversion-maven-plugin:0.4.11:compute-osgi-version' in the plugin 'com.sun.enterprise:osgiversion-maven-plugin'. A required class is missing: Lorg/apache/maven/shared/osgi/Maven2OsgiConverter;
org.apache.maven.shared.osgi.Maven2OsgiConverter
[INFO] ------------------------------------------------------------------------
[INFO] Trace
org.apache.maven.lifecycle.LifecycleExecutionException: Internal error in the plugin manager executing goal 'com.sun.enterprise:osgiversion-maven-plugin:0.4.11:compute-osgi-version': Unable to load the mojo 'com.sun.enterprise:osgiversion-maven-plugin:0.4.11:compute-osgi-version' in the plugin 'com.sun.enterprise:osgiversion-maven-plugin'. A required class is missing: Lorg/apache/maven/shared/osgi/Maven2OsgiConverter;
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:698)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle(DefaultLifecycleExecutor.java:556)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:535)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:387)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:348)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:180)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:362)
at org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:60)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:601)
at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
Caused by: org.apache.maven.plugin.PluginManagerException: Unable to load the mojo 'com.sun.enterprise:osgiversion-maven-plugin:0.4.11:compute-osgi-version' in the plugin 'com.sun.enterprise:osgiversion-maven-plugin'. A required class is missing: Lorg/apache/maven/shared/osgi/Maven2OsgiConverter;
at org.apache.maven.plugin.DefaultPluginManager.getConfiguredMojo(DefaultPluginManager.java:679)
at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:468)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:694)
... 17 more
Caused by: java.lang.NoClassDefFoundError: Lorg/apache/maven/shared/osgi/Maven2OsgiConverter;
at java.lang.Class.getDeclaredFields0(Native Method)
at java.lang.Class.privateGetDeclaredFields(Class.java:2308)
at java.lang.Class.getDeclaredField(Class.java:1897)
at hidden.org.codehaus.plexus.util.ReflectionUtils.getFieldByNameIncludingSuperclasses(ReflectionUtils.java:47)
at org.codehaus.plexus.component.composition.FieldComponentComposer.getFieldByName(FieldComponentComposer.java:212)
at org.codehaus.plexus.component.composition.FieldComponentComposer.findMatchingField(FieldComponentComposer.java:171)
at org.codehaus.plexus.component.composition.FieldComponentComposer.assembleComponent(FieldComponentComposer.java:62)
at org.codehaus.plexus.component.composition.DefaultComponentComposerManager.assembleComponent(DefaultComponentComposerManager.java:68)
at org.codehaus.plexus.DefaultPlexusContainer.composeComponent(DefaultPlexusContainer.java:1486)
at org.codehaus.plexus.personality.plexus.lifecycle.phase.CompositionPhase.execute(CompositionPhase.java:29)
at org.codehaus.plexus.lifecycle.AbstractLifecycleHandler.start(AbstractLifecycleHandler.java:101)
at org.codehaus.plexus.component.manager.AbstractComponentManager.startComponentLifecycle(AbstractComponentManager.java:105)
at org.codehaus.plexus.component.manager.AbstractComponentManager.createComponentInstance(AbstractComponentManager.java:95)
at org.codehaus.plexus.component.manager.PerLookupComponentManager.getComponent(PerLookupComponentManager.java:48)
at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:331)
at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:440)
at org.apache.maven.plugin.DefaultPluginManager.getConfiguredMojo(DefaultPluginManager.java:652)
... 19 more
Caused by: java.lang.ClassNotFoundException: org.apache.maven.shared.osgi.Maven2OsgiConverter
at java.net.URLClassLoader$1.run(URLClassLoader.java:366)
at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
at java.lang.ClassLoader.loadClass(ClassLoader.java:423)
at org.codehaus.classworlds.RealmClassLoader.loadClassDirect(RealmClassLoader.java:195)
at org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:255)
at org.codehaus.classworlds.DefaultClassRealm.loadClass(DefaultClassRealm.java:274)
at org.codehaus.classworlds.RealmClassLoader.loadClass(RealmClassLoader.java:214)
at java.lang.ClassLoader.loadClass(ClassLoader.java:356)
... 36 more
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 19 minutes 30 seconds
[INFO] Finished at: Fri Dec 21 19:13:39 IST 2012
[INFO] Final Memory: 15M/63M
[INFO] ------------------------------------------------------------------------
How to fix those errors?
Thanks!
Related
I recently change my SONARQUBE configuration:
Before:
SonarQube 5.1
Java plugin 3.0
PMD plugin 2.3
Checkstyle plugin 2.2
FindBugs plugin 3.2
Issue Assign plugin 1.6
After:
SonarQube 5.1
Java plugin 3.3
PMD plugin 2.4.1
Checkstyle plugin 2.3
FindBugs plugin 3.2
Issue Assign plugin 1.6
On new configuration I have enabled all new rules brought from 3.1 to 3.2 Java plugin version.
The analysis batch fails at IssueTracking Decorating stage of the batch analysis:
[INFO] [08:37:25.503] Compare over 1 days (2015-05-31, analysis of Fri May 29 21:49:21 BST 2015)
[INFO] [08:37:25.504] Compare over 7 days (2015-05-25, analysis of Mon May 25 08:07:18 BST 2015)
[INFO] [08:37:25.505] Compare over 30 days (2015-05-02, analysis of Sat May 02 00:19:16 BST 2015)
[INFO] [08:37:25.506] Compare to date 2014-04-01 (analysis of 2014-06-06)
[INFO] [08:37:25.741] Execute decorators...
[INFO] [08:37:25.744] Issue 2c785d7e-3a5b-4282-9c5b-39bd4d645a81 won't be auto-assigned. Reason: NOT_NEW
[INFO] [08:37:25.744] Issue ebcf237e-1bc5-407c-9d84-1224f029b7f6 won't be auto-assigned. Reason: BEFORE_CUTOFF_DATE
[INFO] [08:37:25.748] Issue 01da957a-a184-4baa-8adf-15984869b1fc won't be auto-assigned. Reason: BEFORE_CUTOFF_DATE
[INFO] [08:37:25.749] Issue 4fe8ef3e-de23-4c59-8846-21b4cd5a875b won't be auto-assigned. Reason: BEFORE_CUTOFF_DATE
[INFO] [08:37:25.749] Issue 6684e397-09ce-488f-8a10-4e5c1eb40492 won't be auto-assigned. Reason: BEFORE_CUTOFF_DATE
[INFO] [08:37:25.749] Issue 6abbb736-898d-4592-bc05-4a52062c57c8 won't be auto-assigned. Reason: BEFORE_CUTOFF_DATE
[INFO] [08:37:25.749] Issue 7375deed-09a7-45b1-8184-40f0b4a4666f won't be auto-assigned. Reason: BEFORE_CUTOFF_DATE
[INFO] [08:37:25.749] Issue 90d82183-edf0-4854-b096-e9a9105af3ad won't be auto-assigned. Reason: BEFORE_CUTOFF_DATE
[INFO] [08:37:25.750] Issue 9170b68c-909b-40c7-aea1-571d8e99ac74 won't be auto-assigned. Reason: BEFORE_CUTOFF_DATE
[INFO] [08:37:25.750] Issue 95221ab3-aa9f-4dc3-9a03-11ddb7dea082 won't be auto-assigned. Reason: BEFORE_CUTOFF_DATE
[ERROR] Failed to execute goal org.codehaus.mojo:sonar-maven-plugin:2.6:sonar (default-cli) on project myapp: Fail to decorate 'org.sonar.api.resources.File#7d30e345[key=src/main/java/com/mycompany/EquityAccountingHandler.java,path=src/main/java/com/mycompany/EquityAccountingHandler.java,filename=EquityAccountingHandler.java,language=Java]': 489 -> [Help 1]
org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal org.codehaus.mojo:sonar-maven-plugin:2.6:sonar (default-cli) on project myapp: Fail to decorate 'org.sonar.api.resources.File#7d30e345[key=src/main/java/com/mycompany/EquityAccountingHandler.java,path=src/main/java/com/mycompany/EquityAccountingHandler.java,filename=EquityAccountingHandler.java,language=Java]'
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:216)
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:120)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:355)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:155)
at org.apache.maven.cli.MavenCli.execute(MavenCli.java:584)
at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:216)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:160)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
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: org.apache.maven.plugin.MojoExecutionException: Fail to decorate 'org.sonar.api.resources.File#7d30e345[key=src/main/java/com/mycompany/EquityAccountingHandler.java,path=src/main/java/com/mycompany/EquityAccountingHandler.java,filename=EquityAccountingHandler.java,language=Java]'
at org.codehaus.mojo.sonar.bootstrap.ExceptionHandling.handle(ExceptionHandling.java:41)
at org.codehaus.mojo.sonar.bootstrap.RunnerBootstraper.execute(RunnerBootstraper.java:139)
at org.codehaus.mojo.sonar.SonarMojo.execute(SonarMojo.java:132)
at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:132)
at org.apache.maven.lifecycle.internal.MojoExecutor.execute(MojoExecutor.java:208)
... 19 more
Caused by: org.sonar.api.utils.SonarException: Fail to decorate 'org.sonar.api.resources.File#7d30e345[key=src/main/java/com/mycompany/EquityAccountingHandler.java,path=src/main/java/com/mycompany/EquityAccountingHandler.java,filename=EquityAccountingHandler.java,language=Java]'
at org.sonar.batch.phases.DecoratorsExecutor.executeDecorator(DecoratorsExecutor.java:104)
at org.sonar.batch.phases.DecoratorsExecutor.decorateResource(DecoratorsExecutor.java:87)
at org.sonar.batch.phases.DecoratorsExecutor.decorateResource(DecoratorsExecutor.java:79)
at org.sonar.batch.phases.DecoratorsExecutor.decorateResource(DecoratorsExecutor.java:79)
at org.sonar.batch.phases.DecoratorsExecutor.execute(DecoratorsExecutor.java:71)
at org.sonar.batch.phases.DatabaseModePhaseExecutor.execute(DatabaseModePhaseExecutor.java:127)
at org.sonar.batch.scan.ModuleScanContainer.doAfterStart(ModuleScanContainer.java:264)
at org.sonar.api.platform.ComponentContainer.startComponents(ComponentContainer.java:92)
at org.sonar.api.platform.ComponentContainer.execute(ComponentContainer.java:77)
at org.sonar.batch.scan.ProjectScanContainer.scan(ProjectScanContainer.java:235)
at org.sonar.batch.scan.ProjectScanContainer.scanRecursively(ProjectScanContainer.java:230)
at org.sonar.batch.scan.ProjectScanContainer.scanRecursively(ProjectScanContainer.java:228)
at org.sonar.batch.scan.ProjectScanContainer.doAfterStart(ProjectScanContainer.java:220)
at org.sonar.api.platform.ComponentContainer.startComponents(ComponentContainer.java:92)
at org.sonar.api.platform.ComponentContainer.execute(ComponentContainer.java:77)
at org.sonar.batch.scan.ScanTask.scan(ScanTask.java:57)
at org.sonar.batch.scan.ScanTask.execute(ScanTask.java:45)
at org.sonar.batch.bootstrap.TaskContainer.doAfterStart(TaskContainer.java:135)
at org.sonar.api.platform.ComponentContainer.startComponents(ComponentContainer.java:92)
at org.sonar.api.platform.ComponentContainer.execute(ComponentContainer.java:77)
at org.sonar.batch.bootstrap.GlobalContainer.executeTask(GlobalContainer.java:158)
at org.sonar.batch.bootstrapper.Batch.executeTask(Batch.java:95)
at org.sonar.batch.bootstrapper.Batch.execute(Batch.java:67)
at org.sonar.runner.batch.IsolatedLauncher.execute(IsolatedLauncher.java:48)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at org.sonar.runner.impl.BatchLauncher$1.delegateExecution(BatchLauncher.java:87)
at org.sonar.runner.impl.BatchLauncher$1.run(BatchLauncher.java:75)
at java.security.AccessController.doPrivileged(Native Method)
at org.sonar.runner.impl.BatchLauncher.doExecute(BatchLauncher.java:69)
at org.sonar.runner.impl.BatchLauncher.execute(BatchLauncher.java:50)
at org.sonar.runner.api.EmbeddedRunner.doExecute(EmbeddedRunner.java:102)
at org.sonar.runner.api.Runner.execute(Runner.java:100)
at org.codehaus.mojo.sonar.bootstrap.RunnerBootstraper.execute(RunnerBootstraper.java:135)
... 22 more
Caused by: java.lang.ArrayIndexOutOfBoundsException: 489
at org.sonar.batch.issue.tracking.FileHashes.getHash(FileHashes.java:89)
at org.sonar.batch.issue.tracking.IssueTracking.setChecksumOnNewIssues(IssueTracking.java:66)
at org.sonar.batch.issue.tracking.IssueTracking.track(IssueTracking.java:51)
at org.sonar.batch.issue.tracking.IssueTrackingDecorator.doDecorate(IssueTrackingDecorator.java:139)
at org.sonar.batch.issue.tracking.IssueTrackingDecorator.decorate(IssueTrackingDecorator.java:113)
at org.sonar.batch.phases.DecoratorsExecutor.executeDecorator(DecoratorsExecutor.java:96)
... 57 more
Any idea what happened?
EDIT:
I removed new rule checkstyle:com.puppycrawl.tools.checkstyle.checks.javadoc.SummaryJavadocCheck brought by checkstyle 2.3 plugin version. The analysis works correctly now.
The issue is due to some Checkstyle rules. If you remove them, this solves the problem.
For further reference: http://sonarqube.15.x6.nabble.com/ArrayIndexOutOfBoundsException-while-decorating-Java-file-td5034646.html
We have a big maven project which compiles just fine on linux(ubuntu) machines.
We are using JDK 1.7.0_71
However, trying to build it(mvn clean install) on osx 10.10.1 on some modules in the project, maven fails with the following exception message:
any ideas??
[ERROR] FATAL ERROR
[INFO] ------------------------------------------------------------------------
[INFO] 9728
[INFO] ------------------------------------------------------------------------
[INFO] Trace
java.lang.ArrayIndexOutOfBoundsException: 9728
at hidden.org.codehaus.plexus.util.xml.pull.MXParser.parsePI(MXParser.java:2470)
at hidden.org.codehaus.plexus.util.xml.pull.MXParser.parseEpilog(MXParser.java:1575)
at hidden.org.codehaus.plexus.util.xml.pull.MXParser.nextImpl(MXParser.java:1405)
at hidden.org.codehaus.plexus.util.xml.pull.MXParser.next(MXParser.java:1105)
at org.apache.maven.model.io.xpp3.MavenXpp3Reader.parseModel(MavenXpp3Reader.java:2133)
at org.apache.maven.model.io.xpp3.MavenXpp3Reader.read(MavenXpp3Reader.java:3912)
at org.apache.maven.project.DefaultMavenProjectBuilder.readModel(DefaultMavenProjectBuilder.java:1606)
at org.apache.maven.project.DefaultMavenProjectBuilder.readModel(DefaultMavenProjectBuilder.java:1571)
at org.apache.maven.project.DefaultMavenProjectBuilder.findModelFromRepository(DefaultMavenProjectBuilder.java:562)
at org.apache.maven.project.DefaultMavenProjectBuilder.buildFromRepository(DefaultMavenProjectBuilder.java:251)
at org.apache.maven.project.artifact.MavenMetadataSource.retrieveRelocatedProject(MavenMetadataSource.java:163)
at org.apache.maven.project.artifact.MavenMetadataSource.retrieveRelocatedArtifact(MavenMetadataSource.java:94)
at org.apache.maven.artifact.resolver.DefaultArtifactCollector.recurse(DefaultArtifactCollector.java:387)
at org.apache.maven.artifact.resolver.DefaultArtifactCollector.recurse(DefaultArtifactCollector.java:435)
at org.apache.maven.artifact.resolver.DefaultArtifactCollector.collect(DefaultArtifactCollector.java:74)
at org.apache.maven.artifact.resolver.DefaultArtifactResolver.resolveTransitively(DefaultArtifactResolver.java:316)
at org.apache.maven.artifact.resolver.DefaultArtifactResolver.resolveTransitively(DefaultArtifactResolver.java:304)
at org.apache.maven.plugin.DefaultPluginManager.resolveTransitiveDependencies(DefaultPluginManager.java:1499)
at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:442)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:694)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle(DefaultLifecycleExecutor.java:556)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:535)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:387)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:348)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:180)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:362)
at org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:60)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:606)
at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
I am following the following steps:
git clone http://git.eclipse.org/gitroot/paho/org.eclipse.paho.mqtt.java.git
cd org.eclipse.paho.mqtt.java.git
mvn package -DskipTests
This step result in:
[INFO] Scanning for projects...
[INFO] ------------------------------------------------------------------------
[ERROR] FATAL ERROR
[INFO] ------------------------------------------------------------------------
[INFO] Error building POM (may not be this project's POM).
Project ID: org.eclipse.paho:java-parent
Reason: Cannot find layout implementation corresponding to: 'p2' for remote repository with id: 'eclipse-kepler'. for project org.eclipse.paho:java-parent
[INFO] ------------------------------------------------------------------------
[INFO] Trace
org.apache.maven.reactor.MavenExecutionException: Cannot find layout implementation corresponding to: 'p2' for remote repository with id: 'eclipse-kepler'. for project org.eclipse.paho:java-parent
at org.apache.maven.DefaultMaven.getProjects(DefaultMaven.java:404)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:272)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:362)
at org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:60)
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:483)
at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
Caused by: org.apache.maven.project.ProjectBuildingException: Cannot find layout implementation corresponding to: 'p2' for remote repository with id: 'eclipse-kepler'. for project org.eclipse.paho:java-parent
at org.apache.maven.project.DefaultMavenProjectBuilder.buildArtifactRepositories(DefaultMavenProjectBuilder.java:949)
at org.apache.maven.project.DefaultMavenProjectBuilder.assembleLineage(DefaultMavenProjectBuilder.java:1206)
at org.apache.maven.project.DefaultMavenProjectBuilder.buildInternal(DefaultMavenProjectBuilder.java:823)
at org.apache.maven.project.DefaultMavenProjectBuilder.buildFromSourceFileInternal(DefaultMavenProjectBuilder.java:508)
at org.apache.maven.project.DefaultMavenProjectBuilder.build(DefaultMavenProjectBuilder.java:200)
at org.apache.maven.DefaultMaven.getProject(DefaultMaven.java:604)
at org.apache.maven.DefaultMaven.collectProjects(DefaultMaven.java:487)
at org.apache.maven.DefaultMaven.getProjects(DefaultMaven.java:391)
... 12 more
Caused by: org.apache.maven.artifact.InvalidRepositoryException: Cannot find layout implementation corresponding to: 'p2' for remote repository with id: 'eclipse-kepler'.
at org.apache.maven.project.ProjectUtils.getRepositoryLayout(ProjectUtils.java:157)
at org.apache.maven.project.ProjectUtils.buildArtifactRepository(ProjectUtils.java:110)
at org.apache.maven.project.ProjectUtils.buildArtifactRepositories(ProjectUtils.java:56)
at org.apache.maven.project.DefaultMavenProjectBuilder.buildArtifactRepositories(DefaultMavenProjectBuilder.java:942)
... 19 more
Caused by: org.codehaus.plexus.component.repository.exception.ComponentLookupException: Component descriptor cannot be found in the component repository: org.apache.maven.artifact.repository.layout.ArtifactRepositoryLayoutp2.
at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:323)
at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:440)
at org.apache.maven.project.ProjectUtils.getRepositoryLayout(ProjectUtils.java:153)
... 22 more
[INFO] ------------------------------------------------------------------------
[INFO] Total time: < 1 second
[INFO] Finished at: Sat Nov 22 11:37:37 CET 2014
[INFO] Final Memory: 2M/136M
[INFO] ------------------------------------------------------------------------
If remove 'eclipse-kepler' reposiroty in pom.xml get other type of errors.
+ Error stacktraces are turned on.
[INFO] Scanning for projects...
[INFO] Reactor build order:
[INFO] Eclipse Paho
[INFO] Unnamed - org.eclipse.paho:org.eclipse.paho.client.mqttv3:eclipse-plugin:1.0.1
[INFO] Unnamed - org.eclipse.paho:org.eclipse.paho.client.mqttv3.test:jar:1.0.1
[INFO] Unnamed - org.eclipse.paho:org.eclipse.paho.client.eclipse.feature:eclipse-feature:1.0.1
[INFO] Unnamed - org.eclipse.paho:org.eclipse.paho.client.eclipse.view:eclipse-plugin:1.0.1
[INFO] Paho P2 Repository
[INFO] Unnamed - org.eclipse.paho:org.eclipse.paho.mqtt.utility:jar:1.0.1
[INFO] Unnamed - org.eclipse.paho:org.eclipse.paho.ui:pom:1.0.1
[INFO] Unnamed - org.eclipse.paho:org.eclipse.paho.ui.core:eclipse-plugin:1.0.1
[INFO] Unnamed - org.eclipse.paho:org.eclipse.paho.ui.app:eclipse-repository:1.0.1
[INFO] Unnamed - org.eclipse.paho:org.eclipse.paho.ui.plugin:pom:1.0.1
[INFO] Eclipse Paho - MQTT Android Service
[INFO] Unnamed - org.eclipse.paho:org.eclipse.paho.android.service:jar:1.0.1
[INFO] ------------------------------------------------------------------------
[INFO] Building Eclipse Paho
[INFO] task-segment: [package]
[INFO] ------------------------------------------------------------------------
[INFO] [site:attach-descriptor {execution: default-attach-descriptor}]
[INFO] ------------------------------------------------------------------------
[INFO] Building Unnamed - org.eclipse.paho:org.eclipse.paho.client.mqttv3:eclipse-plugin:1.0.1
[INFO] task-segment: [package]
[INFO] ------------------------------------------------------------------------
[INFO] ------------------------------------------------------------------------
[ERROR] BUILD ERROR
[INFO] ------------------------------------------------------------------------
[INFO] Internal error in the plugin manager executing goal 'org.eclipse.tycho:tycho-packaging-plugin:0.20.0:build-qualifier': Unable to find the mojo 'build-qualifier' (or one of its required components) in the plugin 'org.eclipse.tycho:tycho-packaging-plugin'
Component descriptor cannot be found in the component repository: org.codehaus.plexus.logging.Logger.
[INFO] ------------------------------------------------------------------------
[INFO] Trace
org.apache.maven.lifecycle.LifecycleExecutionException: Internal error in the plugin manager executing goal 'org.eclipse.tycho:tycho-packaging-plugin:0.20.0:build-qualifier': Unable to find the mojo 'build-qualifier' (or one of its required components) in the plugin 'org.eclipse.tycho:tycho-packaging-plugin'
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:698)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalWithLifecycle(DefaultLifecycleExecutor.java:556)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:535)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:387)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:348)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:180)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:362)
at org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:60)
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:483)
at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
Caused by: org.apache.maven.plugin.PluginManagerException: Unable to find the mojo 'build-qualifier' (or one of its required components) in the plugin 'org.eclipse.tycho:tycho-packaging-plugin'
at org.apache.maven.plugin.DefaultPluginManager.getConfiguredMojo(DefaultPluginManager.java:674)
at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:468)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:694)
... 17 more
Caused by: org.codehaus.plexus.component.repository.exception.ComponentLookupException: Unable to lookup component 'org.apache.maven.plugin.Mojoorg.eclipse.tycho:tycho-packaging-plugin:0.20.0:build-qualifier', it could not be started
at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:339)
at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:440)
at org.apache.maven.plugin.DefaultPluginManager.getConfiguredMojo(DefaultPluginManager.java:652)
... 19 more
Caused by: org.codehaus.plexus.component.repository.exception.ComponentLifecycleException: Error starting component
at org.codehaus.plexus.component.manager.AbstractComponentManager.startComponentLifecycle(AbstractComponentManager.java:109)
at org.codehaus.plexus.component.manager.AbstractComponentManager.createComponentInstance(AbstractComponentManager.java:95)
at org.codehaus.plexus.component.manager.PerLookupComponentManager.getComponent(PerLookupComponentManager.java:48)
at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:331)
... 21 more
Caused by: org.codehaus.plexus.personality.plexus.lifecycle.phase.PhaseExecutionException: Error composing component
at org.codehaus.plexus.personality.plexus.lifecycle.phase.CompositionPhase.execute(CompositionPhase.java:33)
at org.codehaus.plexus.lifecycle.AbstractLifecycleHandler.start(AbstractLifecycleHandler.java:101)
at org.codehaus.plexus.component.manager.AbstractComponentManager.startComponentLifecycle(AbstractComponentManager.java:105)
... 24 more
Caused by: org.codehaus.plexus.component.composition.CompositionException: Composition failed of field projectTypes in object of type org.eclipse.tycho.buildversion.BuildQualifierMojo because the requirement ComponentRequirement{role='org.eclipse.tycho.core.TychoProject', roleHint='null', fieldName='projectTypes'} was missing
at org.codehaus.plexus.component.composition.FieldComponentComposer.assignRequirementToField(FieldComponentComposer.java:154)
at org.codehaus.plexus.component.composition.FieldComponentComposer.assembleComponent(FieldComponentComposer.java:73)
at org.codehaus.plexus.component.composition.DefaultComponentComposerManager.assembleComponent(DefaultComponentComposerManager.java:68)
at org.codehaus.plexus.DefaultPlexusContainer.composeComponent(DefaultPlexusContainer.java:1486)
at org.codehaus.plexus.personality.plexus.lifecycle.phase.CompositionPhase.execute(CompositionPhase.java:29)
... 26 more
Caused by: org.codehaus.plexus.component.repository.exception.ComponentLookupException: Unable to lookup component 'org.eclipse.tycho.core.TychoProjecteclipse-test-plugin', it could not be started
at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:339)
at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:440)
at org.codehaus.plexus.DefaultPlexusContainer.lookupMap(DefaultPlexusContainer.java:390)
at org.codehaus.plexus.component.composition.FieldComponentComposer.assignRequirementToField(FieldComponentComposer.java:103)
... 30 more
Caused by: org.codehaus.plexus.component.repository.exception.ComponentLifecycleException: Error starting component
at org.codehaus.plexus.component.manager.AbstractComponentManager.startComponentLifecycle(AbstractComponentManager.java:109)
at org.codehaus.plexus.component.manager.AbstractComponentManager.createComponentInstance(AbstractComponentManager.java:95)
at org.codehaus.plexus.component.manager.ClassicSingletonComponentManager.getComponent(ClassicSingletonComponentManager.java:92)
at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:331)
... 33 more
Caused by: org.codehaus.plexus.personality.plexus.lifecycle.phase.PhaseExecutionException: Error composing component
at org.codehaus.plexus.personality.plexus.lifecycle.phase.CompositionPhase.execute(CompositionPhase.java:33)
at org.codehaus.plexus.lifecycle.AbstractLifecycleHandler.start(AbstractLifecycleHandler.java:101)
at org.codehaus.plexus.component.manager.AbstractComponentManager.startComponentLifecycle(AbstractComponentManager.java:105)
... 36 more
Caused by: org.codehaus.plexus.component.composition.CompositionException: Composition failed of field resolver in object of type org.eclipse.tycho.core.osgitools.OsgiTestBundleProject because the requirement ComponentRequirement{role='org.eclipse.tycho.core.osgitools.EquinoxResolver', roleHint='null', fieldName='resolver'} was missing
at org.codehaus.plexus.component.composition.FieldComponentComposer.assignRequirementToField(FieldComponentComposer.java:154)
at org.codehaus.plexus.component.composition.FieldComponentComposer.assembleComponent(FieldComponentComposer.java:73)
at org.codehaus.plexus.component.composition.DefaultComponentComposerManager.assembleComponent(DefaultComponentComposerManager.java:68)
at org.codehaus.plexus.DefaultPlexusContainer.composeComponent(DefaultPlexusContainer.java:1486)
at org.codehaus.plexus.personality.plexus.lifecycle.phase.CompositionPhase.execute(CompositionPhase.java:29)
... 38 more
Caused by: org.codehaus.plexus.component.repository.exception.ComponentLookupException: Unable to lookup component 'org.eclipse.tycho.core.osgitools.EquinoxResolver', it could not be started
at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:339)
at org.codehaus.plexus.component.composition.FieldComponentComposer.assignRequirementToField(FieldComponentComposer.java:129)
... 42 more
Caused by: org.codehaus.plexus.component.repository.exception.ComponentLifecycleException: Error starting component
at org.codehaus.plexus.component.manager.AbstractComponentManager.startComponentLifecycle(AbstractComponentManager.java:109)
at org.codehaus.plexus.component.manager.AbstractComponentManager.createComponentInstance(AbstractComponentManager.java:95)
at org.codehaus.plexus.component.manager.ClassicSingletonComponentManager.getComponent(ClassicSingletonComponentManager.java:92)
at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:331)
... 43 more
Caused by: org.codehaus.plexus.personality.plexus.lifecycle.phase.PhaseExecutionException: Error composing component
at org.codehaus.plexus.personality.plexus.lifecycle.phase.CompositionPhase.execute(CompositionPhase.java:33)
at org.codehaus.plexus.lifecycle.AbstractLifecycleHandler.start(AbstractLifecycleHandler.java:101)
at org.codehaus.plexus.component.manager.AbstractComponentManager.startComponentLifecycle(AbstractComponentManager.java:105)
... 46 more
Caused by: org.codehaus.plexus.component.composition.CompositionException: Composition failed of field logger in object of type org.eclipse.tycho.core.osgitools.EquinoxResolver because the requirement ComponentRequirement{role='org.codehaus.plexus.logging.Logger', roleHint='null', fieldName='logger'} was missing
at org.codehaus.plexus.component.composition.FieldComponentComposer.assignRequirementToField(FieldComponentComposer.java:154)
at org.codehaus.plexus.component.composition.FieldComponentComposer.assembleComponent(FieldComponentComposer.java:73)
at org.codehaus.plexus.component.composition.DefaultComponentComposerManager.assembleComponent(DefaultComponentComposerManager.java:68)
at org.codehaus.plexus.DefaultPlexusContainer.composeComponent(DefaultPlexusContainer.java:1486)
at org.codehaus.plexus.personality.plexus.lifecycle.phase.CompositionPhase.execute(CompositionPhase.java:29)
... 48 more
Caused by: org.codehaus.plexus.component.repository.exception.ComponentLookupException: Component descriptor cannot be found in the component repository: org.codehaus.plexus.logging.Logger.
at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:323)
at org.codehaus.plexus.DefaultPlexusContainer.lookup(DefaultPlexusContainer.java:312)
at org.codehaus.plexus.component.composition.FieldComponentComposer.assignRequirementToField(FieldComponentComposer.java:129)
... 52 more
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 1 second
[INFO] Finished at: Sat Nov 22 11:45:51 CET 2014
[INFO] Final Memory: 20M/265M
[INFO] ------------------------------------------------------------------------
Can somebody help me?
You can try to upgrade maven from 2.x to 3.x.
Note that on Ubuntu, the 'maven' package is newer than the 'maven2' package. The following commands fixed it for me:
sudo apt-get remove maven2
sudo apt-get install maven
I was using Maven 2.2.1 - successfully downloaded repository on my systems when I had Java 1.6. BUT when I moved to Java 1.7, I am not able to download it again.
NOW I have rollback to java 1.6 but still I am not able to download maven. [NOTE : I HAVE ALSO TRIED IT WITH MAVEN 3.0.3 AND FACING SAME ISSUE]
I am getting following Build Error
System has set JAVA_HOME of Java Home directory
[ERROR] BUILD ERROR
[INFO] ----------------------------------------------------------------------
[INFO] Internal error in the plugin manager executing goal 'com.sun.enterprise:osgiversion-maven-plugin:0.4.11:compute-osgi-version': Unable to load the mojo 'com.sun.enterprise:osgiversion-maven-plugin:0.4.11:compute-osgi-version' in the plugin 'com.sun.enterprise:osgiversion-maven-plugin'. A required class is missing: Lorg/apache/maven/shared/osgi/Maven2OsgiConverter;
org.apache.maven.shared.osgi.Maven2OsgiConverter
[INFO] ----------------------------------------------------------------------
[INFO] Trace
org.apache.maven.lifecycle.LifecycleExecutionExcep tion: Internal error in the plugin manager executing goal 'com.sun.enterprise:osgiversion-maven-plugin:0.4.11:compute-osgi-version': Unable to load the mojo 'com.sun.enterprise:osgiversion-maven-plugin:0.4.11:compute-osgi-version' in the plugin 'com.sun.enterprise:osgiversion-maven-plugin'. A required class is missing: Lorg/apache/maven/shared/osgi/Maven2OsgiConverter;
at org.apache.maven.lifecycle.DefaultLifecycleExecuto r.executeGoals(DefaultLifecycleExecutor.java:698)
at org.apache.maven.lifecycle.DefaultLifecycleExecuto r.executeGoalWithLifecycle(DefaultLifecycleExecuto r.java:556)
at org.apache.maven.lifecycle.DefaultLifecycleExecuto r.executeGoal(DefaultLifecycleExecutor.java:535)
at org.apache.maven.lifecycle.DefaultLifecycleExecuto r.executeGoalAndHandleFailures(DefaultLifecycleExe cutor.java:387)
at org.apache.maven.lifecycle.DefaultLifecycleExecuto r.executeTaskSegments(DefaultLifecycleExecutor.jav a:348)
at org.apache.maven.lifecycle.DefaultLifecycleExecuto r.execute(DefaultLifecycleExecutor.java:180)
at org.apache.maven.DefaultMaven.doExecute(DefaultMav en.java:328)
at org.apache.maven.DefaultMaven.execute(DefaultMaven .java:138)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:3 62)
at org.apache.maven.cli.compat.CompatibleMain.main(Co mpatibleMain.java:60)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Nativ e Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(Native MethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(De legatingMethodAccessorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:597)
at org.codehaus.classworlds.Launcher.launchEnhanced(L auncher.java:315)
at org.codehaus.classworlds.Launcher.launch(Launcher. java:255)
at org.codehaus.classworlds.Launcher.mainWithExitCode (Launcher.java:430)
at org.codehaus.classworlds.Launcher.main(Launcher.ja va:375)
Caused by: org.apache.maven.plugin.PluginManagerException: Unable to load the mojo 'com.sun.enterprise:osgiversion-maven-plugin:0.4.11:compute-osgi-version' in the plugin 'com.sun.enterprise:osgiversion-maven-plugin'. A required class is missing: Lorg/apache/maven/shared/osgi/Maven2OsgiConverter;
at org.apache.maven.plugin.DefaultPluginManager.getCo nfiguredMojo(DefaultPluginManager.java:679)
at org.apache.maven.plugin.DefaultPluginManager.execu teMojo(DefaultPluginManager.java:468)
at org.apache.maven.lifecycle.DefaultLifecycleExecuto r.executeGoals(DefaultLifecycleExecutor.java:694)
... 17 more
Caused by: java.lang.NoClassDefFoundError: Lorg/apache/maven/shared/osgi/Maven2OsgiConverter;
at java.lang.Class.getDeclaredFields0(Native Method)
at java.lang.Class.privateGetDeclaredFields(Class.jav a:2291)
at java.lang.Class.getDeclaredField(Class.java:1880)
at hidden.org.codehaus.plexus.util.ReflectionUtils.ge tFieldByNameIncludingSuperclasses(ReflectionUtils. java:47)
at org.codehaus.plexus.component.composition.FieldCom ponentComposer.getFieldByName(FieldComponentCompos er.java:212)
at org.codehaus.plexus.component.composition.FieldCom ponentComposer.findMatchingField(FieldComponentCom poser.java:171)
at org.codehaus.plexus.component.composition.FieldCom ponentComposer.assembleComponent(FieldComponentCom poser.java:62)
at org.codehaus.plexus.component.composition.DefaultC omponentComposerManager.assembleComponent(DefaultC omponentComposerManager.java:68)
at org.codehaus.plexus.DefaultPlexusContainer.compose Component(DefaultPlexusContainer.java:1486)
at org.codehaus.plexus.personality.plexus.lifecycle.p hase.CompositionPhase.execute(CompositionPhase.jav a:29)
at org.codehaus.plexus.lifecycle.AbstractLifecycleHan dler.start(AbstractLifecycleHandler.java:101)
at org.codehaus.plexus.component.manager.AbstractComp onentManager.startComponentLifecycle(AbstractCompo nentManager.java:105)
at org.codehaus.plexus.component.manager.AbstractComp onentManager.createComponentInstance(AbstractCompo nentManager.java:95)
at org.codehaus.plexus.component.manager.PerLookupCom ponentManager.getComponent(PerLookupComponentManag er.java:48)
at org.codehaus.plexus.DefaultPlexusContainer.lookup( DefaultPlexusContainer.java:331)
at org.codehaus.plexus.DefaultPlexusContainer.lookup( DefaultPlexusContainer.java:440)
at org.apache.maven.plugin.DefaultPluginManager.getCo nfiguredMojo(DefaultPluginManager.java:652)
... 19 more
Caused by: java.lang.ClassNotFoundException: org.apache.maven.shared.osgi.Maven2OsgiConverter
at java.net.URLClassLoader$1.run(URLClassLoader.java: 200)
at java.security.AccessController.doPrivileged(Native Method)
at java.net.URLClassLoader.findClass(URLClassLoader.j ava:188)
at java.lang.ClassLoader.loadClass(ClassLoader.java:3 07)
at org.codehaus.classworlds.RealmClassLoader.loadClas sDirect(RealmClassLoader.java:195)
at org.codehaus.classworlds.DefaultClassRealm.loadCla ss(DefaultClassRealm.java:255)
at org.codehaus.classworlds.DefaultClassRealm.loadCla ss(DefaultClassRealm.java:274)
at org.codehaus.classworlds.RealmClassLoader.loadClas s(RealmClassLoader.java:214)
at java.lang.ClassLoader.loadClass(ClassLoader.java:2 52)
at java.lang.ClassLoader.loadClassInternal(ClassLoade r.java:320)
... 36 more
[INFO] ----------------------------------------------------------------------
[INFO] Total time: 29 minutes 36 seconds
[INFO] Finished at: Fri Dec 21 13:07:49 IST 2012
[INFO] Final Memory: 13M/23M
[INFO] ----------------------------------------------------------------------
Can anybody please let me know what settings are changed that I need to update ?
Thanks
I use maven site plugin version 2.2 and XStream version 1.3.1. When I do,
mvn site:stage -DstagingDirectory=C:\
It always fails with
[INFO] Trace
com.thoughtworks.xstream.XStream$InitializationException: Could not instatiate converter : com.thoughtworks.xstream.converters.enums.EnumSetConverter : null
at com.thoughtworks.xstream.XStream.dynamicallyRegisterConverter(XStream.java:651)
at com.thoughtworks.xstream.XStream.setupConverters(XStream.java:620)
at com.thoughtworks.xstream.XStream.<init>(XStream.java:371)
at com.thoughtworks.xstream.XStream.<init>(XStream.java:316)
at org.codehaus.mojo.dashboard.report.plugin.DashBoardUtils.saveXMLDashBoardReport(DashBoardUtils.java:995)
at org.codehaus.mojo.dashboard.report.plugin.DashBoardReportMojo.executeReport(DashBoardReportMojo.java:282)
at org.apache.maven.reporting.AbstractMavenReport.generate(AbstractMavenReport.java:98)
at org.apache.maven.plugins.site.ReportDocumentRenderer.renderDocument(ReportDocumentRenderer.java:161)
at org.apache.maven.doxia.siterenderer.DefaultSiteRenderer.renderModule(DefaultSiteRenderer.java:330)
at org.apache.maven.doxia.siterenderer.DefaultSiteRenderer.render(DefaultSiteRenderer.java:134)
at org.apache.maven.plugins.site.SiteMojo.renderLocale(SiteMojo.java:154)
at org.apache.maven.plugins.site.SiteMojo.execute(SiteMojo.java:118)
at org.apache.maven.plugins.site.SiteStageMojo.execute(SiteStageMojo.java:112)
at org.apache.maven.plugin.DefaultPluginManager.executeMojo(DefaultPluginManager.java:490)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoals(DefaultLifecycleExecutor.java:694)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeStandaloneGoal(DefaultLifecycleExecutor.java:569)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoal(DefaultLifecycleExecutor.java:539)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeGoalAndHandleFailures(DefaultLifecycleExecutor.java:387)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.executeTaskSegments(DefaultLifecycleExecutor.java:348)
at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:180)
at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:328)
at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:138)
at org.apache.maven.cli.MavenCli.main(MavenCli.java:362)
at org.apache.maven.cli.compat.CompatibleMain.main(CompatibleMain.java:60)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:37)
at java.lang.reflect.Method.invoke(Method.java:599)
at org.codehaus.classworlds.Launcher.launchEnhanced(Launcher.java:315)
at org.codehaus.classworlds.Launcher.launch(Launcher.java:255)
at org.codehaus.classworlds.Launcher.mainWithExitCode(Launcher.java:430)
at org.codehaus.classworlds.Launcher.main(Launcher.java:375)
Caused by: java.lang.reflect.InvocationTargetException
at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method)
at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:41)
at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:39)
at java.lang.reflect.Constructor.newInstance(Constructor.java:515)
at com.thoughtworks.xstream.XStream.dynamicallyRegisterConverter(XStream.java:644)
... 31 more
Caused by: java.lang.RuntimeException: Could not access java.util.EnumSet.elementType field
at com.thoughtworks.xstream.core.util.Fields.find(Fields.java:18)
at com.thoughtworks.xstream.converters.enums.EnumSetConverter.<init>(EnumSetConverter.java:31)
... 36 more
[INFO] ------------------------------------------------------------------------
[INFO] Total time: 25 seconds
[INFO] Finished at: Thu Oct 11 17:01:09 CDT 2012
[INFO] Final Memory: 118M/249M
[INFO] ------------------------------------------------------------------------
What I'm doing wrong here. I tried to use XStream version 1.2.2 without any luck
From exception that is Dashboard Maven Plugin that fails. Try using different version of that.