[jboss-user] [JBoss jBPM] - Dynamically creating task * nodes * for each group of actor

elifarley do-not-reply at jboss.com
Fri Feb 6 15:57:48 EST 2009


Consider the following pseudo code:


  | 
  | // List whose elements are arrays of actor ids.
  | // Its contents are not known in advance
  | List<String[]> listOfArrays = { {"actor-A", "actor-B"}, {"actor-C", "actor-D"} };
  | 
  | for (String[] actorIds : listOfArrays ) {
  | 
  |   ! create a task-node assigned to all actors in actorIds;
  |   ! wait until any of those actors completes his/her task by selecting either YES or NO;
  |   ! If the actor selected "NO", abort.  Otherwise, continue. 
  | 
  | }
  | 
  | 

Example of execution:


  | 
  | List<String[]> listOfArrays = { {"actor-A", "actor-B"}, {"actor-C", "actor-D"} };
  | 
  | ! create task node assigned to {"actor-A", "actor-B"};
  | ! wait for the task to be completed by either actor;
  | (Suppose actor selected "YES")
  | ! create task node assigned to {"actor-C", "actor-D"};
  | ! wait for the task to be completed by either actor;
  | (Suppose actor selected "YES")
  | ! Done.
  | 
  | 


What would be the best way to implement this with jBPM ?

Maybe there's a way of achieving the same goal without creating task nodes...

Thanks for any ideas you may have.

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

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



More information about the jboss-user mailing list