Details

    • Global Rank:
      13579

      Description

      Some p2 repositories (like http://community.polarion.com/projects/subversive/download/eclipse/2.0/weekly-site/, for example) do not return 404 (Not Found) for missing file, but return 300 (Multiple Choices) instead. This confuses Maven dependency and makes the build fail with exception like below

      [ERROR] Failed to execute goal on project workspace-plugin-repository: Unable to read local copy of metadata: Cannot read metadata from 'C:\Users\hudson\.m2\repository\org\sonatype\nexus\nexus-plugin-manager\1.4.2-SNAPSHOT\maven-metadata-subversive-connectors-weekly.xml': end tag name </ul> must be the same as start tag <li> from line 10 (position: TEXT seen ...</a> (common basename)\n</ul>... @11:6) 
        org.sonatype.nexus:nexus-plugin-manager:jar:1.4.2-SNAPSHOT
      
      Path to dependency: 
      	1) org.sonatype.m2e.nexus:workspace-plugin-repository:pom:pom:1.0.0-SNAPSHOT
      	2) org.sonatype.nexus:nexus-plugin-manager:jar:1.4.2-SNAPSHOT
      -> [Help 1]
      org.apache.maven.lifecycle.LifecycleExecutionException: Failed to execute goal on project workspace-plugin-repository: Unable to read local copy of metadata: Cannot read metadata from 'C:\Users\hudson\.m2\repository\org\sonatype\nexus\nexus-plugin-manager\1.4.2-SNAPSHOT\maven-metadata-subversive-connectors-weekly.xml': end tag name </ul> must be the same as start tag <li> from line 10 (position: TEXT seen ...</a> (common basename)\n</ul>... @11:6) 
        org.sonatype.nexus:nexus-plugin-manager:jar:1.4.2-SNAPSHOT
      
      Path to dependency: 
      	1) org.sonatype.m2e.nexus:workspace-plugin-repository:pom:pom:1.0.0-SNAPSHOT
      	2) org.sonatype.nexus:nexus-plugin-manager:jar:1.4.2-SNAPSHOT
      
      
      	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.resolveProjectDependencies(DefaultLifecycleExecutor.java:409)
      	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.execute(DefaultLifecycleExecutor.java:307)
      	at org.apache.maven.DefaultMaven.doExecute(DefaultMaven.java:247)
      	at org.apache.maven.DefaultMaven.execute(DefaultMaven.java:104)
      	at org.apache.maven.cli.MavenCli.execute(MavenCli.java:423)
      	at org.apache.maven.cli.MavenCli.doMain(MavenCli.java:158)
      	at org.apache.maven.cli.MavenCli.main(MavenCli.java:123)
      	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.plexus.classworlds.launcher.Launcher.launchEnhanced(Launcher.java:290)
      	at org.codehaus.plexus.classworlds.launcher.Launcher.launch(Launcher.java:230)
      	at org.codehaus.plexus.classworlds.launcher.Launcher.mainWithExitCode(Launcher.java:409)
      	at org.codehaus.plexus.classworlds.launcher.Launcher.main(Launcher.java:352)
      Caused by: org.apache.maven.artifact.resolver.ArtifactResolutionException: Unable to read local copy of metadata: Cannot read metadata from 'C:\Users\hudson\.m2\repository\org\sonatype\nexus\nexus-plugin-manager\1.4.2-SNAPSHOT\maven-metadata-subversive-connectors-weekly.xml': end tag name </ul> must be the same as start tag <li> from line 10 (position: TEXT seen ...</a> (common basename)\n</ul>... @11:6) 
        org.sonatype.nexus:nexus-plugin-manager:jar:1.4.2-SNAPSHOT
      
      Path to dependency: 
      	1) org.sonatype.m2e.nexus:workspace-plugin-repository:pom:pom:1.0.0-SNAPSHOT
      	2) org.sonatype.nexus:nexus-plugin-manager:jar:1.4.2-SNAPSHOT
      
      
      	at org.apache.maven.repository.legacy.resolver.transform.SnapshotTransformation.transformForResolve(SnapshotTransformation.java:82)
      	at org.apache.maven.repository.legacy.resolver.transform.DefaultArtifactTransformationManager.transformForResolve(DefaultArtifactTransformationManager.java:49)
      	at org.apache.maven.artifact.resolver.DefaultArtifactResolver.resolve(DefaultArtifactResolver.java:198)
      	at org.apache.maven.artifact.resolver.DefaultArtifactResolver.resolve(DefaultArtifactResolver.java:568)
      	at org.apache.maven.repository.legacy.LegacyRepositorySystem.resolve(LegacyRepositorySystem.java:325)
      	at org.apache.maven.DefaultProjectDependenciesResolver.resolve(DefaultProjectDependenciesResolver.java:152)
      	at org.apache.maven.DefaultProjectDependenciesResolver.resolve(DefaultProjectDependenciesResolver.java:66)
      	at org.apache.maven.lifecycle.DefaultLifecycleExecutor.resolveProjectDependencies(DefaultLifecycleExecutor.java:378)
      	... 14 more
      Caused by: org.apache.maven.artifact.repository.metadata.RepositoryMetadataResolutionException: Unable to read local copy of metadata: Cannot read metadata from 'C:\Users\hudson\.m2\repository\org\sonatype\nexus\nexus-plugin-manager\1.4.2-SNAPSHOT\maven-metadata-subversive-connectors-weekly.xml': end tag name </ul> must be the same as start tag <li> from line 10 (position: TEXT seen ...</a> (common basename)\n</ul>... @11:6) 
      	at org.apache.maven.artifact.repository.metadata.DefaultRepositoryMetadataManager.resolve(DefaultRepositoryMetadataManager.java:169)
      	at org.apache.maven.repository.legacy.resolver.transform.AbstractVersionTransformation.resolveVersion(AbstractVersionTransformation.java:88)
      	at org.apache.maven.repository.legacy.resolver.transform.SnapshotTransformation.transformForResolve(SnapshotTransformation.java:77)
      	... 21 more
      Caused by: org.apache.maven.artifact.repository.metadata.RepositoryMetadataReadException: Cannot read metadata from 'C:\Users\hudson\.m2\repository\org\sonatype\nexus\nexus-plugin-manager\1.4.2-SNAPSHOT\maven-metadata-subversive-connectors-weekly.xml': end tag name </ul> must be the same as start tag <li> from line 10 (position: TEXT seen ...</a> (common basename)\n</ul>... @11:6) 
      	at org.apache.maven.artifact.repository.metadata.DefaultRepositoryMetadataManager.readMetadata(DefaultRepositoryMetadataManager.java:421)
      	at org.apache.maven.artifact.repository.metadata.DefaultRepositoryMetadataManager.loadMetadata(DefaultRepositoryMetadataManager.java:376)
      	at org.apache.maven.artifact.repository.metadata.DefaultRepositoryMetadataManager.mergeMetadata(DefaultRepositoryMetadataManager.java:314)
      	at org.apache.maven.artifact.repository.metadata.DefaultRepositoryMetadataManager.resolve(DefaultRepositoryMetadataManager.java:161)
      	... 23 more
      Caused by: org.codehaus.plexus.util.xml.pull.XmlPullParserException: end tag name </ul> must be the same as start tag <li> from line 10 (position: TEXT seen ...</a> (common basename)\n</ul>... @11:6) 
      	at org.codehaus.plexus.util.xml.pull.MXParser.parseEndTag(MXParser.java:1708)
      	at org.codehaus.plexus.util.xml.pull.MXParser.nextImpl(MXParser.java:1143)
      	at org.codehaus.plexus.util.xml.pull.MXParser.next(MXParser.java:1105)
      	at org.apache.maven.artifact.repository.metadata.io.xpp3.MetadataXpp3Reader.parseMetadata(MetadataXpp3Reader.java:503)
      	at org.apache.maven.artifact.repository.metadata.io.xpp3.MetadataXpp3Reader.read(MetadataXpp3Reader.java:952)
      	at org.apache.maven.artifact.repository.metadata.DefaultRepositoryMetadataManager.readMetadata(DefaultRepositoryMetadataManager.java:409)
      	... 26 more
      [ERROR] 
      [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/ArtifactResolutionException
      [ERROR] 
      [ERROR] After correcting the problems, you can resume the build with the command
      [ERROR]   mvn <goals> -rf :workspace-plugin-repository
      Finished: FAILURE
      

        Activity

        Hide
        Benjamin Bentmann added a comment -

        Filled MNG-4498 on the Maven side for graceful handling of bad metadata.

        Show
        Benjamin Bentmann added a comment - Filled MNG-4498 on the Maven side for graceful handling of bad metadata.
        Hide
        Igor Fedorenko added a comment -

        Changed Tycho p2 repository layout implementation such that manen will never attempt resolving maven artifacts from p2 repositories.

        Show
        Igor Fedorenko added a comment - Changed Tycho p2 repository layout implementation such that manen will never attempt resolving maven artifacts from p2 repositories.

          People

          • Assignee:
            Igor Fedorenko
            Reporter:
            Igor Fedorenko
            Last Updated By:
            Brian Fox
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:
              Date of First Response: