org.restlet.resource.ResourceException: The server encountered an unexpected condition which prevented it from fulfilling the request

Sonatype JIRA | Rias A. Sherzad | 5 years ago
  1. 0

    I find it very odd that Nexus is trying to merge those two artifacts so I assume that must be a bug. This is what I see when Maven runs: {noformat}Downloading: http://repo.myserverdomain.com/content/groups/public/javax/mail/mail/maven-metadata.xml [WARNING] Could not transfer metadata javax.mail:mail/maven-metadata.xml from/to nexus (http://repo.myserverdomain.com/content/groups/public): Error transferring file: Server returned HTTP response code: 500 for URL: http://repo.myserverdomain.com/content/groups/public/javax/mail/mail/maven-metadata.xml{noformat} I'm not sure which information you need so here's the Stacktrace I see in Nexus' logfile: {noformat}org.restlet.resource.ResourceException: The server encountered an unexpected condition which prevented it from fulfilling the request at org.sonatype.nexus.rest.AbstractResourceStoreContentPlexusResource.handleException(AbstractResourceStoreContentPlexusResource.java:807) at org.sonatype.nexus.rest.AbstractResourceStoreContentPlexusResource.get(AbstractResourceStoreContentPlexusResource.java:161) at org.sonatype.plexus.rest.resource.RestletResource.represent(RestletResource.java:246) at org.sonatype.nexus.rest.NexusRestletResource.represent(NexusRestletResource.java:50) at org.restlet.resource.Resource.getRepresentation(Resource.java:302) at org.restlet.resource.Resource.handleGet(Resource.java:464) at org.restlet.Finder.handle(Finder.java:353) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Router.handle(Router.java:504) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Filter.doHandle(Filter.java:150) at org.sonatype.plexus.rest.RetargetableRestlet.doHandle(RetargetableRestlet.java:39) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Filter.doHandle(Filter.java:150) at com.noelios.restlet.StatusFilter.doHandle(StatusFilter.java:130) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at com.noelios.restlet.ChainHelper.handle(ChainHelper.java:124) at com.noelios.restlet.application.ApplicationHelper.handle(ApplicationHelper.java:112) at org.restlet.Application.handle(Application.java:341) at org.restlet.ext.wadl.WadlApplication.handle(WadlApplication.java:705) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Router.handle(Router.java:504) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at org.restlet.Router.handle(Router.java:504) at org.restlet.Filter.doHandle(Filter.java:150) at org.restlet.Filter.handle(Filter.java:195) at com.noelios.restlet.ChainHelper.handle(ChainHelper.java:124) at org.restlet.Component.handle(Component.java:673) at org.restlet.Server.handle(Server.java:331) at com.noelios.restlet.ServerHelper.handle(ServerHelper.java:68) at com.noelios.restlet.http.HttpServerHelper.handle(HttpServerHelper.java:147) at com.noelios.restlet.ext.servlet.ServerServlet.service(ServerServlet.java:881) at javax.servlet.http.HttpServlet.service(HttpServlet.java:717) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.shiro.web.servlet.ProxiedFilterChain.doFilter(ProxiedFilterChain.java:61) at org.apache.shiro.web.servlet.AdviceFilter.executeChain(AdviceFilter.java:108) at org.apache.shiro.web.servlet.AdviceFilter.doFilterInternal(AdviceFilter.java:137) at org.apache.shiro.web.servlet.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:81) at org.apache.shiro.web.servlet.ProxiedFilterChain.doFilter(ProxiedFilterChain.java:66) at org.apache.shiro.web.servlet.AdviceFilter.executeChain(AdviceFilter.java:108) at org.apache.shiro.web.servlet.AdviceFilter.doFilterInternal(AdviceFilter.java:137) at org.apache.shiro.web.servlet.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:81) at org.apache.shiro.web.servlet.ProxiedFilterChain.doFilter(ProxiedFilterChain.java:66) at org.apache.shiro.web.servlet.AbstractShiroFilter.executeChain(AbstractShiroFilter.java:359) at org.apache.shiro.web.servlet.AbstractShiroFilter$1.call(AbstractShiroFilter.java:275) at org.apache.shiro.subject.support.SubjectCallable.doCall(SubjectCallable.java:90) at org.apache.shiro.subject.support.SubjectCallable.call(SubjectCallable.java:83) at org.apache.shiro.subject.support.DelegatingSubject.execute(DelegatingSubject.java:344) at org.apache.shiro.web.servlet.AbstractShiroFilter.doFilterInternal(AbstractShiroFilter.java:272) at org.apache.shiro.web.servlet.OncePerRequestFilter.doFilter(OncePerRequestFilter.java:81) at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235) at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206) at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:233) at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:191) at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127) at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102) at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109) at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:291) at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:859) at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:602) at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:489) at java.lang.Thread.run(Thread.java:662) Caused by: org.sonatype.nexus.proxy.LocalStorageException: Got MetadataException during M2 metadata merging. at org.sonatype.nexus.proxy.maven.maven2.M2GroupRepository.doRetrieveMetadata(M2GroupRepository.java:324) at org.sonatype.nexus.proxy.maven.maven2.M2GroupRepository.doRetrieveItem(M2GroupRepository.java:141) at org.sonatype.nexus.proxy.repository.AbstractRepository.retrieveItem(AbstractRepository.java:770) at org.sonatype.nexus.proxy.repository.AbstractRepository.retrieveItem(AbstractRepository.java:575) at org.sonatype.nexus.proxy.router.DefaultRepositoryRouter.retrieveItem(DefaultRepositoryRouter.java:189) at org.sonatype.nexus.rest.AbstractResourceStoreContentPlexusResource.get(AbstractResourceStoreContentPlexusResource.java:143) ... 73 more Caused by: org.sonatype.nexus.proxy.maven.metadata.operations.MetadataException: Could not merge metadata with different groupId: 'javax.activation' and 'javax.mail' at org.sonatype.nexus.proxy.maven.metadata.operations.NexusMergeOperation.perform(NexusMergeOperation.java:124) at org.sonatype.nexus.proxy.maven.metadata.operations.MetadataBuilder.changeMetadata(MetadataBuilder.java:117) at org.sonatype.nexus.proxy.maven.maven2.M2GroupRepository.doRetrieveMetadata(M2GroupRepository.java:287) ... 78 more{noformat} I did see 1 or 2 similar (older) bugs here on JIRA but couldn't relate them to this one.

    Sonatype JIRA | 5 years ago | Rias A. Sherzad
    org.restlet.resource.ResourceException: The server encountered an unexpected condition which prevented it from fulfilling the request

    Root Cause Analysis

    1. org.sonatype.nexus.proxy.maven.metadata.operations.MetadataException

      Could not merge metadata with different groupId: 'javax.activation' and 'javax.mail'

      at org.sonatype.nexus.proxy.maven.metadata.operations.NexusMergeOperation.perform()
    2. ${project.groupId}:${project.artifactId}
      M2GroupRepository.doRetrieveMetadata
      1. org.sonatype.nexus.proxy.maven.metadata.operations.NexusMergeOperation.perform(NexusMergeOperation.java:124)
      2. org.sonatype.nexus.proxy.maven.metadata.operations.MetadataBuilder.changeMetadata(MetadataBuilder.java:117)
      3. org.sonatype.nexus.proxy.maven.maven2.M2GroupRepository.doRetrieveMetadata(M2GroupRepository.java:287)
      3 frames