Status: Resolved (View Workflow)
Affects Version/s: jBPM 4.3
Fix Version/s: jBPM 4.4
There is a potential risk of wrong usage of sub process execution that seems like it was not tested.
Please consider following scenario:
- there are two processes (main and sub)
- both of them have states somewhere in the execution
- subprocess goes into wait state
- user wants to signal it but there is no reference to it available via public API
- user tries to signal using main process instance
- no exception is thrown
Potential misuse would be to call signal method using main process instance which will in fact move on with execution leaving unfinished sub process instance.
Solution to this issue could be as follows:
- expose method getSubProcessInstance on Execution (public API)
- disable direct signal on sub process activity from the API when it is in active state
- create an example and document it in user guide
I have already tested that and it seems to work properly.
If no objections, will finish with docs and examples and put it to repository.