Re: [rules-users] Process with subprocesses don't continue after finish work items in the subprocesses
Dirk, I tested out your example and I think this is working with the latest trunk, below is the output I received. Could you try your test case with the latest snapshot release, as this might be related to an issue that has already been fixed? http://hudson.jboss.org/hudson/job/drools/lastSuccessfulBuild/artifact/trunk/target/ Kris Super - Action (1/3) Execute Human Task: WorkItem 1 [name=Human Task, state=0, processInstanceId=1, parameters{}] Started process instance 1 Sub1 - Action (1/2) Execute Human Task: WorkItem 2 [name=Human Task, state=0, processInstanceId=2, parameters{}] Sub1 - Action (2/2) Super - Action (2/3) Sub2 - Action (1/3) Execute Human Task: WorkItem 3 [name=Human Task, state=0, processInstanceId=3, parameters{}] Sub1 - Action (1/2) Execute Human Task: WorkItem 4 [name=Human Task, state=0, processInstanceId=4, parameters{}] Sub1 - Action (2/2) Sub2 - Action (2/3) Execute Human Task: WorkItem 5 [name=Human Task, state=0, processInstanceId=3, parameters{}] Sub2 - Action (3/3) Execute Human Task: WorkItem 6 [name=Human Task, state=0, processInstanceId=1, parameters{}] Super - Action (3/3) - Original Message - From: "Dirk" To: Sent: Tuesday, February 23, 2010 4:39 PM Subject: Re: [rules-users] Process with subprocesses don't continue after finish work items in the subprocesses > > Hey Kris, > > I created a little demo-process with two subprocesses which covers my > problem. The flow should be Start - Super - Sub1 - Sub2 - Sub1 - Super - > End. But at runtime it is only Start - Super - Sub1 - End. > I think the test case is self-explanatory. > > Thank you for your efforts! > > Regards > Dirk http://n3.nabble.com/file/n404348/testcaseSubprocesses.zip > testcaseSubprocesses.zip > -- > View this message in context: > http://n3.nabble.com/Process-with-subprocesses-don-t-continue-after-finish-work-items-in-the-subprocesses-tp326801p404348.html > Sent from the Drools - User mailing list archive at Nabble.com. > ___ > rules-users mailing list > rules-users@lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users Disclaimer: http://www.kuleuven.be/cwis/email_disclaimer.htm ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
Re: [rules-users] Process with subprocesses don't continue after finish work items in the subprocesses
Hey Kris, I created a little demo-process with two subprocesses which covers my problem. The flow should be Start - Super - Sub1 - Sub2 - Sub1 - Super - End. But at runtime it is only Start - Super - Sub1 - End. I think the test case is self-explanatory. Thank you for your efforts! Regards Dirk http://n3.nabble.com/file/n404348/testcaseSubprocesses.zip testcaseSubprocesses.zip -- View this message in context: http://n3.nabble.com/Process-with-subprocesses-don-t-continue-after-finish-work-items-in-the-subprocesses-tp326801p404348.html Sent from the Drools - User mailing list archive at Nabble.com. ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
Re: [rules-users] Process with subprocesses don't continue after finish work items in the subprocesses
Hey Kris, I run the test and had some problems: 1. First I had empty workitems. I fix it by adding this line after creating and loading the session: ksession.getWorkItemManager().registerWorkItemHandler("Human Task", handler); But how could the test passed in your environment without this lines? 2. To use it I had to rearrage the order of the variable-definition. 3. The test fails at the last line: assertNull( processInstance ); Is this a problem? I'm not sure... Now I try to downsize my own prozess for this test... -- View this message in context: http://n3.nabble.com/Process-with-subprocesses-don-t-continue-after-finish-work-items-in-the-subprocesses-tp326801p378414.html Sent from the Drools - User mailing list archive at Nabble.com. ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
Re: [rules-users] Process with subprocesses don't continue after finish work items in the subprocesses
Dirk, There is a junit test testPersistenceSubProcess() that is testing exactly that use case: http://anonsvn.jboss.org/repos/labs/labs/jbossrules/trunk/drools-persistence-jpa/src/test/java/org/drools/persistence/session/PersistentStatefulSessionTest.java Could you create a simple test cases that reproduces this incorrect behaviour? Kris - Original Message - From: "Dirk" To: Sent: Monday, February 22, 2010 3:05 PM Subject: [rules-users] Process with subprocesses don't continue after finish work items in the subprocesses > > Hey Drools-Users, > > I've got a big and urgent problem with my drools process. I have a complex > process with many decisions and subprocesses. These subprocesses could > even > contains more subprocesses so that i have a four-level flow. > > I testet each subprocess isolated in a mock environment and now i get my > problem when they are combined in a big "super-process". I create the > process with the JPAKnowledgeService (and VariablePersistenceStrategy) and > everything works as expected. The process execute some actions, a > validation-subprocess and another subprocess with a human task (with a > custom handler). The process stops and persist all the variables (except > Integers; Must be a bug?). Perfect. Now I load the session with the > JPAKnowledgeService and complete the workitem with the > ksession.getWorkItemManager().completeWorkItem method. The subprocess now > execute to the end and then the engine stopps without an error. But there > are more steps in the superprocess todo. All subprocesse are "independent > = > true" with "wait for completion = true" and don't have timers. > > Has anybody an idea? Is this a known problem? I'm using the last > successfully build form the 21.02.2010. Do you need the process? (Then i > have to remove some internal information and could post it...) > > Many thanks in advance > Dirk > -- > View this message in context: > http://n3.nabble.com/Process-with-subprocesses-don-t-continue-after-finish-work-items-in-the-subprocesses-tp326801p326801.html > Sent from the Drools - User mailing list archive at Nabble.com. > ___ > rules-users mailing list > rules-users@lists.jboss.org > https://lists.jboss.org/mailman/listinfo/rules-users Disclaimer: http://www.kuleuven.be/cwis/email_disclaimer.htm ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users
[rules-users] Process with subprocesses don't continue after finish work items in the subprocesses
Hey Drools-Users, I've got a big and urgent problem with my drools process. I have a complex process with many decisions and subprocesses. These subprocesses could even contains more subprocesses so that i have a four-level flow. I testet each subprocess isolated in a mock environment and now i get my problem when they are combined in a big "super-process". I create the process with the JPAKnowledgeService (and VariablePersistenceStrategy) and everything works as expected. The process execute some actions, a validation-subprocess and another subprocess with a human task (with a custom handler). The process stops and persist all the variables (except Integers; Must be a bug?). Perfect. Now I load the session with the JPAKnowledgeService and complete the workitem with the ksession.getWorkItemManager().completeWorkItem method. The subprocess now execute to the end and then the engine stopps without an error. But there are more steps in the superprocess todo. All subprocesse are "independent = true" with "wait for completion = true" and don't have timers. Has anybody an idea? Is this a known problem? I'm using the last successfully build form the 21.02.2010. Do you need the process? (Then i have to remove some internal information and could post it...) Many thanks in advance Dirk -- View this message in context: http://n3.nabble.com/Process-with-subprocesses-don-t-continue-after-finish-work-items-in-the-subprocesses-tp326801p326801.html Sent from the Drools - User mailing list archive at Nabble.com. ___ rules-users mailing list rules-users@lists.jboss.org https://lists.jboss.org/mailman/listinfo/rules-users