javascriptjavabpmnflowable

Flowable runtimeService.startProcessInstanceByKey('MY_SUBPROCESS_KEY') executes but superProcessId null


After starting from my MY_SUPER_PROCESS another subprocess using the following syntax:

 runtimeService.startProcessInstanceByKey('MY_SUBPROCESS_KEY') 

the subprocess is started and executed correctly, but in the admin panel flowable panel there is no subprocess visible for MY_SUPER_PROCESS. Also asking about 'MY_SUBPROCESS_KEY' instance returns that superProcessInstanceId is null.

Is there any possibility to start the subprocess so that the information about super process and subprocess connection won't be lost?


Solution

  • Do you need to run the process via runtimeService? Try using callActivity.

    UPD:

    For start multi instance of subprocess in loop can use callActivity with Multi-instance marker.