While deploying a new process via REST API, getting the following error- "
{
“type”: “ProcessEngineException”,
“message”: “ENGINE-01011 Cannot deploy process definition ‘Sales_Skeleton.bpmn’: there already is a message event subscription for the message with name ‘xyz’.”
}
"
I already have a different process which uses a same message name ‘xyz’ but that shouldn’t stop me from using the same message name in a different process.
If you have 2 processes with the same message start event the engine will not let you deploy it because it wouldn’t know which one to start when the message comes in.
Is it restriction by BPMN specification or is it a engine limitation? Ideally, in a real world modelling scenario I cannot think of a use case where I will need this but from a process engine perspective it shouldn’t not be a limitation. @Niall Your thoughts on this?
This adhears to the specification - in BPMN 2.0 a message must have a 1-to-1 correlation when sent. By deploying 2 processes which wait for the same message it would make a 1-to-1 correlation impossible.
Another way would be to use a signal event instead - this can have a 1-to-X correlation and so if you wanted to start multiple processes with the same event you would just use that.