1 Reply Latest reply on Mar 4, 2003 2:43 AM by gabri

    Problem with deployment of CustomerEJB

    gabri

      Hi to all. I'm a newbe in JBoss and I'm trying to create the CustomerEJB presented in the book.

      I decided to jar the CustomerEJB along with CabinEJB and TravelAgentEJB so I added another tag in the deployment desc.

      The problem is that the JBoss console says that titan.jar has been deployed but when I try to connect to the beans I get a <some-bean> not bound.

      Please help me!!!


      The ejb.jar.xml:

      <?xml version="1.0"?>

      <!DOCTYPE ejb-jar PUBLIC "-//Sun Microsystems, Inc.//DTD Enterprise JavaBeans 2.0//EN" "http://java.sun.com/dtd/ejb-jar_2_0.dtd">

      <ejb-jar>
      <enterprise-beans>

      <ejb-name>CabinEJB</ejb-name>
      com.titan.cabin.CabinHomeRemote
      com.titan.cabin.CabinRemote
      <ejb-class>com.titan.cabin.CabinBean</ejb-class>
      <persistence-type>Container</persistence-type>
      <prim-key-class>java.lang.Integer</prim-key-class>
      False
      <cmp-version>2.x</cmp-version>
      <abstract-schema-name>Cabin</abstract-schema-name>
      <cmp-field><field-name>id</field-name></cmp-field>
      <cmp-field><field-name>name</field-name></cmp-field>
      <cmp-field><field-name>deckLevel</field-name></cmp-field>
      <cmp-field><field-name>shipId</field-name></cmp-field>
      <cmp-field><field-name>bedCount</field-name></cmp-field>
      <primkey-field>id</primkey-field>
      <security-identity><use-caller-identity/></security-identity>



      <ejb-name>CustomerEJB</ejb-name>
      com.titan.customer.CustomerHomeRemote
      com.titan.customer.CustomerRemote
      <ejb-class>com.titan.customer.CustomerBean</ejb-class>
      <persistence-type>Container</persistence-type>
      <prim-key-class>java.lang.Integer</prim-key-class>
      False
      <cmp-version>2.x</cmp-version>
      <abstract-schema-name>Customer</abstract-schema-name>
      <cmp-field><field-name>id</field-name></cmp-field>
      <cmp-field><field-name>lastName</field-name></cmp-field>
      <cmp-field><field-name>firstName</field-name></cmp-field>
      <primkey-field>id</primkey-field>
      <security-identity><use-caller-identity/></security-identity>



      <ejb-name>TravelAgentEJB</ejb-name>
      com.titan.travelagent.TravelAgentHomeRemote
      com.titan.travelagent.TravelAgentRemote
      <ejb-class>com.titan.travelagent.TravelAgentBean</ejb-class>
      <session-type>Stateless</session-type>
      <transaction-type>Container</transaction-type>
      <ejb-ref>
      <ejb-ref-name>ejb/CabinHomeRemote</ejb-ref-name>
      <ejb-ref-type>Entity</ejb-ref-type>
      com.titan.cabin.CabinHomeRemote
      com.titan.cabin.CabinRemote
      </ejb-ref>
      <security-identity><use-caller-identity/></security-identity>

      </enterprise-beans>

      <assembly-descriptor>
      <security-role>

      This role represents everyone who is allowed full access to the beans.

      <role-name>everyone</role-name>
      </security-role>

      <method-permission>
      <role-name>everyone</role-name>

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


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


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

      </method-permission>

      <container-transaction>

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


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


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

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

      The jboss.xml:

      <?xml version="1.0"?>


      <enterprise-beans>

      <ejb-name>CabinEJB</ejb-name>
      <jndi-name>CabinHomeRemote</jndi-name>



      <ejb-name>CustomerEJB</ejb-name>
      <jndi-name>CustomerHomeRemote</jndi-name>



      <ejb-name>TravelAgentEJB</ejb-name>
      <jndi-name>TravelAgentHomeRemote</jndi-name>
      <ejb-ref>
      <ejb-ref-name>ejb/CabinHomeRemote</ejb-ref-name>
      <jndi-name>CabinHomeRemote</jndi-name>
      </ejb-ref>

      </enterprise-beans>


        • 1. Re: Problem with deployment of CustomerEJB
          gabri

          Hello to everyone!
          There seem to be something not working in the deployment process of JBoss. I rebooted the machine, restarted JBoss, recompiled my beans and finally redeployed them. The result is that they are being deployed correctly and working well...

          Bye...