2 Replies Latest reply on Jul 6, 2009 12:59 PM by alrubinger

    How to convert @Service MBean POJO to microcontainer POJO

    yashendrac

      I have lot of MBean Services created using @Service and @Management annotations. I am not using -service xml instead using @Service annotation so that I can use annotations like @EJB.These Services depends on various EJBs and to get reference of ejbs from Services I am using @EJB annotation. This is how the code is:

      @Service
      @Management(StartupMBean.class)
      @Depends("jboss:name=SmcBarrier,type=Barrier")
      public class UserStartup
       implements StartupMBean {
      
       @EJB
       private ObjectManagerLocal objectManager;
       @EJB
       private PropertyManagerLocal propertyManager;
      .....
      .....
       public void start() {
      .....
      .....
       }
      
      


      It would be highly appreciated if anybody let me know how to achieve all these if I want convert my POJO mbeans to microcontainer beans.

      Are there equivalent annotations in microcontainer for @EJB , @Depends.
      Or it is not possible in microcontained bean to achieve these through annotations without using -beans.xml