cancel
Showing results for 
Search instead for 
Did you mean: 

workflow engine transaction

luisalves00
Champ in-the-making
Champ in-the-making
hello,


I'm wondering if it's possible to delete on workflow and start another in one transaction:

deleteCancelationWorkflow(String.valueOf(pc.getIdWorkflow())); //delete previous…can I have a transaction here?
invokeRecoverWorkflow(pc);//start the new one…

not that they are different workflows….
5 REPLIES 5

trademak
Star Contributor
Star Contributor
Sure, this is provided by the Activiti Spring module, but also by using the new Activiti CDI module (>= 5.8) in a JEE 6 environment.
So you can delete a process instance and create a new process instance with independent process definitions within the same transaction.

Best regards,

luisalves00
Champ in-the-making
Champ in-the-making
can you give me a sample code? (without CDI)

trademak
Star Contributor
Star Contributor
Have you looked here: http://activiti.org/userguide/index.html#N104AB ?

Best regards,

luisalves00
Champ in-the-making
Champ in-the-making
I'm not using Spring…:/

prevoj
Champ in-the-making
Champ in-the-making
Hey luisalves00 (or anybody),

Did you ever get an answer to this? We're trying to use Activiti in our standalone app without Spring and we are trying to do a transaction around several operations as well.