Hi Edgar, if we have a MDB that finds the meaning of life, well... we just might not need any beans at all anymore. Who knows :-))
What I have is an AbstractAsynchActionHandler that is configable for all kinds of stuff. Should the node wait for MDB to complete, 'success'-, 'failure'- and 'retry'-transactions for the call back by the MDB etc. (As well as some other magic.) Then I have a AbstractAsynchMDB that implements the onMessage() method, parses out all things relevant for the jBPM signalling and passes on the payload of the Message to the implementing class. This only has to call the callbackAsynch() method with a 'success', 'failure' or 'retry' constant and the base class takes care of the rest. I have seperated all jBPM workflow code from the application code. The reason for this was seperating the transactions that contain the payload from the transactions that move the workflow. (If you persisted the processInstance in the payload MDB it would be all or nothing.) This basically means that ALL triggering of tokens happens by JMS and I only have a single MDB class (more than one instance) that exclusively accesses processInstances etc. So the 'meaning of live' MDB would send another Message back to the main jBPM MDB to signal the token. Gee... this sounds complicated (now I have to ask: does this make sense?) but it realy isn't. Its all about correct transaction handling and works very nicely in practice. As soon as I get around to checking out the 3.1 asynch stuff I'll see how the concepts fit. Greetings View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3924058#3924058 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3924058 ------------------------------------------------------- This SF.net email is sponsored by: Splunk Inc. Do you grep through log files for problems? Stop! Download the new AJAX search engine that makes searching your log files as easy as surfing the web. DOWNLOAD SPLUNK! http://sel.as-us.falkag.net/sel?cmd=lnk&kid=103432&bid=230486&dat=121642 _______________________________________________ JBoss-user mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/jboss-user
