cancel
Showing results for 
Search instead for 
Did you mean: 

Way to start an process instance id programmatically with super process instance

joshting
Champ in-the-making
Champ in-the-making
Hope someone can shed some light on this.

I am implementing a sub process that act as a broker to start a process instance by message event.  In it is basically a service task and a intermediate message catching event that uses:

startProcessInstanceByMessage(messageEventName, processVariables)

The purpose is to decouple the sub processes from the top level BPMN so that they can be updated independently without full re-deployment.

However, this means that the sub process started will be orphaned and does not have relationship with the actual parent.  There is no method currently in the Activiti engine that allows me to start the process instance by specifying the parent process.

My question is if there is an easy way to do this without doing anything drastic like extending Activiti codes.  Is there a method that can manually start an instance (call activity) and specifying its parent (the process that calls the call activity).
1 REPLY 1

martin_grofcik
Confirmed Champ
Confirmed Champ
Hi joshting,


startProcessInstanceByMessage(messageEventName, processVariables)

add parent process instance id to the process variables.

Regards
Martin