3 Replies Latest reply on Dec 9, 2005 10:40 PM by yantriki

    Service in JBoss

      I want to write an application which is supposed to run as a service and it needs to do periodic tasks [poll some object and collect statistics]. I have following questions:

      1. Can I write such an application as service in JBoss.
      2. If yes, what happens to lifecycle management am I allowed to create threads? Where can I find more information?

      I appreciate any help.

        • 1. Re: Service in JBoss
          starksm64
          • 2. Re: Service in JBoss

            Thanks Scott.

            Ok, so I started reading about JBoss microkernal and realize that I need to write a ServiceMBean. Now the AS document mentions org.jboss.naming.NonSerializableFactory for binding the beans. I could not find the class in any jar file. I searched, albeit, I don't know how good is microsoft search when it comes to looking for a string in jar file and the jar files listed on jarhoo.com for the class could not be found. I am using jboss4.0.3SP1.

            1. Has the class org.jboss.naming.NonSerializableFactory been replaced? After extensive searching I see some JIRA entries mentioning that the class has been renamed to "org.jboss.util.naming.NonSerializableFactory". If that's so the documentation needs to be updated.

            2. What other alternative do I have to bind some object in my service into JNDI. Do I specifically have to use NonSerializableFactory?

            • 3. Re: Service in JBoss

              Need help to understand how to write service using EJB 3.0. Have posted the code in the EJB 3.0 forum:

              http://www.jboss.org/index.html?module=bb&op=viewtopic&t=73769

              Would appreciate any help.