4 Replies Latest reply on Aug 20, 2002 9:32 AM by rolex

    Getting "outside" EJB container?

    rolex

      Once upon a time ...
      I worked with Weblogic (5.1). I that project we had problems with the well known EJB restrictions (no threads ...). When consulting the vendor of the product causing the problem (threads) we created a Business Delegate class. The Business Delagate class had to live "outside" the EJB container. In Weblogic this is done with a startup class. The problem was solved!

      Now I have a similar problem, this time Jolt that also manipulates threads.

      What is the best way in JBoss to create a class that lives "outside" the EJB container?
      Should i create an MBean ?

        • 1. Re: Getting "outside" EJB container?
          rolex

          I forgot.

          I have to be able to access the Business Delegate class instance from my EJBs. I guess not directly since isolation is lost, so RMI perhaps ?

          • 2. Re: Getting "outside" EJB container?
            sgturner

            I'm not sure what you mean by "outside" the container. But there are 3 options, as I see it.

            1. 2 JVMs on 2 machines
            2. 2 JVMs on same machine
            3. both in same JVM.

            For #1 or #2, use an MBean and use the RMI connector to communicate between the two. For this solution, use the JBoss JMX and for good explanation of JMX see free JMX book on www.theserverside.com.

            For #3, I don't know - depends what you mean.

            • 3. Re: Getting "outside" EJB container?
              rolex

              Option #3 meets my needs.
              I just want to make sure I isolate my EJBs from code (Jolt) that manipulates threads. At least in Weblogic that caused problems.

              • 4. Re: Getting "outside" EJB container?
                rolex

                So,
                I guess I will have to isolate my Jolt code from the EJB in JBoss too?
                What is the best way to do that in JBoss?