When I try in 0.11.3-SNAPSHOT to get urlmap with root org.codehaus.plexus:plexus:1.0.5 I get NPE:
16:32:27,113 ERROR [org.apache.catalina.core.ContainerBase.[jboss.web].[default-host].[/aprox].[org.commonjava.aprox.bind.jaxrs.RESTApplication]] (http-/127.0.0.1:8080-1) JBWEB000236: Servlet.service() for servlet org.commonjava.aprox.bind.jaxrs.RESTApplication threw exception: org.jboss.resteasy.spi.UnhandledException: java.lang.NullPointerException
at org.jboss.resteasy.core.SynchronousDispatcher.handleApplicationException(SynchronousDispatcher.java:365) [resteasy-jaxrs-2.3.7.Final-redhat-2.jar:2.3.7.Final-redhat-2]
at org.jboss.resteasy.core.SynchronousDispatcher.handleException(SynchronousDispatcher.java:233) [resteasy-jaxrs-2.3.7.Final-redhat-2.jar:2.3.7.Final-redhat-2]
at org.jboss.resteasy.core.SynchronousDispatcher.handleInvokerException(SynchronousDispatcher.java:209) [resteasy-jaxrs-2.3.7.Final-redhat-2.jar:2.3.7.Final-redhat-2]
at org.jboss.resteasy.core.SynchronousDispatcher.getResponse(SynchronousDispatcher.java:557) [resteasy-jaxrs-2.3.7.Final-redhat-2.jar:2.3.7.Final-redhat-2]
at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:524) [resteasy-jaxrs-2.3.7.Final-redhat-2.jar:2.3.7.Final-redhat-2]
at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:126) [resteasy-jaxrs-2.3.7.Final-redhat-2.jar:2.3.7.Final-redhat-2]
at org.jboss.resteasy.plugins.server.servlet.ServletContainerDispatcher.service(ServletContainerDispatcher.java:208) [resteasy-jaxrs-2.3.7.Final-redhat-2.jar:2.3.7.Final-redhat-2]
at org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:55) [resteasy-jaxrs-2.3.7.Final-redhat-2.jar:2.3.7.Final-redhat-2]
at org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:50) [resteasy-jaxrs-2.3.7.Final-redhat-2.jar:2.3.7.Final-redhat-2]
at javax.servlet.http.HttpServlet.service(HttpServlet.java:847) [jboss-servlet-api_3.0_spec-1.0.2.Final-redhat-1.jar:1.0.2.Final-redhat-1]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:295) [jbossweb-7.2.2.Final-redhat-1.jar:7.2.2.Final-redhat-1]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214) [jbossweb-7.2.2.Final-redhat-1.jar:7.2.2.Final-redhat-1]
at org.commonjava.aprox.depgraph.jaxrs.filter.WorkspaceHandlerFilter.doFilter(WorkspaceHandlerFilter.java:79) [classes:]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:246) [jbossweb-7.2.2.Final-redhat-1.jar:7.2.2.Final-redhat-1]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214) [jbossweb-7.2.2.Final-redhat-1.jar:7.2.2.Final-redhat-1]
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230) [jbossweb-7.2.2.Final-redhat-1.jar:7.2.2.Final-redhat-1]
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:149) [jbossweb-7.2.2.Final-redhat-1.jar:7.2.2.Final-redhat-1]
at org.jboss.as.web.security.SecurityContextAssociationValve.invoke(SecurityContextAssociationValve.java:169) [jboss-as-web-7.3.0.Final-redhat-14.jar:7.3.0.Final-redhat-14]
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:145) [jbossweb-7.2.2.Final-redhat-1.jar:7.2.2.Final-redhat-1]
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:97) [jbossweb-7.2.2.Final-redhat-1.jar:7.2.2.Final-redhat-1]
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:102) [jbossweb-7.2.2.Final-redhat-1.jar:7.2.2.Final-redhat-1]
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:336) [jbossweb-7.2.2.Final-redhat-1.jar:7.2.2.Final-redhat-1]
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:856) [jbossweb-7.2.2.Final-redhat-1.jar:7.2.2.Final-redhat-1]
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:653) [jbossweb-7.2.2.Final-redhat-1.jar:7.2.2.Final-redhat-1]
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:920) [jbossweb-7.2.2.Final-redhat-1.jar:7.2.2.Final-redhat-1]
at java.lang.Thread.run(Thread.java:744) [rt.jar:1.7.0_51]
Caused by: java.lang.NullPointerException
at org.commonjava.maven.galley.maven.parse.XMLInfrastructure.getParentRef(XMLInfrastructure.java:386) [classes:]
at org.commonjava.maven.galley.maven.parse.XMLInfrastructure$Proxy$_$$_WeldClientProxy.getParentRef(XMLInfrastructure$Proxy$_$$_WeldClientProxy.java) [classes:]
at org.commonjava.maven.galley.maven.parse.MavenPomReader.read(MavenPomReader.java:83) [classes:]
at org.commonjava.maven.galley.maven.parse.MavenPomReader$Proxy$_$$_WeldClientProxy.read(MavenPomReader$Proxy$_$$_WeldClientProxy.java) [classes:]
at org.commonjava.aprox.depgraph.discover.AproxModelDiscoverer.discoverRelationships(AproxModelDiscoverer.java:98) [classes:]
at org.commonjava.aprox.depgraph.discover.AproxModelDiscoverer$Proxy$_$$_WeldClientProxy.discoverRelationships(AproxModelDiscoverer$Proxy$_$$_WeldClientProxy.java) [classes:]
at org.commonjava.aprox.depgraph.discover.AproxProjectGraphDiscoverer.discoverRelationships(AproxProjectGraphDiscoverer.java:134) [classes:]
at org.commonjava.aprox.depgraph.discover.AproxProjectGraphDiscoverer$Proxy$_$$_WeldClientProxy.discoverRelationships(AproxProjectGraphDiscoverer$Proxy$_$$_WeldClientProxy.java) [classes:]
at org.commonjava.maven.cartographer.ops.ResolveOps.resolve(ResolveOps.java:148) [classes:]
at org.commonjava.maven.cartographer.ops.ResolveOps.resolve(ResolveOps.java:368) [classes:]
at org.commonjava.maven.cartographer.ops.ResolveOps.resolveReferenceMap(ResolveOps.java:302) [classes:]
at org.commonjava.maven.cartographer.ops.ResolveOps.resolveRepositoryContents(ResolveOps.java:195) [classes:]
at org.commonjava.maven.cartographer.ops.ResolveOps$Proxy$_$$_WeldClientProxy.resolveRepositoryContents(ResolveOps$Proxy$_$$_WeldClientProxy.java) [classes:]
at org.commonjava.aprox.depgraph.rest.RepositoryController.resolveContents(RepositoryController.java:371) [classes:]
at org.commonjava.aprox.depgraph.rest.RepositoryController.getUrlMap(RepositoryController.java:120) [classes:]
at org.commonjava.aprox.depgraph.rest.RepositoryController.getUrlMap(RepositoryController.java:102) [classes:]
at org.commonjava.aprox.depgraph.rest.RepositoryController$Proxy$_$$_WeldClientProxy.getUrlMap(RepositoryController$Proxy$_$$_WeldClientProxy.java) [classes:]
at org.commonjava.aprox.depgraph.jaxrs.render.RepositoryResource.getUrlMap(RepositoryResource.java:60) [classes:]
at org.commonjava.aprox.depgraph.jaxrs.render.RepositoryResource$Proxy$_$$_WeldClientProxy.getUrlMap(RepositoryResource$Proxy$_$$_WeldClientProxy.java) [classes:]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [rt.jar:1.7.0_51]
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) [rt.jar:1.7.0_51]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) [rt.jar:1.7.0_51]
at java.lang.reflect.Method.invoke(Method.java:606) [rt.jar:1.7.0_51]
at org.jboss.resteasy.core.MethodInjectorImpl.invoke(MethodInjectorImpl.java:167) [resteasy-jaxrs-2.3.7.Final-redhat-2.jar:2.3.7.Final-redhat-2]
at org.jboss.resteasy.core.ResourceMethod.invokeOnTarget(ResourceMethod.java:269) [resteasy-jaxrs-2.3.7.Final-redhat-2.jar:2.3.7.Final-redhat-2]
at org.jboss.resteasy.core.ResourceMethod.invoke(ResourceMethod.java:227) [resteasy-jaxrs-2.3.7.Final-redhat-2.jar:2.3.7.Final-redhat-2]
at org.jboss.resteasy.core.ResourceMethod.invoke(ResourceMethod.java:216) [resteasy-jaxrs-2.3.7.Final-redhat-2.jar:2.3.7.Final-redhat-2]
at org.jboss.resteasy.core.SynchronousDispatcher.getResponse(SynchronousDispatcher.java:542) [resteasy-jaxrs-2.3.7.Final-redhat-2.jar:2.3.7.Final-redhat-2]
... 22 more
The actual cause is a non-defined XML entity in the pom. Although this is tested in Galley when I run it in AProx it behaves differently from the test. The root cause of this exception is TrensformerFactory implementation used when running in AProx on EAP 6.1/6.2. While when ran from tests, the used class is com.sun.org.apache.xalan.internal.xsltc.trax.TransformerFactoryImpl while when ran in AProx, the implementation is redirected.TransformerFactory (containing 2 org.apache.xalan.processor.TransformerFactoryImpl instances in fields actual and saxtual) resulting in transformer of class org.apache.xalan.transformer.TransformerIdentityImpl. The thrown exception is (note that I added logging of this exception at XMLInfrastructure:337, so the following line numbers are increased by one):
16:32:27,105 INFO [org.commonjava.maven.galley.maven.parse.XMLInfrastructure] (http-/127.0.0.1:8080-1) org.commonjava.maven.galley.maven.parse.GalleyMavenXMLException: Failed to parse: RepositoryLocation [repository:central]:org/codehaus/plexus/plexus/1.0.5/plexus-1.0.5.pom. STaX error: Can't transform a Source of type javax.xml.transform.stax.StAXSource.
Original DOM error: The entity "oslash" was referenced, but not declared.
at org.commonjava.maven.galley.maven.parse.XMLInfrastructure.fallbackParseDocument(XMLInfrastructure.java:281) [classes:]
at org.commonjava.maven.galley.maven.parse.XMLInfrastructure.parseDocument(XMLInfrastructure.java:250) [classes:]
at org.commonjava.maven.galley.maven.parse.XMLInfrastructure.parse(XMLInfrastructure.java:333) [classes:]
at org.commonjava.maven.galley.maven.parse.XMLInfrastructure$Proxy$_$$_WeldClientProxy.parse(XMLInfrastructure$Proxy$_$$_WeldClientProxy.java) [classes:]
at org.commonjava.maven.galley.maven.parse.MavenPomReader.getDocRef(MavenPomReader.java:196) [classes:]
at org.commonjava.maven.galley.maven.parse.MavenPomReader.read(MavenPomReader.java:80) [classes:]
at org.commonjava.maven.galley.maven.parse.MavenPomReader$Proxy$_$$_WeldClientProxy.read(MavenPomReader$Proxy$_$$_WeldClientProxy.java) [classes:]
at org.commonjava.aprox.depgraph.discover.AproxModelDiscoverer.discoverRelationships(AproxModelDiscoverer.java:98) [classes:]
at org.commonjava.aprox.depgraph.discover.AproxModelDiscoverer$Proxy$_$$_WeldClientProxy.discoverRelationships(AproxModelDiscoverer$Proxy$_$$_WeldClientProxy.java) [classes:]
at org.commonjava.aprox.depgraph.discover.AproxProjectGraphDiscoverer.discoverRelationships(AproxProjectGraphDiscoverer.java:134) [classes:]
at org.commonjava.aprox.depgraph.discover.AproxProjectGraphDiscoverer$Proxy$_$$_WeldClientProxy.discoverRelationships(AproxProjectGraphDiscoverer$Proxy$_$$_WeldClientProxy.java) [classes:]
at org.commonjava.maven.cartographer.ops.ResolveOps.resolve(ResolveOps.java:148) [classes:]
at org.commonjava.maven.cartographer.ops.ResolveOps.resolve(ResolveOps.java:368) [classes:]
at org.commonjava.maven.cartographer.ops.ResolveOps.resolveReferenceMap(ResolveOps.java:302) [classes:]
at org.commonjava.maven.cartographer.ops.ResolveOps.resolveRepositoryContents(ResolveOps.java:195) [classes:]
at org.commonjava.maven.cartographer.ops.ResolveOps$Proxy$_$$_WeldClientProxy.resolveRepositoryContents(ResolveOps$Proxy$_$$_WeldClientProxy.java) [classes:]
at org.commonjava.aprox.depgraph.rest.RepositoryController.resolveContents(RepositoryController.java:371) [classes:]
at org.commonjava.aprox.depgraph.rest.RepositoryController.getUrlMap(RepositoryController.java:120) [classes:]
at org.commonjava.aprox.depgraph.rest.RepositoryController.getUrlMap(RepositoryController.java:102) [classes:]
at org.commonjava.aprox.depgraph.rest.RepositoryController$Proxy$_$$_WeldClientProxy.getUrlMap(RepositoryController$Proxy$_$$_WeldClientProxy.java) [classes:]
at org.commonjava.aprox.depgraph.jaxrs.render.RepositoryResource.getUrlMap(RepositoryResource.java:60) [classes:]
at org.commonjava.aprox.depgraph.jaxrs.render.RepositoryResource$Proxy$_$$_WeldClientProxy.getUrlMap(RepositoryResource$Proxy$_$$_WeldClientProxy.java) [classes:]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [rt.jar:1.7.0_51]
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57) [rt.jar:1.7.0_51]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) [rt.jar:1.7.0_51]
at java.lang.reflect.Method.invoke(Method.java:606) [rt.jar:1.7.0_51]
at org.jboss.resteasy.core.MethodInjectorImpl.invoke(MethodInjectorImpl.java:167) [resteasy-jaxrs-2.3.7.Final-redhat-2.jar:2.3.7.Final-redhat-2]
at org.jboss.resteasy.core.ResourceMethod.invokeOnTarget(ResourceMethod.java:269) [resteasy-jaxrs-2.3.7.Final-redhat-2.jar:2.3.7.Final-redhat-2]
at org.jboss.resteasy.core.ResourceMethod.invoke(ResourceMethod.java:227) [resteasy-jaxrs-2.3.7.Final-redhat-2.jar:2.3.7.Final-redhat-2]
at org.jboss.resteasy.core.ResourceMethod.invoke(ResourceMethod.java:216) [resteasy-jaxrs-2.3.7.Final-redhat-2.jar:2.3.7.Final-redhat-2]
at org.jboss.resteasy.core.SynchronousDispatcher.getResponse(SynchronousDispatcher.java:542) [resteasy-jaxrs-2.3.7.Final-redhat-2.jar:2.3.7.Final-redhat-2]
at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:524) [resteasy-jaxrs-2.3.7.Final-redhat-2.jar:2.3.7.Final-redhat-2]
at org.jboss.resteasy.core.SynchronousDispatcher.invoke(SynchronousDispatcher.java:126) [resteasy-jaxrs-2.3.7.Final-redhat-2.jar:2.3.7.Final-redhat-2]
at org.jboss.resteasy.plugins.server.servlet.ServletContainerDispatcher.service(ServletContainerDispatcher.java:208) [resteasy-jaxrs-2.3.7.Final-redhat-2.jar:2.3.7.Final-redhat-2]
at org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:55) [resteasy-jaxrs-2.3.7.Final-redhat-2.jar:2.3.7.Final-redhat-2]
at org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.service(HttpServletDispatcher.java:50) [resteasy-jaxrs-2.3.7.Final-redhat-2.jar:2.3.7.Final-redhat-2]
at javax.servlet.http.HttpServlet.service(HttpServlet.java:847) [jboss-servlet-api_3.0_spec-1.0.2.Final-redhat-1.jar:1.0.2.Final-redhat-1]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:295) [jbossweb-7.2.2.Final-redhat-1.jar:7.2.2.Final-redhat-1]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214) [jbossweb-7.2.2.Final-redhat-1.jar:7.2.2.Final-redhat-1]
at org.commonjava.aprox.depgraph.jaxrs.filter.WorkspaceHandlerFilter.doFilter(WorkspaceHandlerFilter.java:79) [classes:]
at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:246) [jbossweb-7.2.2.Final-redhat-1.jar:7.2.2.Final-redhat-1]
at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:214) [jbossweb-7.2.2.Final-redhat-1.jar:7.2.2.Final-redhat-1]
at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230) [jbossweb-7.2.2.Final-redhat-1.jar:7.2.2.Final-redhat-1]
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:149) [jbossweb-7.2.2.Final-redhat-1.jar:7.2.2.Final-redhat-1]
at org.jboss.as.web.security.SecurityContextAssociationValve.invoke(SecurityContextAssociationValve.java:169) [jboss-as-web-7.3.0.Final-redhat-14.jar:7.3.0.Final-redhat-14]
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:145) [jbossweb-7.2.2.Final-redhat-1.jar:7.2.2.Final-redhat-1]
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:97) [jbossweb-7.2.2.Final-redhat-1.jar:7.2.2.Final-redhat-1]
at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:102) [jbossweb-7.2.2.Final-redhat-1.jar:7.2.2.Final-redhat-1]
at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:336) [jbossweb-7.2.2.Final-redhat-1.jar:7.2.2.Final-redhat-1]
at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:856) [jbossweb-7.2.2.Final-redhat-1.jar:7.2.2.Final-redhat-1]
at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:653) [jbossweb-7.2.2.Final-redhat-1.jar:7.2.2.Final-redhat-1]
at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:920) [jbossweb-7.2.2.Final-redhat-1.jar:7.2.2.Final-redhat-1]
at java.lang.Thread.run(Thread.java:744) [rt.jar:1.7.0_51]
Caused by: javax.xml.transform.TransformerException: Can't transform a Source of type javax.xml.transform.stax.StAXSource
at org.apache.xalan.transformer.TransformerIdentityImpl.transform(TransformerIdentityImpl.java:419)
at org.commonjava.maven.galley.maven.parse.XMLInfrastructure.fallbackParseDocument(XMLInfrastructure.java:275) [classes:]
... 52 more
When I try in 0.11.3-SNAPSHOT to get urlmap with root org.codehaus.plexus:plexus:1.0.5 I get NPE:
The actual cause is a non-defined XML entity in the pom. Although this is tested in Galley when I run it in AProx it behaves differently from the test. The root cause of this exception is TrensformerFactory implementation used when running in AProx on EAP 6.1/6.2. While when ran from tests, the used class is com.sun.org.apache.xalan.internal.xsltc.trax.TransformerFactoryImpl while when ran in AProx, the implementation is redirected.TransformerFactory (containing 2 org.apache.xalan.processor.TransformerFactoryImpl instances in fields actual and saxtual) resulting in transformer of class org.apache.xalan.transformer.TransformerIdentityImpl. The thrown exception is (note that I added logging of this exception at XMLInfrastructure:337, so the following line numbers are increased by one):