Hi,
I’m trying to test catching signals on the boundary of a subprocess (as a mechanism for breaking out of the subprocess). My test process looks like:
The signal definition is scoped to “processInstance”, as I want to target a specific process instance. When I send the signal via the runtimeService, I use the overloaded signalEventReceived(signalName, executionId), with the executionId being the process instance ID.
I get the following error: Execution ‘7505’ has not subscribed to a signal event with name ‘signal-foo’.
Is this telling me that the process instance itself has no subscription to the signal, because it is the subprocess that has the subscription? Would this work if instead I supplied the ID of the subprocess execution to signalEventReceived? The problem with this is that I don’t have access to the subprocess ID in my particular use case. All I have is the overall process ID. My hope was that sending the signal to a specific process ID would end up delivering the signal to any catching signals within the scope of that process (ie including sub processes), but this seems not to be the case.
Any idea how I can fix this to make it work? All I really want to do is fire some sort of signal or message that lets me short-circuit out of a subprocess that is sitting in a wait state.
Thanks,
Shannon