4 Replies Latest reply on Jul 11, 2008 4:41 AM by giulio massa

    SessionBean not deployed, remote not bound

    giulio massa Newbie

      Hi, i'm developing a ejb3 app with a session bean, a remote interface and a stand alone client.
      I use Netbeans 5.5 with jboss4.0.4 bundled and my ear package is succesfully builded and deployed.
      But when I put the .ear package in another Jboss4.0.4 server (with all configuration), only the client
      is deployed:

      10:41:44,899 INFO [EARDeployer] Init J2EE application: file:/home/giulio/Informatica/Sistemi_Middleware/jboss-4.0.4.GA-clustered/server/all/deploy/AddressBook.ear
      10:41:44,996 INFO [ClientDeployer] Client ENC bound under: AddressBook-app-client
      10:41:45,161 INFO [EARDeployer] Started J2EE application: file:/home/giulio/Informatica/Sistemi_Middleware/jboss-4.0.4.GA-clustered/server/all/deploy/AddressBook.ear
      

      Instead of:
      [NamingHelper] JNDI InitialContext properties:{java.naming.factory.initial=org.jnp.interfaces.NamingContextFactory,java.naming.factory.url.pkgs=org.jboss.naming:org.jnp.interfaces}
      12:32:36,588 INFO [JmxKernelAbstraction] installing MBean: jboss.j2ee:ear=AddressBook.ear,jar=AddressBook-ejb.jar,name=SessionBean,service=EJB3 with dependencies:
      12:32:36,588 INFO [JmxKernelAbstraction] persistence.units:ear=AddressBook.ear,jar=AddressBook-ejb.jar,unitName=AddressBook-ejbPU
      12:32:36,672 INFO [EJBContainer] STARTED EJB: ejb.SessionBean ejbName: SessionBean
      12:32:36,699 INFO [EJB3Deployer] Deployed: file:/home/giulio/Informatica/Sistemi_Middleware/JBoss-4.0.4.GA/server/default/tmp/deploy/tmp30870AddressBook.ear-contents/AddressBook-ejb.jar
      12:32:36,790 INFO [EARDeployer] Started J2EE application: file:/home/giulio/Informatica/Sistemi_Middleware/JBoss-4.0.4.GA/server/default/deploy/AddressBook.ear
      

      The application can't bound the remote interface, as I can see from JNDIView list():

      +- AddressBook-app-client (class: org.jnp.interfaces.NamingContext)
      

      Instead of:

      +- AddressBook (class: org.jnp.interfaces.NamingContext)
      | +- SessionBean (class: org.jnp.interfaces.NamingContext)
      | | +- remote (proxy: $Proxy73 implements interface ejb.SessionRemote,interface org.jboss.ejb3.JBossProxy,interface javax.ejb.EJBObject)
      +- UserTransaction (class: org.jboss.tm.usertx.client.ClientUserTransaction)
      +- AddressBook-app-client (class: org.jnp.interfaces.NamingContext)
      

      Why this happens?
      Please help me!


        • 1. Re: SessionBean not deployed, remote not bound
          jaikiran pai Master

          Please post the contents of your application.xml and the output of the following command:

          jar -tf AddressBook.ear


          Also any specific reason for using 4.0.4 version of JBoss? JBoss-4.2.2 GA is the latest stable release with EJB3 support.

          • 2. Re: SessionBean not deployed, remote not bound
            jaikiran pai Master

            By the way, as far as i remember, 4.0.4 required additional EJB3 patches to be applied for EJB3 support. Have you done that?

            • 3. Re: SessionBean not deployed, remote not bound
              giulio massa Newbie

              This is the output of tar -tf jar -tf AddressBook.ear :

              META-INF/
              META-INF/MANIFEST.MF
              jar/
              AddressBook-app-client.jar
              AddressBook-ejb.jar
              META-INF/application.xml
              META-INF/jboss-app.xml


              Also any specific reason for using 4.0.4 version of JBoss? JBoss-4.2.2 GA is the latest stable release with EJB3 support.


              Because I've a cluster of hosts with this version (4.0.4GA)

              By the way, as far as i remember, 4.0.4 required additional EJB3 patches to be applied for EJB3 support. Have you done that?


              I've installed it from the installer, and the "all" configuration support the EJB3 as I've read during the installation.
              My application.xml:

              <?xml version="1.0" encoding="UTF-8"?>
              <application version="5" xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_5.xsd">
               <display-name>AddressBook</display-name>
               <module>
               <java>AddressBook-app-client.jar</java>
               </module>
               <module>
               <ejb>AddressBook-ejb.jar</ejb>
               </module>
              </application>


              And jboss-app.xml:

              <?xml version="1.0" encoding="UTF-8"?>
              <jboss-app/>


              (this files are generated by Netbeans5.5)





              • 4. Re: SessionBean not deployed, remote not bound
                giulio massa Newbie

                I've solved migrating to 4.2.2.GA, but I can't believe that I've lost so much time with this problem...
                With 4.2.2 everything magically runs.