5 Replies Latest reply on Jun 25, 2010 4:12 AM by Stefano Ficcadenti

    Error deploying a Web Service

    Stefano Ficcadenti Newbie

      When I try to deploy a java web service (with annotations) on JBoss AS 5.1 I have:

      [AbstractKernelController] Error installing to Real: name=vfsfile:/Applications/JBoss5.1/server/default/deploy/WS_My.war/ state=PreReal mode=Manual requiredState=Real

       

      How is the problem ?

      I previus deploy similar WS without exception...

        • 1. Re: Error deploying a Web Service
          Stefano Ficcadenti Newbie

          It seems a problem with a JAXB Context but I don't understand how resolve it...

           

          I try to deploy a WS with same procedure of previus test WS I created (and work well) but now still return same error for further Ws...

          • 2. Re: Error deploying a Web Service
            Sidney Zurch Novice

            You're not giving us much to go on.

             

            If you have one web service that deploys successfully on 5.1, and a different web service that does not deploy, what does that tell you?  What would logically be the problem?

             

            Deployment errors cascade.  The error that you report may be triggered by a previous error.   The only way you're going to get help tracking that down is to post a stack trace.

            • 3. Re: Error deploying a Web Service
              Stefano Ficcadenti Newbie

              Logically I don't understand the problem, I use always Java Annotations (@WebService, @SOAPBinding,ecc...) and basic web.xml.

               

              09:03:38,889 ERROR [AbstractKernelController] Error installing to Real: name=vfsfile:/Applications/JBoss5.1/server/default/deploy/UnikaWS.war/ state=PreReal mode=Manual requiredState=Real
              org.jboss.deployers.spi.DeploymentException: Error during deploy: vfsfile:/Applications/JBoss5.1/server/default/deploy/UnikaWS.war/
                  at org.jboss.deployers.spi.DeploymentException.rethrowAsDeploymentException(DeploymentException.java:49)
                  at org.jboss.deployers.plugins.deployers.DeployerWrapper.deploy(DeployerWrapper.java:177)
                  at org.jboss.deployers.plugins.deployers.DeployersImpl.doDeploy(DeployersImpl.java:1439)
                  at org.jboss.deployers.plugins.deployers.DeployersImpl.doInstallParentFirst(DeployersImpl.java:1157)
                  at org.jboss.deployers.plugins.deployers.DeployersImpl.install(DeployersImpl.java:1098)
                  at org.jboss.dependency.plugins.AbstractControllerContext.install(AbstractControllerContext.java:348)
                  at org.jboss.dependency.plugins.AbstractController.install(AbstractController.java:1631)
                  at org.jboss.dependency.plugins.AbstractController.incrementState(AbstractController.java:934)
                  at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:1082)
                  at org.jboss.dependency.plugins.AbstractController.resolveContexts(AbstractController.java:984)
                  at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:822)
                  at org.jboss.dependency.plugins.AbstractController.change(AbstractController.java:553)
                  at org.jboss.deployers.plugins.deployers.DeployersImpl.process(DeployersImpl.java:781)
                  at org.jboss.deployers.plugins.main.MainDeployerImpl.process(MainDeployerImpl.java:702)
                  at org.jboss.system.server.profileservice.repository.MainDeployerAdapter.process(MainDeployerAdapter.java:117)
                  at org.jboss.system.server.profileservice.hotdeploy.HDScanner.scan(HDScanner.java:362)
                  at org.jboss.system.server.profileservice.hotdeploy.HDScanner.run(HDScanner.java:255)
                  at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
                  at java.util.concurrent.FutureTask$Sync.innerRunAndReset(FutureTask.java:317)
                  at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:150)
                  at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$101(ScheduledThreadPoolExecutor.java:98)
                  at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.runPeriodic(ScheduledThreadPoolExecutor.java:181)
                  at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:205)
                  at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
                  at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
                  at java.lang.Thread.run(Thread.java:637)
              Caused by: java.lang.IllegalStateException: Cannot build JAXB context
                  at org.jboss.ws.metadata.builder.jaxws.JAXWSMetaDataBuilder.createJAXBContext(JAXWSMetaDataBuilder.java:984)
                  at org.jboss.ws.metadata.builder.jaxws.JAXWSWebServiceMetaDataBuilder.buildWebServiceMetaData(JAXWSWebServiceMetaDataBuilder.java:154)
                  at org.jboss.ws.metadata.builder.jaxws.JAXWSServerMetaDataBuilder.setupProviderOrWebService(JAXWSServerMetaDataBuilder.java:50)
                  at org.jboss.ws.metadata.builder.jaxws.JAXWSMetaDataBuilderJSE.buildMetaData(JAXWSMetaDataBuilderJSE.java:61)
                  at org.jboss.wsf.stack.jbws.UnifiedMetaDataDeploymentAspect.start(UnifiedMetaDataDeploymentAspect.java:64)
                  at org.jboss.wsf.framework.deployment.DeploymentAspectManagerImpl.deploy(DeploymentAspectManagerImpl.java:129)
                  at org.jboss.wsf.container.jboss50.deployer.ArchiveDeployerHook.deploy(ArchiveDeployerHook.java:76)
                  at org.jboss.wsf.container.jboss50.deployer.AbstractWebServiceDeployer.internalDeploy(AbstractWebServiceDeployer.java:60)
                  at org.jboss.deployers.spi.deployer.helpers.AbstractRealDeployer.deploy(AbstractRealDeployer.java:50)
                  at org.jboss.deployers.plugins.deployers.DeployerWrapper.deploy(DeployerWrapper.java:171)
                  ... 24 more
              Caused by: org.jboss.ws.WSException: Failed to create JAXBContext
                  at org.jboss.ws.core.jaxws.CustomizableJAXBContextFactory.createContext(CustomizableJAXBContextFactory.java:114)
                  at org.jboss.ws.metadata.builder.jaxws.JAXWSMetaDataBuilder.createJAXBContext(JAXWSMetaDataBuilder.java:980)
                  ... 33 more
              Caused by: com.sun.xml.bind.v2.runtime.IllegalAnnotationsException: 1 counts of IllegalAnnotationExceptions
              java.lang.StackTraceElement does not have a no-arg default constructor.
                  this problem is related to the following location:
                      at java.lang.StackTraceElement
                      at public java.lang.StackTraceElement[] java.lang.Throwable.getStackTrace()
                      at java.lang.Throwable
                      at java.lang.Exception
                      at java.sql.SQLException
                      at private java.sql.SQLException test.ws.jaxws.SQLExceptionBean.nextException
                      at test.ws.jaxws.SQLExceptionBean

               

                  at com.sun.xml.bind.v2.runtime.IllegalAnnotationsException$Builder.check(IllegalAnnotationsException.java:102)
                  at com.sun.xml.bind.v2.runtime.JAXBContextImpl.getTypeInfoSet(JAXBContextImpl.java:448)
                  at com.sun.xml.bind.v2.runtime.JAXBContextImpl.<init>(JAXBContextImpl.java:297)
                  at com.sun.xml.bind.v2.ContextFactory.createContext(ContextFactory.java:139)
                  at com.sun.xml.bind.api.JAXBRIContext.newInstance(JAXBRIContext.java:105)
                  at org.jboss.ws.core.jaxws.CustomizableJAXBContextFactory.createContext(CustomizableJAXBContextFactory.java:108)
                  ... 34 more
              09:03:38,895 WARN  [HDScanner] Failed to process changes
              org.jboss.deployers.client.spi.IncompleteDeploymentException: Summary of incomplete deployments (SEE PREVIOUS ERRORS FOR DETAILS):

               

              *** DEPLOYMENTS IN ERROR: Name -> Error

               

              vfsfile:/Applications/JBoss5.1/server/default/deploy/UnikaWS.war/ -> org.jboss.deployers.spi.DeploymentException: Error during deploy: vfsfile:/Applications/JBoss5.1/server/default/deploy/UnikaWS.war/

               


              DEPLOYMENTS IN ERROR:
                Deployment "vfsfile:/Applications/JBoss5.1/server/default/deploy/UnikaWS.war/" is in error due to the following reason(s): com.sun.xml.bind.v2.runtime.IllegalAnnotationsException: 1 counts of IllegalAnnotationExceptions
              java.lang.StackTraceElement does not have a no-arg default constructor.
                  this problem is related to the following location:
                      at java.lang.StackTraceElement
                      at public java.lang.StackTraceElement[] java.lang.Throwable.getStackTrace()
                      at java.lang.Throwable
                      at java.lang.Exception
                      at java.sql.SQLException
                      at private java.sql.SQLException test.ws.jaxws.SQLExceptionBean.nextException
                      at test.ws.jaxws.SQLExceptionBean

               


                  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.system.server.profileservice.hotdeploy.HDScanner.scan(HDScanner.java:369)
                  at org.jboss.system.server.profileservice.hotdeploy.HDScanner.run(HDScanner.java:255)
                  at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441)
                  at java.util.concurrent.FutureTask$Sync.innerRunAndReset(FutureTask.java:317)
                  at java.util.concurrent.FutureTask.runAndReset(FutureTask.java:150)
                  at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.access$101(ScheduledThreadPoolExecutor.java:98)
                  at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.runPeriodic(ScheduledThreadPoolExecutor.java:181)
                  at java.util.concurrent.ScheduledThreadPoolExecutor$ScheduledFutureTask.run(ScheduledThreadPoolExecutor.java:205)
                  at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:886)
                  at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:908)
                  at java.lang.Thread.run(Thread.java:637)

              • 4. Re: Error deploying a Web Service
                Sidney Zurch Novice

                Like they say in Las Vegas, "Bingo!"

                 

                Illega lAnnotation

                 

                You may have to post the code.  And I'm curious about how SQL is related.

                Stefano Ficcadenti wrote:

                 

                Logically I don't understand the problem, I use always Java Annotations (@WebService, @SOAPBinding,ecc...) and basic web.xml.

                 


                Caused by: com.sun.xml.bind.v2.runtime.IllegalAnnotationsException: 1 counts of IllegalAnnotationExceptions
                java.lang.StackTraceElement does not have a no-arg default constructor.
                    this problem is related to the following location:
                        at java.lang.StackTraceElement
                        at public java.lang.StackTraceElement[] java.lang.Throwable.getStackTrace()
                        at java.lang.Throwable
                        at java.lang.Exception
                        at java.sql.SQLException
                        at private java.sql.SQLException test.ws.jaxws.SQLExceptionBean.nextException
                        at test.ws.jaxws.SQLExceptionBean

                 

                ...


                DEPLOYMENTS IN ERROR:
                  Deployment "vfsfile:/Applications/JBoss5.1/server/default/deploy/UnikaWS.war/" is in error due to the following reason(s): com.sun.xml.bind.v2.runtime.IllegalAnnotationsException: 1 counts of IllegalAnnotationExceptions
                java.lang.StackTraceElement does not have a no-arg default constructor.
                    this problem is related to the following location:
                        at java.lang.StackTraceElement
                        at public java.lang.StackTraceElement[] java.lang.Throwable.getStackTrace()
                        at java.lang.Throwable
                        at java.lang.Exception
                        at java.sql.SQLException
                        at private java.sql.SQLException test.ws.jaxws.SQLExceptionBean.nextException
                        at test.ws.jaxws.SQLExceptionBean

                 

                • 5. Re: Error deploying a Web Service
                  Stefano Ficcadenti Newbie

                  I resolve, now I can deploy it correctly.

                   

                  In java class web service I expose the @WebMethod as follow:

                  public String[] myMethod( @WebParam(name = "name") String param ) throws SQLException

                   

                  as in the method I use SQL class to query data on a DB.

                  To resolve the problem I change "throws SQLException" in "throws Exception" and now it work.

                   

                  Why "throws SQLException" get deploy error ?