4 Replies Latest reply on Jan 27, 2011 8:04 AM by jaikiran

    @Depends not supported in Jboss AS 4.2.2 ?

    alansmanne

      Hello,

       

      I've got a problem that seems to have already been solved on these forums... but the solution doesn't work for me.

       

      I have a Queue and a simple MDB that implements MessageDrivenBean, MessageListener.

      Sometimes, when the server is restarted, the queue starts "too early" and crash, because most of the EJBs are not yet deployed.

      So, I've tried to add

       

      @Depends({
           "jboss.j2ee:ear=myEar.ear,jar=myrJar-ejb.jar,name=MyBean,service=EJB3",
           "....",
      })     
      
      

       

      at the beginning of my MDB class. But when I restart Jboss, I see that the MDB is still deployed first (actually second) before most EJBs...

       

      I've even try to put

       

      @Depends({
           "I hope that my wrong syntax will crash at deployment !!!"
      })   
      
      

       

      But nothing happenned... and the MDB was again deployed "first".

       

      I'm using Jboss 4.2.2. I'm can't upgrade to Jboss 5, and start to plan a full switch to Quartz instead of JMS if I can't resolve this problem...