Subprocess Start and End event ids incorrectly generated

Description

When creating sub processes, the start and end event id's are incorrect. Here is the generated BPMN2.0 code:
<subProcess id="subprocess1" name="Print Design">
<startEvent id="startevent2" name="Start"></startEvent>
<endEvent id="endevent2" name="End"></endEvent>

Sequence flows within the subprocess use the ids <subProcessid>_<start|end event id>
ex:
<sequenceFlow id="subprocess1_flow16" name="" sourceRef="subprocess1_startevent2" targetRef="subprocess1_usertask2"></sequenceFlow>
and
<sequenceFlow id="subprocess1_flow23" name="" sourceRef="subprocess1_usertask5" targetRef="subprocess1_endevent2"></sequenceFlow>

This causes deployment problems.

Invalid source 'subprocess1_startevent2' of sequence flow 'subprocess1_flow16' | diagrams/FutureStateWorkflow.activiti.bpmn20.xml | line 14 | column 123
Invalid destination 'subprocess1_endevent2' of sequence flow 'subprocess1_flow23' | diagrams/FutureStateWorkflow.activiti.bpmn20.xml | line 25 | column 121

Environment

Windows

Assignee

Tijs Rademakers

Reporter

Kostas Pagratis

Labels

None

Components

Fix versions

Affects versions

Priority

Blocker
Configure