5 Replies Latest reply on Apr 30, 2008 2:32 PM by Zaiwen Gong

    How is JBPM connected with JBoss Messaging?

    Zaiwen Gong Newbie

      Hi,

      I know how to use JBoss Messaging and how to use JBPM seperately, but I would like to find out how those two can be connected?

      For example, if I start a JBPM process, I want it to generate a message topic or a message queue so that other clients can subscribe this topic or receive message from this queue. How to achieve this?

      Thanks a lot!

        • 1. Re: How is JBPM connected with JBoss Messaging?
          Zaiwen Gong Newbie

          Let me clarify what I exactly want to achieve:

          Suppose I have two processes, ProcessA and ProcessB.

          When ProcessA is started, I would like it to send a message to a predefined destination, and thus ProcessB will be invoked automatically.

          Anyone can provide such sample process? Thanks!

          • 2. Re: How is JBPM connected with JBoss Messaging?
            Chip Schoch Novice

            Without more detail I can only suggest that you create an actionhandler that is invoked by processA, which posts a message to your destination. Also, create an MDB that listens on that destination. That MDB should create the ProcessB instance and signal it to start.

            • 3. Re: How is JBPM connected with JBoss Messaging?
              Zaiwen Gong Newbie

              Thanks a lot. You basically anwsered my question.

              I reviewed the bpm_orchestration3 sample included in jbossesb-server-4.2.1GA\samples\quickstarts. This sample is just one process that has 3 nodes, but its design is similar to what you described.

              What I really need to confirm is:

              Is it possible that without any other external actionhadler or MDB, only processA and processB, can they achieve this effect? I mean, can the nodes alone in the BPM process definition achieve the function of posting message or being invoked by message?

              Thanks again!

              • 4. Re: How is JBPM connected with JBoss Messaging?
                Christopher Cox Newbie

                Hi Zaiwen,

                I have actually done what you are looking to do.

                As the previous post states you would create a actionhandler that would send a message to a queue or topic. Then use a MDB to pick up the message and kick start the second process.

                If you look into the jBPM wiki it shows how to integrate jBPM with a JBoss Server, but obviously you would have already replace JBoss MQ with JBoss Messaging.

                Good luck!

                Chris

                • 5. Re: How is JBPM connected with JBoss Messaging?
                  Zaiwen Gong Newbie

                  Many thanks, Chris!

                  Last question to clarify:

                  Inside the processA, you can define a node whicn contains an action with an actionhandler that would send a message. I understand this.

                  HOWEVER, in order to invoke processB, you need to use a MDB to pick up the message. What is MDB? Is it something you have to define outside of processB? Can you define something like a listener inside processB which will wait for the message and kick processB to start?

                  Basically what I want is a very clean GUI design of JBPM process defintion without any outside coding. Is it possible?

                  Hope I don't confuse you.