[jBPM Users] - Re: workflow design about wait states
by mmusaji
Thanks for that Ronald, be a huge help if you can see what I'm doing wrong.
So I changed the async nodes (custom one and two) to takeDefaultTransition().
| package org.workflow.test.forum;
|
| import java.util.List;
| import java.util.Map;
|
| import org.jbpm.api.Execution;
| import org.jbpm.api.ProcessInstance;
| import org.jbpm.api.activity.ActivityExecution;
| import org.jbpm.api.activity.ExternalActivityBehaviour;
| import org.jbpm.api.job.Job;
| import org.jbpm.test.JbpmTestCase;
|
| public class ProcessTest extends JbpmTestCase {
| String deploymentDbid;
|
| protected void setUp() throws Exception {
| super.setUp();
| deploymentDbid = repositoryService.createDeployment()
| .addResourceFromClasspath("org/workflow/test/forum/process.jpdl.xml")
| .deploy();
| }
|
| protected void tearDown() throws Exception {
| repositoryService.deleteDeploymentCascade(deploymentDbid);
| super.tearDown();
| }
|
| public void testProcess() throws Exception {
| ProcessInstance processInstance = executionService.startProcessInstanceByKey("process");
| Execution executionInOne = processInstance.findActiveExecutionIn("custom one");
| assertNotNull(executionInOne);
| processInstance = executionService.signalExecutionById(executionInOne.getId());
|
| String processInstanceId = processInstance.getId();
|
| List<Job> jobs = managementService.createJobQuery()
| .processInstanceId(processInstanceId)
| .list();
|
| assertEquals(2, jobs.size());
|
| Job job = jobs.get(0);
|
| managementService.executeJob(job.getId());
|
| job = jobs.get(1);
|
| managementService.executeJob(job.getId());
|
| Execution executionInFour = processInstance.findActiveExecutionIn("custom four");
| assertNotNull(executionInFour);
| processInstance = executionService.signalExecutionById(executionInFour.getId());
| }
|
| public static class CustomOne implements ExternalActivityBehaviour {
| private static final long serialVersionUID = 1L;
|
| public void execute(ActivityExecution execution) throws Exception {
| System.out.println("Executing");
|
| System.out.println(execution.getActivityName());
|
| execution.waitForSignal();
| }
|
| public void signal(ActivityExecution execution,
| String signalName,
| Map<String, ?> parameters) {
| execution.take(signalName);
| }
| }
|
| public static class CustomTwo implements ExternalActivityBehaviour {
| private static final long serialVersionUID = 1L;
|
| public void execute(ActivityExecution execution) throws Exception {
| System.out.println("Executing");
|
| System.out.println(execution.getActivityName());
|
| execution.takeDefaultTransition();
| }
|
| public void signal(ActivityExecution execution,
| String signalName,
| Map<String, ?> parameters) {
| execution.take(signalName);
| }
| }
|
| public static class CustomThree implements ExternalActivityBehaviour {
| private static final long serialVersionUID = 1L;
|
| public void execute(ActivityExecution execution) throws Exception {
| System.out.println("Executing");
|
| System.out.println(execution.getActivityName());
|
| execution.takeDefaultTransition();
| }
|
| public void signal(ActivityExecution execution,
| String signalName,
| Map<String, ?> parameters) {
| execution.take(signalName);
| }
| }
|
| public static class CustomFour implements ExternalActivityBehaviour {
| private static final long serialVersionUID = 1L;
|
| public void execute(ActivityExecution execution) throws Exception {
| System.out.println("Executing");
|
| System.out.println(execution.getActivityName());
|
| execution.waitForSignal();
| }
|
| public void signal(ActivityExecution execution,
| String signalName,
| Map<String, ?> parameters) {
| execution.take(signalName);
| }
| }
|
| }
|
|
With the same workflow as before I get custom four node as showing output but still get null when the unittest attempts to find execution in this node.
| 13:58:02,975 FIN | [BaseJbpmTestCase] === starting testProcess =============================
| 13:58:03,100 FIN | [BaseJbpmTestCase] using ProcessEngine 22743805
| log4j:WARN No appenders could be found for logger (org.hibernate.cfg.Environment).
| log4j:WARN Please initialize the log4j system properly.
| 13:58:04,288 FIN | [ProcessDefinitionImpl] creating new execution for process 'process'
| 13:58:04,288 FIN | [DefaultIdGenerator] generated execution id process.222
| Executing
| custom one
| 13:58:04,288 FIN | [ExecuteActivity] executing activity(14731203)
| 13:58:04,288 FIN | [ExecuteActivity] executing activity(custom one)
| 13:58:04,303 FIN | [Signal] signalling activity(custom one), signalName=null
| 13:58:04,303 FIN | [ExecuteActivity] executing activity(fork)
| 13:58:04,303 FIN | [DefaultIdGenerator] generated execution id process.222.custom two
| 13:58:04,303 FIN | [ExecutionImpl] created execution[process.222.custom two]
| 13:58:04,319 FIN | [JobExecutorMessageSession] sending message ExecuteActivityMessage
| 13:58:04,319 INF | [JobExecutorThread] starting...
| 13:58:04,319 INF | [JobExecutorThread] starting...
| 13:58:04,319 INF | [JobExecutorThread] starting...
| 13:58:04,319 INF | [DispatcherThread] starting...
| 13:58:04,319 FIN | [DefaultIdGenerator] generated execution id process.222.custom three
| 13:58:04,319 FIN | [ExecutionImpl] created execution[process.222.custom three]
| 13:58:04,319 FIN | [JobExecutorMessageSession] sending message ExecuteActivityMessage
| 13:58:04,319 FIN | [AcquireJobsCmd] start querying first acquirable job...
| 13:58:04,319 FIN | [AcquireJobsCmd] locking jobs []
| 13:58:04,319 FIN | [GetNextDueDateCmd] getting next due date...
| 13:58:04,319 FIN | [GetNextDueDateCmd] next due date is null
| 13:58:04,319 FIN | [DispatcherThread] DispatcherThread will wait for max 600ms on org.jbpm.pvm.internal.jobexecutor.JobExecutor@1ff2e1b
| 13:58:04,319 FIN | [DispatcherThread] DispatcherThread woke up
| 13:58:04,335 FIN | [AcquireJobsCmd] start querying first acquirable job...
| 13:58:04,335 FIN | [AcquireJobsCmd] locking jobs [296]
| 13:58:04,335 FIN | [DispatcherThread] pushing jobs on the queue [296]
| 13:58:04,335 FIN | [DispatcherThread] added jobs [296] to the queue
| 13:58:04,335 FIN | [AcquireJobsCmd] start querying first acquirable job...
| 13:58:04,335 FIN | [AcquireJobsCmd] locking jobs [297]
| 13:58:04,335 FIN | [ExecuteJobCmd] executing job ExecuteActivityMessage[296]...
| 13:58:04,335 FIN | [JobExecutorThread] took job(s) [296] from queue
| 13:58:04,335 FIN | [DispatcherThread] pushing jobs on the queue [297]
| 13:58:04,335 FIN | [DispatcherThread] added jobs [297] to the queue
| 13:58:04,335 FIN | [AcquireJobsCmd] start querying first acquirable job...
| 13:58:04,350 FIN | [AcquireJobsCmd] locking jobs []
| 13:58:04,350 FIN | [GetNextDueDateCmd] getting next due date...
| 13:58:04,350 FIN | [GetNextDueDateCmd] next due date is null
| 13:58:04,350 FIN | [DispatcherThread] DispatcherThread will wait for max 600ms on org.jbpm.pvm.internal.jobexecutor.JobExecutor@1ff2e1b
| Executing
| custom two
| 13:58:04,350 FIN | [ExecuteActivity] execution[process.222.custom two] executes activity(custom two)
| 13:58:04,350 FIN | [JobExecutorThread] took job(s) [297] from queue
| 13:58:04,350 FIN | [JobExecutorMessageSession] sending message ExecuteActivityMessage
| 13:58:04,350 FIN | [ExecuteJobCmd] executing job ExecuteActivityMessage[297]...
| Executing
| custom three
| 13:58:04,350 FIN | [ExecuteJobCmd] executed job ExecuteActivityMessage[296]
| 13:58:04,366 FIN | [ExecuteActivity] execution[process.222.custom three] executes activity(custom three)
| 13:58:04,366 FIN | [JobExecutorMessageSession] sending message ExecuteActivityMessage
| 13:58:04,366 FIN | [ExecuteJobCmd] executed job ExecuteActivityMessage[297]
| 13:58:04,366 FIN | [ExecuteJobCmd] executing job ExecuteActivityMessage[297]...
| 13:58:04,366 FIN | [ExecuteJobCmd] job 296 no longer exists
| Executing
| custom three
| 13:58:04,366 FIN | [DispatcherThread] DispatcherThread woke up
| 13:58:04,366 FIN | [AcquireJobsCmd] start querying first acquirable job...
| 13:58:04,366 FIN | [ExecuteActivity] execution[process.222.custom three] executes activity(custom three)
| 13:58:04,366 FIN | [JobExecutorMessageSession] sending message ExecuteActivityMessage
| 13:58:04,366 FIN | [ExecuteJobCmd] executed job ExecuteActivityMessage[297]
| 13:58:04,381 FIN | [AcquireJobsCmd] locking jobs [298, 299]
| 13:58:04,381 FIN | [DispatcherThread] pushing jobs on the queue [298, 299]
| 13:58:04,381 FIN | [DispatcherThread] added jobs [298, 299] to the queue
| 13:58:04,381 FIN | [JobExecutorThread] took job(s) [298, 299] from queue
| 13:58:04,381 FIN | [AcquireJobsCmd] start querying first acquirable job...
| 13:58:04,381 FIN | [AcquireJobsCmd] locking jobs []
| 13:58:04,381 FIN | [GetNextDueDateCmd] getting next due date...
| 13:58:04,381 FIN | [ExecuteJobCmd] executing job ExecuteActivityMessage[298]...
| 13:58:04,381 FIN | [GetNextDueDateCmd] next due date is null
| 13:58:04,381 FIN | [DispatcherThread] DispatcherThread will wait for max 600ms on org.jbpm.pvm.internal.jobexecutor.JobExecutor@1ff2e1b
| 13:58:04,381 FIN | [ExecuteActivity] execution[process.222.custom two] executes activity(join)
| 13:58:04,381 FIN | [ExecuteJobCmd] executed job ExecuteActivityMessage[298]
| 13:58:04,381 FIN | [ExecuteJobCmd] executing job ExecuteActivityMessage[299]...
| 13:58:04,397 FIN | [ExecuteActivity] execution[process.222.custom three] executes activity(join)
| 13:58:04,397 FIN | [ExecutionImpl] execution[process.222.custom two] ends
| 13:58:04,397 FIN | [ExecutionImpl] execution[process.222.custom three] ends
| 13:58:04,397 FIN | [ExecuteActivity] executing activity(custom four)
| Executing
| custom four
| 13:58:04,397 FIN | [ExecuteJobCmd] executed job ExecuteActivityMessage[299]
| 13:58:04,428 FIN | [ExecuteJobCmd] job 297 no longer exists
| 13:58:04,428 SEV | [BaseJbpmTestCase]
| ### EXCEPTION ###########################################
| 13:58:04,428 SEV | [BaseJbpmTestCase] ASSERTION FAILURE: null
| junit.framework.AssertionFailedError
| at junit.framework.Assert.fail(Assert.java:47)
| at junit.framework.Assert.assertTrue(Assert.java:20)
| at junit.framework.Assert.assertNotNull(Assert.java:220)
| at junit.framework.Assert.assertNotNull(Assert.java:213)
| at org.workflow.test.forum.ProcessTest.testProcess(ProcessTest.java:51)
| at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
| at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
| at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
| at java.lang.reflect.Method.invoke(Method.java:597)
| at junit.framework.TestCase.runTest(TestCase.java:154)
| at org.jbpm.test.BaseJbpmTestCase.runTest(BaseJbpmTestCase.java:80)
| at junit.framework.TestCase.runBare(TestCase.java:127)
| at junit.framework.TestResult$1.protect(TestResult.java:106)
| at junit.framework.TestResult.runProtected(TestResult.java:124)
| at junit.framework.TestResult.run(TestResult.java:109)
| at junit.framework.TestCase.run(TestCase.java:118)
| at junit.framework.TestSuite.runTest(TestSuite.java:208)
| at junit.framework.TestSuite.run(TestSuite.java:203)
| at org.eclipse.jdt.internal.junit.runner.junit3.JUnit3TestReference.run(JUnit3TestReference.java:130)
| at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
| at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:460)
| at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:673)
| at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:386)
| at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:196)
| ### EXCEPTION ###########################################
| 13:58:04,428 SEV | [BaseJbpmTestCase]
| 13:58:04,444 FIN | [DbSessionImpl] deleting history process instance process.222
| 13:58:04,460 FIN | [DbSessionImpl] deleting process instance process.222
| 13:58:04,460 FIN | [DeleteDeploymentCmd] deleting deployment 109
| 13:58:04,475 FIN | [BaseJbpmTestCase] === ending testProcess =============================
|
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4255090#4255090
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4255090
16 years, 7 months
[jBPM Users] - Re: workflow design about wait states
by mmusaji
Okay so I took your advice and went back to basics. What I'm finding is if i have a node after the join (in my my case a custom node), the Unit test fails to find the execution in this. With a join going straight to an end it is ok.
My workflow:
| <?xml version="1.0" encoding="UTF-8"?>
|
| <process name="process" xmlns="http://jbpm.org/4.0/jpdl">
| <start>
| <transition to="custom one"/>
| </start>
|
| <custom class="org.workflow.test.forum.ProcessTest$CustomOne" name="custom one">
| <transition to="fork"/>
| </custom>
|
| <fork name="fork">
| <transition name="custom two" to="custom two"/>
| <transition name="custom three" to="custom three"/>
| </fork>
|
| <custom continue="async" name="custom two" class="org.workflow.test.forum.ProcessTest$CustomTwo">
| <transition to="join"/>
| </custom>
|
| <custom continue="async" name="custom three" class="org.workflow.test.forum.ProcessTest$CustomThree">
| <transition to="join"/>
| </custom>
|
| <join name="join">
| <transition name="custom four" to="custom four"/>
| </join>
|
| <custom name="custom four" class="org.workflow.test.forum.ProcessTest$CustomFour">
| <transition to="end"/>
| </custom>
|
| <task name="end">
| <transition name="to complete" to="end process"/>
| </task>
|
| <end name="end process" state="complete"/>
|
| </process>
|
I can't figure out how to test the custom four node. Without this things are working as expected but to me it seems like my unit test stops at the join and doesn't signal the workflow to carry on?
| package org.workflow.test.forum;
|
| import java.util.List;
| import java.util.Map;
|
| import org.jbpm.api.Execution;
| import org.jbpm.api.ProcessInstance;
| import org.jbpm.api.activity.ActivityExecution;
| import org.jbpm.api.activity.ExternalActivityBehaviour;
| import org.jbpm.api.job.Job;
| import org.jbpm.test.JbpmTestCase;
|
| public class ProcessTest extends JbpmTestCase {
| String deploymentDbid;
|
| protected void setUp() throws Exception {
| super.setUp();
| deploymentDbid = repositoryService.createDeployment()
| .addResourceFromClasspath("org/workflow/test/forum/process.jpdl.xml")
| .deploy();
| }
|
| protected void tearDown() throws Exception {
| repositoryService.deleteDeploymentCascade(deploymentDbid);
| super.tearDown();
| }
|
| public void testProcess() throws Exception {
| ProcessInstance processInstance = executionService.startProcessInstanceByKey("process");
| Execution executionInOne = processInstance.findActiveExecutionIn("custom one");
| assertNotNull(executionInOne);
| processInstance = executionService.signalExecutionById(executionInOne.getId());
|
| String processInstanceId = processInstance.getId();
|
| List<Job> jobs = managementService.createJobQuery()
| .processInstanceId(processInstanceId)
| .list();
|
| assertEquals(2, jobs.size());
|
| Job job = jobs.get(0);
|
| managementService.executeJob(job.getId());
|
| job = jobs.get(1);
|
| managementService.executeJob(job.getId());
|
| Execution executionInFour = processInstance.findActiveExecutionIn("custom four");
| assertNotNull(executionInFour);
| processInstance = executionService.signalExecutionById(executionInFour.getId());
| }
|
| public static class CustomOne implements ExternalActivityBehaviour {
| private static final long serialVersionUID = 1L;
|
| public void execute(ActivityExecution execution) throws Exception {
| System.out.println("Executing");
|
| System.out.println(execution.getActivityName());
|
| execution.waitForSignal();
| }
|
| public void signal(ActivityExecution execution,
| String signalName,
| Map<String, ?> parameters) {
| execution.take(signalName);
| }
| }
|
| public static class CustomTwo implements ExternalActivityBehaviour {
| private static final long serialVersionUID = 1L;
|
| public void execute(ActivityExecution execution) throws Exception {
| System.out.println("Executing");
|
| System.out.println(execution.getActivityName());
|
| execution.waitForSignal();
| }
|
| public void signal(ActivityExecution execution,
| String signalName,
| Map<String, ?> parameters) {
| execution.take(signalName);
| }
| }
|
| public static class CustomThree implements ExternalActivityBehaviour {
| private static final long serialVersionUID = 1L;
|
| public void execute(ActivityExecution execution) throws Exception {
| System.out.println("Executing");
|
| System.out.println(execution.getActivityName());
|
| execution.waitForSignal();
| }
|
| public void signal(ActivityExecution execution,
| String signalName,
| Map<String, ?> parameters) {
| execution.take(signalName);
| }
| }
|
| public static class CustomFour implements ExternalActivityBehaviour {
| private static final long serialVersionUID = 1L;
|
| public void execute(ActivityExecution execution) throws Exception {
| System.out.println("Executing");
|
| System.out.println(execution.getActivityName());
|
| execution.waitForSignal();
| }
|
| public void signal(ActivityExecution execution,
| String signalName,
| Map<String, ?> parameters) {
| execution.take(signalName);
| }
| }
|
| }
|
|
Output:
| 12:44:53,841 FIN | [BaseJbpmTestCase] === starting testProcess =============================
| 12:44:53,981 FIN | [BaseJbpmTestCase] using ProcessEngine 78236
| log4j:WARN No appenders could be found for logger (org.hibernate.cfg.Environment).
| log4j:WARN Please initialize the log4j system properly.
| 12:44:55,122 FIN | [ProcessDefinitionImpl] creating new execution for process 'process'
| 12:44:55,122 FIN | [DefaultIdGenerator] generated execution id process.149
| Executing
| custom one
| 12:44:55,122 FIN | [ExecuteActivity] executing activity(12319324)
| 12:44:55,122 FIN | [ExecuteActivity] executing activity(custom one)
| 12:44:55,137 FIN | [Signal] signalling activity(custom one), signalName=null
| 12:44:55,137 FIN | [ExecuteActivity] executing activity(fork)
| 12:44:55,137 FIN | [DefaultIdGenerator] generated execution id process.149.custom two
| 12:44:55,137 FIN | [ExecutionImpl] created execution[process.149.custom two]
| 12:44:55,137 FIN | [JobExecutorMessageSession] sending message ExecuteActivityMessage
| 12:44:55,153 INF | [JobExecutorThread] starting...
| 12:44:55,153 INF | [JobExecutorThread] starting...
| 12:44:55,153 INF | [JobExecutorThread] starting...
| 12:44:55,153 INF | [DispatcherThread] starting...
| 12:44:55,153 FIN | [DefaultIdGenerator] generated execution id process.149.custom three
| 12:44:55,153 FIN | [ExecutionImpl] created execution[process.149.custom three]
| 12:44:55,153 FIN | [JobExecutorMessageSession] sending message ExecuteActivityMessage
| 12:44:55,153 FIN | [AcquireJobsCmd] start querying first acquirable job...
| 12:44:55,153 FIN | [AcquireJobsCmd] locking jobs []
| 12:44:55,153 FIN | [GetNextDueDateCmd] getting next due date...
| 12:44:55,153 FIN | [GetNextDueDateCmd] next due date is null
| 12:44:55,153 FIN | [DispatcherThread] DispatcherThread will wait for max 600ms on org.jbpm.pvm.internal.jobexecutor.JobExecutor@1d27069
| 12:44:55,153 FIN | [DispatcherThread] DispatcherThread woke up
| 12:44:55,153 FIN | [AcquireJobsCmd] start querying first acquirable job...
| 12:44:55,169 FIN | [AcquireJobsCmd] locking jobs [184]
| 12:44:55,169 FIN | [ExecuteJobCmd] executing job ExecuteActivityMessage[184]...
| 12:44:55,169 FIN | [DispatcherThread] pushing jobs on the queue [184]
| 12:44:55,169 FIN | [DispatcherThread] added jobs [184] to the queue
| 12:44:55,169 FIN | [AcquireJobsCmd] start querying first acquirable job...
| Executing
| custom two
| 12:44:55,169 FIN | [JobExecutorThread] took job(s) [184] from queue
| 12:44:55,169 FIN | [AcquireJobsCmd] locking jobs [185]
| 12:44:55,184 FIN | [ExecuteActivity] execution[process.149.custom two] executes activity(custom two)
| 12:44:55,184 FIN | [DispatcherThread] pushing jobs on the queue [185]
| 12:44:55,184 FIN | [DispatcherThread] added jobs [185] to the queue
| 12:44:55,184 FIN | [AcquireJobsCmd] start querying first acquirable job...
| 12:44:55,184 FIN | [ExecuteJobCmd] executed job ExecuteActivityMessage[184]
| 12:44:55,184 FIN | [AcquireJobsCmd] locking jobs []
| 12:44:55,184 FIN | [GetNextDueDateCmd] getting next due date...
| 12:44:55,184 FIN | [GetNextDueDateCmd] next due date is null
| 12:44:55,184 FIN | [DispatcherThread] DispatcherThread will wait for max 600ms on org.jbpm.pvm.internal.jobexecutor.JobExecutor@1d27069
| 12:44:55,184 FIN | [JobExecutorThread] took job(s) [185] from queue
| 12:44:55,231 FIN | [ExecuteJobCmd] executing job ExecuteActivityMessage[185]...
| Executing
| custom three
| 12:44:55,231 FIN | [ExecuteJobCmd] executing job ExecuteActivityMessage[184]...
| 12:44:55,231 FIN | [ExecuteActivity] execution[process.149.custom three] executes activity(custom three)
| 12:44:55,231 FIN | [ExecuteJobCmd] executed job ExecuteActivityMessage[185]
| 12:44:55,247 FIN | [ExecuteJobCmd] executing job ExecuteActivityMessage[184]...
| Executing
| custom two
| 12:44:55,247 FIN | [ExecuteActivity] execution[process.149.custom two] executes activity(custom two)
| 12:44:55,247 FIN | [ExecuteJobCmd] executed job ExecuteActivityMessage[184]
| 12:44:55,247 FIN | [ExecuteActivity] execution[process.149.custom two] executes activity(custom two)
| Executing
| custom two
| 12:44:55,247 FIN | [ExecuteJobCmd] executed job ExecuteActivityMessage[184]
| 12:44:55,450 FIN | [ExecuteJobCmd] job 184 no longer exists
| 12:44:55,450 FIN | [ExecuteJobCmd] job 185 no longer exists
| 12:44:55,450 SEV | [BaseJbpmTestCase]
| ### EXCEPTION ###########################################
| 12:44:55,466 SEV | [BaseJbpmTestCase] ASSERTION FAILURE: null
| junit.framework.AssertionFailedError
| at junit.framework.Assert.fail(Assert.java:47)
| at junit.framework.Assert.assertTrue(Assert.java:20)
| at junit.framework.Assert.assertNotNull(Assert.java:220)
| at junit.framework.Assert.assertNotNull(Assert.java:213)
| at org.workflow.test.forum.ProcessTest.testProcess(ProcessTest.java:51)
| at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
| at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
| at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
| at java.lang.reflect.Method.invoke(Method.java:597)
| at junit.framework.TestCase.runTest(TestCase.java:154)
| at org.jbpm.test.BaseJbpmTestCase.runTest(BaseJbpmTestCase.java:80)
| at junit.framework.TestCase.runBare(TestCase.java:127)
| at junit.framework.TestResult$1.protect(TestResult.java:106)
| at junit.framework.TestResult.runProtected(TestResult.java:124)
| at junit.framework.TestResult.run(TestResult.java:109)
| at junit.framework.TestCase.run(TestCase.java:118)
| at junit.framework.TestSuite.runTest(TestSuite.java:208)
| at junit.framework.TestSuite.run(TestSuite.java:203)
| at org.eclipse.jdt.internal.junit.runner.junit3.JUnit3TestReference.run(JUnit3TestReference.java:130)
| at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
| at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:460)
| at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:673)
| at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:386)
| at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:196)
| ### EXCEPTION ###########################################
| 12:44:55,466 SEV | [BaseJbpmTestCase]
| 12:44:55,481 FIN | [DbSessionImpl] deleting history process instance process.149
| 12:44:55,497 FIN | [DbSessionImpl] deleting process instance process.149
| 12:44:55,497 FIN | [DeleteDeploymentCmd] deleting deployment 87
| 12:44:55,528 FIN | [BaseJbpmTestCase] === ending testProcess =============================
|
Also are the classes being called twice? Is it once by the startProcessInstanceByKey and then again my the job in the unit tests?
View the original post : http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4255065#4255065
Reply to the post : http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4255065
16 years, 7 months