Are you starting the process after loading the session? If so, then you are starting a new instance of the process. The first process is still waiting for the human task to be completed.<div><br></div><div>Best Regards,<br>

<div><br></div><div>Best Regards,<br clear="all"><br>XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX<br><br>Esteban Aliverti<br>- Developer @ <a href="http://www.plugtree.com" target="_blank">http://www.plugtree.com </a><br>
- Blog @ <a href="http://ilesteban.wordpress.com" target="_blank">http://ilesteban.wordpress.com</a><br>
<br><br><div class="gmail_quote">On Wed, Apr 6, 2011 at 10:00 AM, gs76pl <span dir="ltr">&lt;<a href="mailto:gstasica@pacemetrics.com" target="_blank">gstasica@pacemetrics.com</a>&gt;</span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">


hi,<br>
<br>
i&#39;ve a simple drools flow process with one workItem (its execute method<br>
simply prints some text) and one human task. I&#39;m using<br>
drools-persistence-jpa to save my process status and load it when<br>
process/server crashes.<br>
What i&#39;ve noticed is that:<br>
1. after starting process my processinfo table gets updated with a new<br>
process status (P1)<br>
2. my workItem (W1) runs correctly and prints a text<br>
3. a human task gets created<br>
 ----- when i stop my server at this point and restart my server executing<br>
below steps<br>
1. load the session using<br>
JPAKnowledgeService.loadStatefulKnowledgeSession(myPreviousSessionId,....)<br>
2. start the process<br>
<br>
At this point previously completed workItem (W1) gets executed once again<br>
and the same human task gets created !!<br>
<br>
I thought that perhaps the issue is with my transactionManager not<br>
committing steps but since i&#39;m using local transaction (commit happens after<br>
any process step) its very unlikely.<br>
Is it a bug that the same workItem gets executed or is it intentional and<br>
it&#39;s up to the developer to check somewhere else whether specific step has<br>
been already finished or not..?<br>
<font color="#888888"><br>
<br>
<br>
<br>
--<br>
View this message in context: <a href="http://drools-java-rules-engine.46999.n3.nabble.com/drools-flow-why-after-reloading-some-process-previously-completed-workItems-gets-executed-once-again-tp2784850p2784850.html" target="_blank">http://drools-java-rules-engine.46999.n3.nabble.com/drools-flow-why-after-reloading-some-process-previously-completed-workItems-gets-executed-once-again-tp2784850p2784850.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></div>
</div>