cancel
Showing results for 
Search instead for 
Did you mean: 

Apply Activiti for old project

greencomet90
Champ in-the-making
Champ in-the-making
We have flow
start -> service task1 (object A state 1)-> user task 1 ->service task 2 (Object A change to state 2)-> user task2 -> ….
Currently, our project is not apply workflow. If now apply Activiti, the flow for Object A should start at service task 2, How can we achieve it ?

Thanks
3 REPLIES 3

jbarrez
Star Contributor
Star Contributor
With an exclusive gateway after process start that checks for the condition you want and then goes directly to service task 2?

greencomet90
Champ in-the-making
Champ in-the-making
Thanks for response, I think of that before. But my boss said that the flow (go direct to service task 2) is not in business, and we should get the sql code, of the Object A run from start to service task 2, then apply that sql to old variable (at state 2), to create history of old the object at state 2 in database like the history of Object A. Is the using of exclusive gateway the only way?

jbarrez
Star Contributor
Star Contributor
It's not the only way. It's code, so you can do whatever you want.
The sql route is possible, but it's kinda hacking. And hard to get 100% correct for all cases I believe.