Hi Anatoly,<br>1. Yes<br>2. based on the work item id it will know how to complete each of them<br>it's business related in my perspective, if you for example send something to process in an external system, you will end up with workitemid related with that process/external system. In such cases if you want to create a mechanism decoupled from your external system, you need to keep track(build your own mechanism) to handle that information. <br>
add me to skype if you want to discuss about it.. we can discuss about how to create something that works for you.<br>(skype: salaboy21)<br><br><div class="gmail_quote">On Mon, May 3, 2010 at 3:22 PM, tolitius <span dir="ltr"><<a href="mailto:webakaunt@gmail.com" target="_blank">webakaunt@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;"><br>
Hey Drools Crew,<br>
<br>
Business process can be designed to have more the one workitem ( human<br>
task ) with the same name. So two questions here:<br>
<br>
1. Confirming: "When registering handlers all of the workitems with<br>
the same name will use the same ( registered to the name ) handler?"<br>
<br>
2. What is the way for the client to identify the workitem in this<br>
case? Let's say there is a "truly" parallel definition:<br>
<br>
/---> workitem1 ( async send to external<br>
system, waiting for completion )<br>
split ----> workitem2 ( async send to external<br>
system, waiting for completion )<br>
\---> workitem3 ( async send to external<br>
system, waiting for completion )<br>
<br>
If workitem1 and workitem3 have the same name, and the response<br>
came back for workitem3, how do the client know to "complete" workitem3 vs.<br>
workitem1?<br>
<br>
Workitem IDs are completely workflow / drools-flow related, and<br>
when ( let's say ) approval has returned from an external system, a client<br>
should just tell one of the business workflow services to:<br>
<br>
completeApprovalFor( ExternalSystem.SuchAndSuch )<br>
<br>
workflow service will have a handler to a workflowInstance<br>
{ businessId, sessionId, processInstanceId, List<Work items in progress>,<br>
etc.. }, so if it is a single workitem the process is waiting for, there is<br>
no problem, but if there are more workitems that make the process to wait +<br>
they may have the same name, it creates a problem.<br>
<br>
One solution (for the above specific case) would be to link external<br>
systems with work item ids, so instead of List< Workitems in progress >, it<br>
would be Map< ExternalSystem, Workitem >. But it just looks to complex and<br>
specific...<br>
<br>
Anything the framework can help with?<br>
<br>
Thank you,<br>
/Anatoly<br>
<font color="#888888">--<br>
View this message in context: <a href="http://drools-java-rules-engine.46999.n3.nabble.com/Drools-Flow-Workitems-with-the-same-name-tp774182p774182.html" target="_blank">http://drools-java-rules-engine.46999.n3.nabble.com/Drools-Flow-Workitems-with-the-same-name-tp774182p774182.html</a><br>
Sent from the Drools - User mailing list archive at Nabble.com.<br>
_______________________________________________<br>
rules-users mailing list<br>
<a href="mailto:rules-users@lists.jboss.org" target="_blank">rules-users@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/rules-users" target="_blank">https://lists.jboss.org/mailman/listinfo/rules-users</a><br>
</font></blockquote></div><br><br clear="all"><br>-- <br> - <a href="http://salaboy.wordpress.com" target="_blank">http://salaboy.wordpress.com</a><br> - <a href="http://www.jbug.com.ar" target="_blank">http://www.jbug.com.ar</a><br>
- Salatino "Salaboy" Mauricio -<br>