Merge "Fix to use common MsoLogger"
[so.git] / bpmn / so-bpmn-building-blocks / src / main / resources / subprocess / BuildingBlock / ExecuteBuildingBlock.bpmn
1 <?xml version="1.0" encoding="UTF-8"?>
2 <bpmn:definitions xmlns:bpmn="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:camunda="http://camunda.org/schema/1.0/bpmn" id="Definitions_1" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="1.10.0">
3   <bpmn:process id="ExecuteBuildingBlock" name="ExecuteBuildingBlock" isExecutable="true">
4     <bpmn:startEvent id="Start_ExecuteBuildingBlock" name="start">
5       <bpmn:outgoing>SequenceFlow_0rq4c5r</bpmn:outgoing>
6     </bpmn:startEvent>
7     <bpmn:callActivity id="Call_BBToExecute" name="BB to Execute" calledElement="${flowToBeCalled}">
8       <bpmn:extensionElements>
9         <camunda:in source="gBuildingBlockExecution" target="gBuildingBlockExecution" />
10         <camunda:out source="WorkflowException" target="WorkflowException" />
11         <camunda:in source="mso-request-id" target="mso-request-id" />
12       </bpmn:extensionElements>
13       <bpmn:incoming>Continue</bpmn:incoming>
14       <bpmn:outgoing>SequenceFlow_01h9qmz</bpmn:outgoing>
15     </bpmn:callActivity>
16     <bpmn:sequenceFlow id="SequenceFlow_0rq4c5r" sourceRef="Start_ExecuteBuildingBlock" targetRef="Task_BBInputSetup" />
17     <bpmn:sequenceFlow id="SequenceFlow_0uzwjrq" sourceRef="Task_BBInputSetup" targetRef="StatusPolicy" />
18     <bpmn:serviceTask id="Task_BBInputSetup" name="BB Input Setup" camunda:expression="${BBInputSetup.execute(execution)}">
19       <bpmn:incoming>SequenceFlow_0rq4c5r</bpmn:incoming>
20       <bpmn:outgoing>SequenceFlow_0uzwjrq</bpmn:outgoing>
21     </bpmn:serviceTask>
22     <bpmn:endEvent id="End_ExecuteBuildingBlock" name="end">
23       <bpmn:incoming>SequenceFlow_01h9qmz</bpmn:incoming>
24       <bpmn:incoming>SequenceFlow_1ryv9sh</bpmn:incoming>
25     </bpmn:endEvent>
26     <bpmn:sequenceFlow id="SequenceFlow_01h9qmz" sourceRef="Call_BBToExecute" targetRef="End_ExecuteBuildingBlock" />
27     <bpmn:sequenceFlow id="Continue" name="Continue" sourceRef="CheckOrchestrationStatusValidationResults" targetRef="Call_BBToExecute" />
28     <bpmn:serviceTask id="StatusPolicy" name="StatusPolicy" camunda:expression="${OrchestrationStatusValidator.validateOrchestrationStatus(InjectExecution.execute(execution, execution.getVariable(&#34;gBuildingBlockExecution&#34;)))}">
29       <bpmn:incoming>SequenceFlow_0uzwjrq</bpmn:incoming>
30       <bpmn:outgoing>SequenceFlow_0je0y25</bpmn:outgoing>
31     </bpmn:serviceTask>
32     <bpmn:sequenceFlow id="SequenceFlow_1ryv9sh" name="SilentSuccess" sourceRef="CheckOrchestrationStatusValidationResults" targetRef="End_ExecuteBuildingBlock">
33       <bpmn:conditionExpression xsi:type="bpmn:tFormalExpression"><![CDATA[${execution.getVariable("orchestrationStatusValidationResult").name() ==  "SILENT_SUCCESS"}]]></bpmn:conditionExpression>
34     </bpmn:sequenceFlow>
35     <bpmn:exclusiveGateway id="CheckOrchestrationStatusValidationResults" name="Check OrchestrationStatus Validation Results" default="Continue">
36       <bpmn:incoming>SequenceFlow_0je0y25</bpmn:incoming>
37       <bpmn:outgoing>Continue</bpmn:outgoing>
38       <bpmn:outgoing>SequenceFlow_1ryv9sh</bpmn:outgoing>
39     </bpmn:exclusiveGateway>
40     <bpmn:sequenceFlow id="SequenceFlow_0je0y25" sourceRef="StatusPolicy" targetRef="CheckOrchestrationStatusValidationResults" />
41     <bpmn:subProcess id="SubProcess_0tv8zda" name="Error Handling&#10;&#10;" triggeredByEvent="true">
42       <bpmn:startEvent id="StartEvent_0tmcs9g">
43         <bpmn:outgoing>SequenceFlow_09synl9</bpmn:outgoing>
44         <bpmn:errorEventDefinition />
45       </bpmn:startEvent>
46       <bpmn:sequenceFlow id="SequenceFlow_09synl9" sourceRef="StartEvent_0tmcs9g" targetRef="Task_QueryRainyDayTable" />
47       <bpmn:serviceTask id="Task_QueryRainyDayTable" name="QueryRainyDayTable" camunda:expression="${ExecuteBuildingBlockRainyDay.queryRainyDayTable(execution)}">
48         <bpmn:incoming>SequenceFlow_09synl9</bpmn:incoming>
49         <bpmn:outgoing>SequenceFlow_0a62t4c</bpmn:outgoing>
50       </bpmn:serviceTask>
51       <bpmn:endEvent id="ErrorEnd2">
52         <bpmn:incoming>SequenceFlow_1db2c7t</bpmn:incoming>
53       </bpmn:endEvent>
54       <bpmn:exclusiveGateway id="ExclusiveGateway_1aonzik" name="Check HandlingCode" default="SequenceFlow_0h8v45y">
55         <bpmn:incoming>SequenceFlow_0a62t4c</bpmn:incoming>
56         <bpmn:outgoing>SequenceFlow_0fwsjva</bpmn:outgoing>
57         <bpmn:outgoing>SequenceFlow_0h8v45y</bpmn:outgoing>
58       </bpmn:exclusiveGateway>
59       <bpmn:intermediateCatchEvent id="IntermediateCatchEvent_RetryTimer" name="RetryTimer">
60         <bpmn:incoming>SequenceFlow_0ndt8ft</bpmn:incoming>
61         <bpmn:outgoing>SequenceFlow_07a1ytc</bpmn:outgoing>
62         <bpmn:timerEventDefinition>
63           <bpmn:timeDuration xsi:type="bpmn:tFormalExpression"><![CDATA[${execution.getVariable("RetryDuration")}]]></bpmn:timeDuration>
64         </bpmn:timerEventDefinition>
65       </bpmn:intermediateCatchEvent>
66       <bpmn:exclusiveGateway id="ExclusiveGateway_0ey4zpt" name="Retries Left?">
67         <bpmn:incoming>SequenceFlow_0fwsjva</bpmn:incoming>
68         <bpmn:outgoing>SequenceFlow_1wbevp0</bpmn:outgoing>
69         <bpmn:outgoing>SequenceFlow_1db2c7t</bpmn:outgoing>
70       </bpmn:exclusiveGateway>
71       <bpmn:serviceTask id="Task_SetRetryTimer" name="Set Retry Timer" camunda:expression="${ExecuteBuildingBlockRainyDay.setRetryTimer(execution)}">
72         <bpmn:incoming>SequenceFlow_1wbevp0</bpmn:incoming>
73         <bpmn:outgoing>SequenceFlow_0ndt8ft</bpmn:outgoing>
74       </bpmn:serviceTask>
75       <bpmn:sequenceFlow id="SequenceFlow_0a62t4c" sourceRef="Task_QueryRainyDayTable" targetRef="ExclusiveGateway_1aonzik" />
76       <bpmn:sequenceFlow id="SequenceFlow_0h8v45y" name="Rollback or Abort" sourceRef="ExclusiveGateway_1aonzik" targetRef="EndEvent_0mvmk3i" />
77       <bpmn:sequenceFlow id="SequenceFlow_1db2c7t" name="no" sourceRef="ExclusiveGateway_0ey4zpt" targetRef="ErrorEnd2" />
78       <bpmn:sequenceFlow id="SequenceFlow_0fwsjva" name="Retry" sourceRef="ExclusiveGateway_1aonzik" targetRef="ExclusiveGateway_0ey4zpt">
79         <bpmn:conditionExpression xsi:type="bpmn:tFormalExpression"><![CDATA[${execution.getVariable("handlingCode")=="Retry"}]]></bpmn:conditionExpression>
80       </bpmn:sequenceFlow>
81       <bpmn:sequenceFlow id="SequenceFlow_0ndt8ft" sourceRef="Task_SetRetryTimer" targetRef="IntermediateCatchEvent_RetryTimer" />
82       <bpmn:sequenceFlow id="SequenceFlow_07a1ytc" sourceRef="IntermediateCatchEvent_RetryTimer" targetRef="EndEvent_1sez2lh" />
83       <bpmn:sequenceFlow id="SequenceFlow_1wbevp0" name="yes" sourceRef="ExclusiveGateway_0ey4zpt" targetRef="Task_SetRetryTimer">
84         <bpmn:conditionExpression xsi:type="bpmn:tFormalExpression"><![CDATA[${execution.getVariable("retryCount")<5}]]></bpmn:conditionExpression>
85       </bpmn:sequenceFlow>
86       <bpmn:endEvent id="EndEvent_0mvmk3i">
87         <bpmn:incoming>SequenceFlow_0h8v45y</bpmn:incoming>
88       </bpmn:endEvent>
89       <bpmn:endEvent id="EndEvent_1sez2lh" name="end">
90         <bpmn:incoming>SequenceFlow_07a1ytc</bpmn:incoming>
91         <bpmn:terminateEventDefinition />
92       </bpmn:endEvent>
93     </bpmn:subProcess>
94   </bpmn:process>
95   <bpmn:error id="Error_0tnktdw" name="Error" errorCode="java.lang.Exception" />
96   <bpmn:error id="Error_17zcdbk" name="Bpmn Error" />
97   <bpmndi:BPMNDiagram id="BPMNDiagram_1">
98     <bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="ExecuteBuildingBlock">
99       <bpmndi:BPMNShape id="_BPMNShape_StartEvent_2" bpmnElement="Start_ExecuteBuildingBlock">
100         <dc:Bounds x="42" y="162" width="36" height="36" />
101         <bpmndi:BPMNLabel>
102           <dc:Bounds x="49" y="198" width="23" height="12" />
103         </bpmndi:BPMNLabel>
104       </bpmndi:BPMNShape>
105       <bpmndi:BPMNShape id="CallActivity_0n67obl_di" bpmnElement="Call_BBToExecute">
106         <dc:Bounds x="589" y="140" width="100" height="80" />
107       </bpmndi:BPMNShape>
108       <bpmndi:BPMNEdge id="SequenceFlow_0rq4c5r_di" bpmnElement="SequenceFlow_0rq4c5r">
109         <di:waypoint xsi:type="dc:Point" x="78" y="180" />
110         <di:waypoint xsi:type="dc:Point" x="141" y="180" />
111         <bpmndi:BPMNLabel>
112           <dc:Bounds x="65" y="165" width="90" height="0" />
113         </bpmndi:BPMNLabel>
114       </bpmndi:BPMNEdge>
115       <bpmndi:BPMNEdge id="SequenceFlow_0uzwjrq_di" bpmnElement="SequenceFlow_0uzwjrq">
116         <di:waypoint xsi:type="dc:Point" x="241" y="180" />
117         <di:waypoint xsi:type="dc:Point" x="307" y="180" />
118         <bpmndi:BPMNLabel>
119           <dc:Bounds x="229" y="165" width="90" height="0" />
120         </bpmndi:BPMNLabel>
121       </bpmndi:BPMNEdge>
122       <bpmndi:BPMNShape id="ServiceTask_1jcuk3b_di" bpmnElement="Task_BBInputSetup">
123         <dc:Bounds x="141" y="140" width="100" height="80" />
124       </bpmndi:BPMNShape>
125       <bpmndi:BPMNShape id="EndEvent_0ahsxzi_di" bpmnElement="End_ExecuteBuildingBlock">
126         <dc:Bounds x="808" y="162" width="36" height="36" />
127         <bpmndi:BPMNLabel>
128           <dc:Bounds x="817" y="202" width="18" height="12" />
129         </bpmndi:BPMNLabel>
130       </bpmndi:BPMNShape>
131       <bpmndi:BPMNEdge id="SequenceFlow_01h9qmz_di" bpmnElement="SequenceFlow_01h9qmz">
132         <di:waypoint xsi:type="dc:Point" x="689" y="180" />
133         <di:waypoint xsi:type="dc:Point" x="808" y="180" />
134         <bpmndi:BPMNLabel>
135           <dc:Bounds x="703.5" y="159" width="90" height="12" />
136         </bpmndi:BPMNLabel>
137       </bpmndi:BPMNEdge>
138       <bpmndi:BPMNShape id="ExclusiveGateway_0ey4zpt_di" bpmnElement="ExclusiveGateway_0ey4zpt" isMarkerVisible="true">
139         <dc:Bounds x="435" y="467" width="50" height="50" />
140         <bpmndi:BPMNLabel>
141           <dc:Bounds x="430" y="442" width="62" height="12" />
142         </bpmndi:BPMNLabel>
143       </bpmndi:BPMNShape>
144       <bpmndi:BPMNShape id="IntermediateCatchEvent_0qjyidb_di" bpmnElement="IntermediateCatchEvent_RetryTimer">
145         <dc:Bounds x="668" y="474" width="36" height="36" />
146         <bpmndi:BPMNLabel>
147           <dc:Bounds x="658" y="449" width="56" height="12" />
148         </bpmndi:BPMNLabel>
149       </bpmndi:BPMNShape>
150       <bpmndi:BPMNShape id="ExclusiveGateway_1aonzik_di" bpmnElement="ExclusiveGateway_1aonzik" isMarkerVisible="true">
151         <dc:Bounds x="324" y="467" width="50" height="50" />
152         <bpmndi:BPMNLabel>
153           <dc:Bounds x="315" y="429" width="68" height="24" />
154         </bpmndi:BPMNLabel>
155       </bpmndi:BPMNShape>
156       <bpmndi:BPMNEdge id="SequenceFlow_1wbevp0_di" bpmnElement="SequenceFlow_1wbevp0">
157         <di:waypoint xsi:type="dc:Point" x="485" y="492" />
158         <di:waypoint xsi:type="dc:Point" x="539" y="492" />
159         <bpmndi:BPMNLabel>
160           <dc:Bounds x="496.68461538461537" y="467" width="19" height="12" />
161         </bpmndi:BPMNLabel>
162       </bpmndi:BPMNEdge>
163       <bpmndi:BPMNEdge id="SequenceFlow_0fwsjva_di" bpmnElement="SequenceFlow_0fwsjva">
164         <di:waypoint xsi:type="dc:Point" x="374" y="492" />
165         <di:waypoint xsi:type="dc:Point" x="435" y="492" />
166         <bpmndi:BPMNLabel>
167           <dc:Bounds x="390.60897435897436" y="500" width="27" height="12" />
168         </bpmndi:BPMNLabel>
169       </bpmndi:BPMNEdge>
170       <bpmndi:BPMNEdge id="SequenceFlow_0h8v45y_di" bpmnElement="SequenceFlow_0h8v45y">
171         <di:waypoint xsi:type="dc:Point" x="349" y="517" />
172         <di:waypoint xsi:type="dc:Point" x="349" y="573" />
173         <bpmndi:BPMNLabel>
174           <dc:Bounds x="355" y="538" width="85" height="12" />
175         </bpmndi:BPMNLabel>
176       </bpmndi:BPMNEdge>
177       <bpmndi:BPMNShape id="EndEvent_0svi3iy_di" bpmnElement="ErrorEnd2">
178         <dc:Bounds x="442" y="573" width="36" height="36" />
179         <bpmndi:BPMNLabel>
180           <dc:Bounds x="452" y="613" width="18" height="12" />
181         </bpmndi:BPMNLabel>
182       </bpmndi:BPMNShape>
183       <bpmndi:BPMNShape id="ServiceTask_1tifgqh_di" bpmnElement="Task_QueryRainyDayTable">
184         <dc:Bounds x="181" y="452" width="100" height="80" />
185       </bpmndi:BPMNShape>
186       <bpmndi:BPMNEdge id="SequenceFlow_1db2c7t_di" bpmnElement="SequenceFlow_1db2c7t">
187         <di:waypoint xsi:type="dc:Point" x="460" y="517" />
188         <di:waypoint xsi:type="dc:Point" x="460" y="573" />
189         <bpmndi:BPMNLabel>
190           <dc:Bounds x="469" y="518.5833333333333" width="12" height="12" />
191         </bpmndi:BPMNLabel>
192       </bpmndi:BPMNEdge>
193       <bpmndi:BPMNEdge id="SequenceFlow_0ndt8ft_di" bpmnElement="SequenceFlow_0ndt8ft">
194         <di:waypoint xsi:type="dc:Point" x="639" y="492" />
195         <di:waypoint xsi:type="dc:Point" x="668" y="492" />
196         <bpmndi:BPMNLabel>
197           <dc:Bounds x="608.5" y="471" width="90" height="12" />
198         </bpmndi:BPMNLabel>
199       </bpmndi:BPMNEdge>
200       <bpmndi:BPMNEdge id="SequenceFlow_07a1ytc_di" bpmnElement="SequenceFlow_07a1ytc">
201         <di:waypoint xsi:type="dc:Point" x="704" y="492" />
202         <di:waypoint xsi:type="dc:Point" x="753" y="492" />
203         <bpmndi:BPMNLabel>
204           <dc:Bounds x="683.5" y="471" width="90" height="12" />
205         </bpmndi:BPMNLabel>
206       </bpmndi:BPMNEdge>
207       <bpmndi:BPMNShape id="ServiceTask_1obvxht_di" bpmnElement="Task_SetRetryTimer">
208         <dc:Bounds x="539" y="452" width="100" height="80" />
209       </bpmndi:BPMNShape>
210       <bpmndi:BPMNEdge id="SequenceFlow_0kdjsnx_di" bpmnElement="Continue">
211         <di:waypoint xsi:type="dc:Point" x="508" y="180" />
212         <di:waypoint xsi:type="dc:Point" x="589" y="180" />
213         <bpmndi:BPMNLabel>
214           <dc:Bounds x="528" y="159" width="43" height="12" />
215         </bpmndi:BPMNLabel>
216       </bpmndi:BPMNEdge>
217       <bpmndi:BPMNShape id="ServiceTask_0brnbqx_di" bpmnElement="StatusPolicy">
218         <dc:Bounds x="307" y="140" width="100" height="80" />
219       </bpmndi:BPMNShape>
220       <bpmndi:BPMNEdge id="SequenceFlow_1ryv9sh_di" bpmnElement="SequenceFlow_1ryv9sh">
221         <di:waypoint xsi:type="dc:Point" x="483" y="155" />
222         <di:waypoint xsi:type="dc:Point" x="483" y="75" />
223         <di:waypoint xsi:type="dc:Point" x="826" y="75" />
224         <di:waypoint xsi:type="dc:Point" x="826" y="162" />
225         <bpmndi:BPMNLabel>
226           <dc:Bounds x="620" y="54" width="69" height="12" />
227         </bpmndi:BPMNLabel>
228       </bpmndi:BPMNEdge>
229       <bpmndi:BPMNShape id="ExclusiveGateway_0f8ghh3_di" bpmnElement="CheckOrchestrationStatusValidationResults" isMarkerVisible="true">
230         <dc:Bounds x="458" y="155" width="50" height="50" />
231         <bpmndi:BPMNLabel>
232           <dc:Bounds x="442" y="209" width="87" height="48" />
233         </bpmndi:BPMNLabel>
234       </bpmndi:BPMNShape>
235       <bpmndi:BPMNEdge id="SequenceFlow_0je0y25_di" bpmnElement="SequenceFlow_0je0y25">
236         <di:waypoint xsi:type="dc:Point" x="407" y="180" />
237         <di:waypoint xsi:type="dc:Point" x="458" y="180" />
238         <bpmndi:BPMNLabel>
239           <dc:Bounds x="388" y="159" width="90" height="12" />
240         </bpmndi:BPMNLabel>
241       </bpmndi:BPMNEdge>
242       <bpmndi:BPMNEdge id="SequenceFlow_0a62t4c_di" bpmnElement="SequenceFlow_0a62t4c">
243         <di:waypoint xsi:type="dc:Point" x="281" y="492" />
244         <di:waypoint xsi:type="dc:Point" x="324" y="492" />
245         <bpmndi:BPMNLabel>
246           <dc:Bounds x="257.5" y="470.5" width="90" height="13" />
247         </bpmndi:BPMNLabel>
248       </bpmndi:BPMNEdge>
249       <bpmndi:BPMNShape id="SubProcess_0tv8zda_di" bpmnElement="SubProcess_0tv8zda" isExpanded="true">
250         <dc:Bounds x="76" y="376" width="733" height="253" />
251       </bpmndi:BPMNShape>
252       <bpmndi:BPMNShape id="StartEvent_0tmcs9g_di" bpmnElement="StartEvent_0tmcs9g">
253         <dc:Bounds x="96" y="474" width="36" height="36" />
254         <bpmndi:BPMNLabel>
255           <dc:Bounds x="24" y="510" width="0" height="12" />
256         </bpmndi:BPMNLabel>
257       </bpmndi:BPMNShape>
258       <bpmndi:BPMNEdge id="SequenceFlow_09synl9_di" bpmnElement="SequenceFlow_09synl9">
259         <di:waypoint xsi:type="dc:Point" x="132" y="492" />
260         <di:waypoint xsi:type="dc:Point" x="181" y="492" />
261         <bpmndi:BPMNLabel>
262           <dc:Bounds x="156.5" y="471" width="0" height="12" />
263         </bpmndi:BPMNLabel>
264       </bpmndi:BPMNEdge>
265       <bpmndi:BPMNShape id="EndEvent_0mvmk3i_di" bpmnElement="EndEvent_0mvmk3i">
266         <dc:Bounds x="331" y="573" width="36" height="36" />
267         <bpmndi:BPMNLabel>
268           <dc:Bounds x="349" y="613" width="0" height="12" />
269         </bpmndi:BPMNLabel>
270       </bpmndi:BPMNShape>
271       <bpmndi:BPMNShape id="EndEvent_1aww7yx_di" bpmnElement="EndEvent_1sez2lh">
272         <dc:Bounds x="753" y="474" width="36" height="36" />
273         <bpmndi:BPMNLabel>
274           <dc:Bounds x="763" y="514" width="18" height="12" />
275         </bpmndi:BPMNLabel>
276       </bpmndi:BPMNShape>
277     </bpmndi:BPMNPlane>
278   </bpmndi:BPMNDiagram>
279 </bpmn:definitions>