1 Reply Latest reply on Jan 2, 2013 9:27 AM by kpiwko

    java.lang.StackOverflowError issue

    chatura

      Hi

       

        I'm getting stackoverflow issue when i tried to deploy my archive through ShrinkWrap.  But this was occured after i refactor some my interfaces to generic types that include in final archive.

       

      05:17:38,938 ERROR [AbstractKernelController] Error installing to Start: name=vfszip:/C:/DialogProvisioning/jbo

      java.lang.StackOverflowError

              at java.lang.Class.getGenericInfo(Class.java:2252)

              at java.lang.Class.getTypeParameters(Class.java:621)

              at org.jboss.webbeans.util.Reflections$HierarchyDiscovery.resolveTypeParameter(Reflections.java:168)

              at org.jboss.webbeans.util.Reflections$HierarchyDiscovery.resolveType(Reflections.java:138)

              at org.jboss.webbeans.util.Reflections$HierarchyDiscovery.resolveTypeParameter(Reflections.java:174)

              at org.jboss.webbeans.util.Reflections$HierarchyDiscovery.resolveType(Reflections.java:138)

              at org.jboss.webbeans.util.Reflections$HierarchyDiscovery.resolveTypeParameter(Reflections.java:174)

              .....        

      05:17:58,254 INFO  [DeployHandler] Failed to complete command: [start] for deployment: names=[test.ear], copyContent=true

      org.jboss.deployers.client.spi.IncompleteDeploymentException: Summary of incomplete deployments (SEE PREVIOUS ERRORS FOR DETAILS):

      DEPLOYMENTS IN ERROR:

        Deployment "vfszip:/C:/DialogProvisioning/jboss-5.1.0.GA/server/default/deploy/test.ear/_WebBeansBootstrapBean" is in error due to the following reason(s): java.lang.StackOverflowError

              at org.jboss.deployers.plugins.deployers.DeployersImpl.checkComplete(DeployersImpl.java:993)

              at org.jboss.deployers.plugins.deployers.DeployersImpl.checkComplete(DeployersImpl.java:939)

              at org.jboss.deployers.plugins.main.MainDeployerImpl.checkComplete(MainDeployerImpl.java:873)

              at org.jboss.system.server.profileservice.repository.MainDeployerAdapter.checkComplete(MainDeployerAdapter.java:128)

              at org.jboss.profileservice.management.upload.remoting.AbstractDeployHandler.start(AbstractDeployHandler.java:265)

              at org.jboss.profileservice.management.upload.remoting.AbstractDeployHandler.invoke(AbstractDeployHandler.java:177)

              at org.jboss.remoting.ServerInvoker.invoke(ServerInvoker.java:891)

              at org.jboss.remoting.transport.socket.ServerThread.completeInvocation(ServerThread.java:744)

              at org.jboss.remoting.transport.socket.ServerThread.processInvocation(ServerThread.java:697)

              at org.jboss.remoting.transport.socket.ServerThread.dorun(ServerThread.java:524)

              at org.jboss.remoting.transport.socket.ServerThread.run(ServerThread.java:232)

       

      My deployment in testcase

       

      public static JavaArchive createTestArchive() {

       

                          return ShrinkWrap

                                                   .create(JavaArchive.class, "provtask.jar")

                                                   .addPackage(TaskExecutorCommand.class.getPackage())// My generic interface type, Alos tried to add this as class resource and same result.

                                                   .addAsManifestResource(EmptyAsset.INSTANCE, ArchivePaths.create("beans.xml")) // b

             .addAsManifestResource("META-INF/persistence.xml",                                                            "persistence.xml");

                }

       

      Generic Interface Type

       

      public interface TaskExecutorCommand<T> {

       

                public TaskExecutorCommand<T> execute(T provisioningTask,TaskExecutionContext executionContext);

       

                public TaskExecutorCommand<T> add(TaskExecutorCommand<T> executorCommand);

       

                public TaskExecutorCommand<T> add(TaskExecutionHandler<T> executionHandler);

       

      }

       

      Below setup i currently use for testing.

       

      arquillian.version : 1.0.3.Final

      arquillian-jbossas-remote-5.1 : 1.0.0.CR3

       

      Thanks

        • 1. Re: java.lang.StackOverflowError issue
          kpiwko

          Hello Chatura,

           

          can you add following snippet to arquillian.xml and compare resulting jar stored in deploymentExportPath with the one you were able to deploy manually?

           

           

              <engine>
                  <property name="deploymentExportPath">target/deployments</property>
              </engine>
          

           

          There is likely a missing class or dependency.

           

          Regards,

           

          Karel