2 Replies Latest reply on Feb 15, 2008 7:49 AM by linoux

    Cross-referencing EJBs doesn't work

    linoux

      Hello !

      It seems that cross referencing 2 sessions does not work in JBoss... Although I found no restricutions about cross-referencing stateless session beans in EJB specs....

      I'm using JBoss-4.0.5.GA.

      Here is my sessions definitions :

      @Local
      public interface ALocal {
      
      }
      
      @Stateless
      public class A implements ALocal {
       @EJB BLocal b;
      }
      
      @Local
      public interface BLocal {
      
      }
      
      @Stateless
      public class B implements BLocal{
       @EJB ALocal a;
      }


      And here the deployment logs (everything before this seems OK) :

      ObjectName: jboss.j2ee:ear=ogp-app.ear,jar=ogp-ejb.jar,name=A,service=EJB3
       State: NOTYETINSTALLED
       I Depend On:
       jboss.j2ee:ear=ogp-app.ear,jar=ogp-ejb.jar,name=B,service=EJB3
       Depends On Me:
       jboss.j2ee:ear=ogp-app.ear,jar=ogp-ejb.jar,name=B,service=EJB3
      
      ObjectName: jboss.j2ee:ear=ogp-app.ear,jar=ogp-ejb.jar,name=B,service=EJB3
       State: NOTYETINSTALLED
       I Depend On:
       jboss.j2ee:ear=ogp-app.ear,jar=ogp-ejb.jar,name=A,service=EJB3
       Depends On Me:
       jboss.j2ee:ear=ogp-app.ear,jar=ogp-ejb.jar,name=A,service=EJB3
      


      It seams that the two EJB are waiting for each other...

      Does anyone know how to make this work ?

      Thanks for your help !

      --
      Celine