[jboss-user] [JBoss jBPM] - async processes : favour termination instead of inception

gogoasa do-not-reply at jboss.com
Wed Oct 3 05:04:17 EDT 2007


Hello,

I have a process that contains several nodes that may take a long time to execute (hours). I order to be able to have a trace of what's happening, I use asynchronous continuations (async="true" for the slow nodes). 

The whole things goes like this: a process initiator send lots (hundreds) of JMS StartProcessInstanceCommands on the jms/JbpmCommandQueue. The command queue is rapidly depleted by the CommandListenerBean which starts a new process and then starts the execution of the first node by sending a message to jms/JmsJobQueue. What happens next is that there are lots of processes that start and very few (if any) that finish. When the first node finishes, because of the async="true"behaviour, another jms message is sent to the JobQueue, at the end of the queue.

This way, for async processes, the start of new processes is favoured instead of finishing the already started. 

Do you have any idea on how to tackle this? 

As for me, I came up with the idea of associating a priority to a node which would be transferred to the JobCommand and then to the JMS message as a JMS priority parameter. Some modifications of jBPM are required though, so that sending a JMS message be done with the proper priority. You guys might have better ideas, I am eager to hear them...

Thank you.

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4090923#4090923

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4090923



More information about the jboss-user mailing list