I quickly went trough your unit test:

* You have at least 2 threads: the JUnit thread and x jobexecutor threads

* The JUnit thread does executes all your codes until the end. At that point, 
the teardown() message is called causing your processdefinition to be deleted.

* However, the JobExecutor thread is still around. Now he comes into play and 
tries to execute some activity of a process definition that doesn't exist 
anymore.

Hence, your error message ("deleted by another transaction")

Try to add Thread.sleep(10000) at the end of your unit test. It should work 
now. The reason why it works sometimes is because sometimes the jobexecutor is 
scheduled before the JUnit thread (damn parallel programming ;-)

Hope this helps

View the original post : 
http://www.jboss.org/index.html?module=bb&op=viewtopic&p=4251457#4251457

Reply to the post : 
http://www.jboss.org/index.html?module=bb&op=posting&mode=reply&p=4251457
_______________________________________________
jboss-user mailing list
jboss-user@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/jboss-user

Reply via email to