startProcessInstanceByMessage - how to access the Map variables?


I am trying to start one diagram by sending a message from another diagram using this method:

ProcessInstance startProcessInstanceByMessage(String messageName, Map<String, Object> processVariables);

That method is mentioned in the docs here

I’ve got it working so that the second diagram is starting up, but I can’t figure out how to access the items in the processVariables Map from service tasks in the second diagram.



key used in map = variable name.

So you can refer as ${key} in your model.