[jboss-user] [jBPM] - Difficult workflow question

John Bize do-not-reply at jboss.com
Wed Mar 28 15:11:23 EDT 2012


John Bize [https://community.jboss.org/people/jbize] created the discussion

"Difficult workflow question"

To view the discussion, visit: https://community.jboss.org/message/727034#727034

--------------------------------------------------------------
I am attempting to handle what to me is a difficult workflow problem.  I believe a good metaphore for this process is: "Who's got the button?"  There are multiple buttons with different descriptions.  There are several working teams that may have the button, but it's possible that no one has it.

So, a user connects to our system and submits a form asking "who's got the button?"  The form can describe the button by composition (plastic, bone, etc.), color, size, age, etc.  (The user does his best to add enough detail.)  Since there aren't too many buttons, sometimes just composition or age is sufficient for identification, but sometimes not.  So, the request first goes to the user's supervisor (group) to validate that the request is valid and sufficient in detail (Human Task 1).  The supervisor may reject the request for a number of reasons or approve it.  If approved, an email is sent to all the teams (currently only 2) that might currently have the button.  Here I split the workflow to two more human tasks.  (I actually put these in an embedded sub-process.)  For each of these team requests (human tasks), the response may be: "*Not Me*," "*Need Additional Info* (e.g. color)", or "*Yes I have it*."  I recombined the workflow, but the answers are relevant to how the workflow procedes:  If both answer "No," (happy path) the supervisor is notified, and the process completes.  If neither answer "Yes," but at least one asks for additional information, the request is pushed back to the previous step.  However, if one team answers "Yes," the process must complete and the other pending human task(s) must be cancelled (or completed) and the supervisor must be notified immediately and the process ends.

I hasven't even decided the best way to handle the "need more info" results. For right now, I need to know the correct way to cleanly end the other pending human tasks once one answers "yes."

I have tried quite a few different things such as events and errors, but nothing seems correct.

Any and all help is sincerely appreciated.

I'll resummarize the flow (code and image are not available):
* User submits request (start process)
* Supervisor approves or rejects (HT-1) (followed by xor gateway for decision flow)
* Diverge Gateway (AND)
* Simultaneously ask Team 1 and 2 (HT-2 & HT-3)
* Converge Gateway (AND) if results are No or Need More Info
* *BUT if either HT response is Yes, other HT is immediately ended (cancelled or stopped), and the process continues*
* Supervisor receives notification for subsequent action (HT-4)
--------------------------------------------------------------

Reply to this message by going to Community
[https://community.jboss.org/message/727034#727034]

Start a new discussion in jBPM at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2034]

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-user/attachments/20120328/a541f227/attachment.html 


More information about the jboss-user mailing list