5 Replies Latest reply on Apr 4, 2003 11:59 AM by paulwells

    Deployment problems

    paulwells

      Hi,

      When deploying my BMP Entity Bean I see the following only in the JBoss log:

      2003-04-04 15:11:26,585 INFO [org.jboss.deployment.MainDeployer] Starting deployment of package: file:/D:/Program Files/jboss-3.0.6_tomcat-4.1.18/server/default/deploy/CustomerEnterpriseBean.jar
      2003-04-04 15:11:26,605 INFO [org.jboss.deployment.MainDeployer] Deployed package: file:/D:/Program Files/jboss-3.0.6_tomcat-4.1.18/server/default/deploy/CustomerEnterpriseBean.jar

      It looks like it is attempting to deploy the package but does not succed in deploying the bean. Is there anyway I can find out why it has not deployed? I thought it was something to do with the deployment descriptor but I think this looks ok:

      <?xml version="1.0"?>
      <!DOCTYPE ejb-jar PUBLIC '-//Sun Microsystems, Inc.//DTD Enterprise JavaBeans 1.1//EN' 'http://java.sun.com/j2ee/dtds/ejb-jar_1_1.dtd'>
      <ejb-jar>
      <enterprise-beans>


      <ejb-name>Customer</ejb-name>
      com.j2ee.projects.test.CustomerHome
      com.j2ee.projects.test.Customer
      <ejb-class>com.j2ee.projects.test.CustomerEJB</ejb-class>
      <persistence-type>Bean</persistence-type>
      <prim-key-class>java.lang.Integer</prim-key-class>
      false

      </enterprise-beans>
      <assembly-descriptor>
      <container-transaction>

      <ejb-name>Customer</ejb-name>
      <method-name>*</method-name>

      <trans-attribute>Required</trans-attribute>
      </container-transaction>
      </assembly-descriptor>
      </ejb-jar>

        • 1. Re: Deployment problems
          paulwells

          Just to quantify this problem, I was expecting to see something like this in the JBoss log:

          [org.jboss.ejb.EjbModule] Creating
          2003-04-04 14:53:35,885 INFO [org.jboss.ejb.EjbModule] Deploying Customer
          2003-04-04 14:53:35,925 INFO [org.jboss.ejb.EjbModule] Created
          2003-04-04 14:53:35,945 INFO [org.jboss.ejb.EjbModule] Starting
          2003-04-04 14:53:36,025 INFO [org.jboss.ejb.EjbModule] Started

          Any ideas?

          • 2. Re: Deployment problems

            What messages do you get?
            Try turning on debug logging in
            server/default/conf/log4j.xml

            Regards,
            Adrian

            • 3. Re: Deployment problems

              Actually, try

              jar -tf myejb.jar

              You should have

              META-INF/ejb-jar.xml

              otherwise it will just deploy it as a class
              library.

              Regards,
              Adrian

              • 4. Re: Deployment problems
                paulwells

                Cheers, that's the ticket. I'd made a schoolboy error and packaged the ejb-jar.xml into the root of the jar instead of META-INF/ejb-jar.xml

                • 5. Re: Deployment problems
                  paulwells

                  Actually there is now another problem. When I try to call any of the business methods on the remote interface I get this exception:

                  17:56:53,198 ERROR [LogInterceptor] RuntimeException:
                  java.lang.IllegalArgumentException: Attempt to get a lock for a null object
                  at org.jboss.ejb.BeanLockManager.getLock(BeanLockManager.java:80)
                  at org.jboss.ejb.plugins.EntityLockInterceptor.invoke(EntityLockInterceptor.java:99)
                  at org.jboss.ejb.plugins.EntityCreationInterceptor.invoke(EntityCreationInterceptor.java:69)
                  at org.jboss.ejb.plugins.AbstractTxInterceptor.invokeNext(AbstractTxInterceptor.java:107)
                  at org.jboss.ejb.plugins.TxInterceptorCMT.runWithTransactions(TxInterceptorCMT.java:228)
                  at org.jboss.ejb.plugins.TxInterceptorCMT.invoke(TxInterceptorCMT.java:92)
                  at org.jboss.ejb.plugins.SecurityInterceptor.invoke(SecurityInterceptor.java:130)
                  at org.jboss.ejb.plugins.LogInterceptor.invoke(LogInterceptor.java:204)
                  at org.jboss.ejb.EntityContainer.invoke(EntityContainer.java:493)
                  at org.jboss.ejb.Container.invoke(Container.java:712)
                  at org.jboss.ejb.EntityContainer.invoke(EntityContainer.java:1058)
                  at org.jboss.mx.server.MBeanServerImpl.invoke(MBeanServerImpl.java:517)
                  at org.jboss.invocation.jrmp.server.JRMPInvoker.invoke(JRMPInvoker.java:382)
                  at sun.reflect.GeneratedMethodAccessor38.invoke(Unknown Source)
                  at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
                  at java.lang.reflect.Method.invoke(Method.java:324)
                  at sun.rmi.server.UnicastServerRef.dispatch(UnicastServerRef.java:261)
                  at sun.rmi.transport.Transport$1.run(Transport.java:148)
                  at java.security.AccessController.doPrivileged(Native Method)
                  at sun.rmi.transport.Transport.serviceCall(Transport.java:144)
                  at sun.rmi.transport.tcp.TCPTransport.handleMessages(TCPTransport.java:460)
                  at sun.rmi.transport.tcp.TCPTransport$ConnectionHandler.run(TCPTransport.java:701)
                  at java.lang.Thread.run(Thread.java:536)

                  Any ideas?