4 Replies Latest reply on Apr 22, 2003 6:54 AM by Setya Setya

    Why should I redeploy after restarting JBoss ?

    Setya Setya Newbie

      Hi all,

      Everytime I restart JBoss I have to redeploy my EJB (though simply by delete and restore the Bean jar) unless a message stating that my EJB is not bound pop ups when the client apps try to access the Bean. What have I done wrong ?

      Thanks in advance.

      Setya

        • 1. Re: Why should I redeploy after restarting JBoss ?
          Adrian Brock Master

          Why is your ejb not bound.

          You should have an ERROR message in
          server/default/log/server.log

          Regards,
          Adrian

          • 2. Re: Why should I redeploy after restarting JBoss ?
            Setya Setya Newbie

            Thanks for the response,

            Here are some lines of the server.log :

            2003-04-19 14:40:16,775 INFO [org.jboss.deployment.MainDeployer] Starting deployment of package: file:/C:/JBoss/server/default/deploy/SunRay-EJBSecurity.jar
            2003-04-19 14:40:16,895 INFO [org.jboss.ejb.EjbModule] Creating
            2003-04-19 14:40:16,915 INFO [org.jboss.ejb.EjbModule] Deploying Security
            2003-04-19 14:40:17,046 ERROR [org.jboss.deployment.scanner.URLDeploymentScanner] Failed to deploy: org.jboss.deployment.scanner.URLDeploymentScanner$DeployedURL@40284085{ url=file:/C:/JBoss/server/default/deploy/SunRay-EJBSecurity.jar, deployedLastModified=0 }
            org.jboss.deployment.DeploymentException: Could not create deployment: file:/C:/JBoss/server/default/deploy/SunRay-EJBSecurity.jar; - nested throwable: (java.lang.NoClassDefFoundError: Lcom/sunray/SecurityBusinessLogic/SecurityBL;)
            at org.jboss.deployment.MainDeployer.create(MainDeployer.java:777)
            at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:620)
            at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:585)
            at sun.reflect.GeneratedMethodAccessor9.invoke(Unknown Source)
            at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
            at java.lang.reflect.Method.invoke(Method.java:324)
            at org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.java:284)
            at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:517)
            at org.jboss.util.jmx.MBeanProxy.invoke(MBeanProxy.java:174)
            at $Proxy4.deploy(Unknown Source)
            at org.jboss.deployment.scanner.URLDeploymentScanner.deploy(URLDeploymentScanner.java:435)
            at org.jboss.deployment.scanner.URLDeploymentScanner.scanDirectory(URLDeploymentScanner.java:656)
            at org.jboss.deployment.scanner.URLDeploymentScanner.scan(URLDeploymentScanner.java:507)
            at org.jboss.deployment.scanner.AbstractDeploymentScanner.startService(AbstractDeploymentScanner.java:261)
            at org.jboss.system.ServiceMBeanSupport.start(ServiceMBeanSupport.java:165)
            at sun.reflect.GeneratedMethodAccessor7.invoke(Unknown Source)
            at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
            at java.lang.reflect.Method.invoke(Method.java:324)
            at org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.java:284)
            at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:517)
            at org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceController.java:978)
            at $Proxy0.start(Unknown Source)
            at org.jboss.system.ServiceController.start(ServiceController.java:398)
            at sun.reflect.GeneratedMethodAccessor6.invoke(Unknown Source)
            at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
            at java.lang.reflect.Method.invoke(Method.java:324)
            at org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.java:284)
            at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:517)
            at org.jboss.util.jmx.MBeanProxy.invoke(MBeanProxy.java:174)
            at $Proxy3.start(Unknown Source)
            at org.jboss.deployment.SARDeployer.start(SARDeployer.java:249)
            at org.jboss.deployment.MainDeployer.start(MainDeployer.java:807)
            at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:621)
            at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:585)
            at org.jboss.deployment.MainDeployer.deploy(MainDeployer.java:569)
            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:324)
            at org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.java:284)
            at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:517)
            at org.jboss.system.server.ServerImpl.doStart(ServerImpl.java:324)
            at org.jboss.system.server.ServerImpl.start(ServerImpl.java:221)
            at org.jboss.Main.boot(Main.java:148)
            at org.jboss.Main$1.run(Main.java:381)
            at java.lang.Thread.run(Thread.java:536)
            Caused by: java.lang.NoClassDefFoundError: Lcom/sunray/SecurityBusinessLogic/SecurityBL;
            at java.lang.Class.getDeclaredFields0(Native Method)
            at java.lang.Class.privateGetDeclaredFields(Class.java:1480)
            at java.lang.Class.getDeclaredFields(Class.java:1061)
            at org.jboss.ejb.plugins.StatefulSessionFilePersistenceManager.create(StatefulSessionFilePersistenceManager.java:122)
            at org.jboss.ejb.StatefulSessionContainer.create(StatefulSessionContainer.java:219)
            at org.jboss.ejb.Container.invoke(Container.java:752)
            at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:517)
            at org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceController.java:978)
            at $Proxy5.create(Unknown Source)
            at org.jboss.system.ServiceController.create(ServiceController.java:315)
            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:324)
            at org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.java:284)
            at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:517)
            at org.jboss.util.jmx.MBeanProxy.invoke(MBeanProxy.java:174)
            at $Proxy21.create(Unknown Source)
            at org.jboss.ejb.EjbModule.createService(EjbModule.java:386)
            at org.jboss.system.ServiceMBeanSupport.create(ServiceMBeanSupport.java:136)
            at sun.reflect.GeneratedMethodAccessor13.invoke(Unknown Source)
            at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
            at java.lang.reflect.Method.invoke(Method.java:324)
            at org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.java:284)
            at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:517)
            at org.jboss.system.ServiceController$ServiceProxy.invoke(ServiceController.java:978)
            at $Proxy5.create(Unknown Source)
            at org.jboss.system.ServiceController.create(ServiceController.java:315)
            at org.jboss.system.ServiceController.create(ServiceController.java:243)
            at sun.reflect.GeneratedMethodAccessor4.invoke(Unknown Source)
            at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
            at java.lang.reflect.Method.invoke(Method.java:324)
            at org.jboss.mx.capability.ReflectedMBeanDispatcher.invoke(ReflectedMBeanDispatcher.java:284)
            at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:517)
            at org.jboss.util.jmx.MBeanProxy.invoke(MBeanProxy.java:174)
            at $Proxy11.create(Unknown Source)
            at org.jboss.ejb.EJBDeployer.create(EJBDeployer.java:377)
            at org.jboss.deployment.MainDeployer.create(MainDeployer.java:760)
            ... 45 more


            The log says that it can not find class Lcom/sunray/SecurityBusinessLogic/SecurityBL(java.lang.NoClassDefFoundError: Lcom/sunray/SecurityBusinessLogic/SecurityBL;).

            My security EJB does import com/sunray/SecurityBusinessLogic/SecurityBL not Lcom/sunray/SecurityBusinessLogic/SecurityBL.

            Or, is this because SunRay-EJBSecurity.jar is deployed before the SunRay-SecurityBL.jar ?
            If this is the case, how can I change the deployment sequence ?

            I'm sorry for the lengthy post.

            Thanks in advanced


            Setya

            • 3. Re: Why should I redeploy after restarting JBoss ?
              Adrian Brock Master

              Maybe the simplest mechanism is to use the
              Prefix deployment sorter.
              See server/default/conf/jboss-service.xml

              Regards,
              Adrian

              • 4. Re: Why should I redeploy after restarting JBoss ?
                Setya Setya Newbie

                Thanks,

                Where can I find documentation about Prefix Deployment Sorter ?

                Setya