Update Logic
[so.git] / bpmn / so-bpmn-infrastructure-flows / src / main / resources / process / CreateAndActivatePnfResource.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:camunda="http://camunda.org/schema/1.0/bpmn" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" id="Definitions_1" targetNamespace="http://bpmn.io/schema/bpmn" exporter="Camunda Modeler" exporterVersion="1.16.2">
3   <bpmn:collaboration id="Collaboration_1d0w8lf">
4     <bpmn:participant id="Participant_1egg397" name="SO&#10;Create and Activate Pnf Resource" processRef="CreateAndActivatePnfResource" />
5     <bpmn:participant id="Participant_0atuyq0" name="AAI" />
6     <bpmn:participant id="Participant_19w87ws" name="Workflow Message Service&#10;(communication with DMAAP)&#10;" />
7     <bpmn:messageFlow id="MessageFlow_1h3xu88" sourceRef="CreateAndActivatePnf_CreateAaiEntry" targetRef="Participant_0atuyq0" />
8     <bpmn:messageFlow id="MessageFlow_09ibv5a" sourceRef="CheckAiiForCorrelationId" targetRef="Participant_0atuyq0" />
9     <bpmn:messageFlow id="MessageFlow_0vjul4t" sourceRef="Participant_0atuyq0" targetRef="CheckAiiForCorrelationId" />
10     <bpmn:messageFlow id="MessageFlow_1vrcp2d" sourceRef="Participant_19w87ws" targetRef="WaitForDmaapPnfReadyNotification" />
11     <bpmn:messageFlow id="MessageFlow_0tg4hw9" sourceRef="InformDmaapClient" targetRef="Participant_19w87ws" />
12     <bpmn:messageFlow id="MessageFlow_1py54jr" sourceRef="CancelDmaapClientSubscription" targetRef="Participant_19w87ws" />
13   </bpmn:collaboration>
14   <bpmn:process id="CreateAndActivatePnfResource" name="CreateAndActivatePnfResource" isExecutable="true">
15     <bpmn:sequenceFlow id="SequenceFlow_1kc34bc" sourceRef="WaitForDmaapTimeout" targetRef="CancelDmaapClientSubscription" />
16     <bpmn:sequenceFlow id="SequenceFlow_1o8od8e" sourceRef="InformDmaapClient" targetRef="WaitForDmaapPnfReadyNotification" />
17     <bpmn:sequenceFlow id="SequenceFlow_0v5ffpe" name="No" sourceRef="DoesAaiContainInfoAboutPnf" targetRef="CreateAndActivatePnf_CreateAaiEntry">
18       <bpmn:conditionExpression xsi:type="bpmn:tFormalExpression">#{!aaiContainsInfoAboutPnf}</bpmn:conditionExpression>
19     </bpmn:sequenceFlow>
20     <bpmn:sequenceFlow id="SequenceFlow_0p09qgm" sourceRef="WaitForDmaapPnfReadyNotification" targetRef="AaiEntryUpdated" />
21     <bpmn:sequenceFlow id="SequenceFlow_17s9025" sourceRef="AaiEntryExists" targetRef="InformDmaapClient" />
22     <bpmn:sequenceFlow id="SequenceFlow_1qr6cmf" sourceRef="CreateAndActivatePnf_CreateAaiEntry" targetRef="AaiEntryExists" />
23     <bpmn:sequenceFlow id="SequenceFlow_1j4r3zt" sourceRef="CheckAiiForCorrelationId" targetRef="DoesAaiContainInfoAboutPnf" />
24     <bpmn:sequenceFlow id="SequenceFlow_0j5ksz1" sourceRef="CreateAndActivatePnf_StartEvent" targetRef="CheckInputs" />
25     <bpmn:sequenceFlow id="SequenceFlow_1miyzfe" sourceRef="CancelDmaapClientSubscription" targetRef="ThrowTimeoutException" />
26     <bpmn:sequenceFlow id="SequenceFlow_1l1t6ak" name="Yes" sourceRef="DoesAaiContainInfoAboutPnf" targetRef="AaiEntryExists">
27       <bpmn:conditionExpression xsi:type="bpmn:tFormalExpression">#{aaiContainsInfoAboutPnf}</bpmn:conditionExpression>
28     </bpmn:sequenceFlow>
29     <bpmn:sequenceFlow id="SequenceFlow_0967g8p" sourceRef="CheckInputs" targetRef="CheckAiiForCorrelationId" />
30     <bpmn:serviceTask id="CheckInputs" name="Check inputs" camunda:delegateExpression="${pnfCheckInputs}">
31       <bpmn:incoming>SequenceFlow_0j5ksz1</bpmn:incoming>
32       <bpmn:outgoing>SequenceFlow_0967g8p</bpmn:outgoing>
33     </bpmn:serviceTask>
34     <bpmn:serviceTask id="CancelDmaapClientSubscription" name="Cancel DmaapClient subscription" camunda:delegateExpression="${cancelDmaapSubscription}">
35       <bpmn:incoming>SequenceFlow_1kc34bc</bpmn:incoming>
36       <bpmn:outgoing>SequenceFlow_1miyzfe</bpmn:outgoing>
37     </bpmn:serviceTask>
38     <bpmn:serviceTask id="InformDmaapClient" name="Inform DmaapClient about business key and corresponding pnf-id" camunda:delegateExpression="${informDmaapClient}">
39       <bpmn:incoming>SequenceFlow_17s9025</bpmn:incoming>
40       <bpmn:outgoing>SequenceFlow_1o8od8e</bpmn:outgoing>
41     </bpmn:serviceTask>
42     <bpmn:intermediateThrowEvent id="AaiEntryExists" name="AAI entry exists">
43       <bpmn:incoming>SequenceFlow_1qr6cmf</bpmn:incoming>
44       <bpmn:incoming>SequenceFlow_1l1t6ak</bpmn:incoming>
45       <bpmn:outgoing>SequenceFlow_17s9025</bpmn:outgoing>
46     </bpmn:intermediateThrowEvent>
47     <bpmn:serviceTask id="CreateAndActivatePnf_CreateAaiEntry" name="Create AAI entry with pnf-id = correlation_id" camunda:delegateExpression="${createAaiEntryWithPnfIdDelegate}">
48       <bpmn:incoming>SequenceFlow_0v5ffpe</bpmn:incoming>
49       <bpmn:outgoing>SequenceFlow_1qr6cmf</bpmn:outgoing>
50     </bpmn:serviceTask>
51     <bpmn:exclusiveGateway id="DoesAaiContainInfoAboutPnf" name="Does AAI contain info about pnf?">
52       <bpmn:incoming>SequenceFlow_1j4r3zt</bpmn:incoming>
53       <bpmn:outgoing>SequenceFlow_1l1t6ak</bpmn:outgoing>
54       <bpmn:outgoing>SequenceFlow_0v5ffpe</bpmn:outgoing>
55     </bpmn:exclusiveGateway>
56     <bpmn:serviceTask id="CheckAiiForCorrelationId" name="Check AAI for correlation_id" camunda:delegateExpression="${checkAaiForCorrelationIdDelegate}">
57       <bpmn:incoming>SequenceFlow_0967g8p</bpmn:incoming>
58       <bpmn:outgoing>SequenceFlow_1j4r3zt</bpmn:outgoing>
59     </bpmn:serviceTask>
60     <bpmn:startEvent id="CreateAndActivatePnf_StartEvent">
61       <bpmn:outgoing>SequenceFlow_0j5ksz1</bpmn:outgoing>
62     </bpmn:startEvent>
63     <bpmn:endEvent id="ThrowTimeoutException" name="Throw timeout exception">
64       <bpmn:incoming>SequenceFlow_1miyzfe</bpmn:incoming>
65       <bpmn:errorEventDefinition errorRef="Error_1" />
66     </bpmn:endEvent>
67     <bpmn:endEvent id="AaiEntryUpdated" name="AAI entry updated">
68       <bpmn:incoming>SequenceFlow_0p09qgm</bpmn:incoming>
69     </bpmn:endEvent>
70     <bpmn:receiveTask id="WaitForDmaapPnfReadyNotification" name="Wait for DMAAP pnf-ready notification" messageRef="Message_13h1tlo">
71       <bpmn:incoming>SequenceFlow_1o8od8e</bpmn:incoming>
72       <bpmn:outgoing>SequenceFlow_0p09qgm</bpmn:outgoing>
73     </bpmn:receiveTask>
74     <bpmn:boundaryEvent id="WaitForDmaapTimeout" name="Timeout" attachedToRef="WaitForDmaapPnfReadyNotification">
75       <bpmn:outgoing>SequenceFlow_1kc34bc</bpmn:outgoing>
76       <bpmn:timerEventDefinition>
77         <bpmn:timeDuration xsi:type="bpmn:tFormalExpression">#{timeoutForPnfEntryNotification}</bpmn:timeDuration>
78       </bpmn:timerEventDefinition>
79     </bpmn:boundaryEvent>
80     <bpmn:association id="Association_0d7oxnz" sourceRef="CreateAndActivatePnf_StartEvent" targetRef="TextAnnotation_1eyzes8" />
81     <bpmn:textAnnotation id="TextAnnotation_1eyzes8">
82       <bpmn:text>Inputs:
83  - timeoutForPnfEntryNotification - String
84  - correlationId - String
85 </bpmn:text>
86     </bpmn:textAnnotation>
87   </bpmn:process>
88   <bpmn:error id="Error_1" name="MSO Workflow Exception" errorCode="MSOWorkflowException" />
89   <bpmn:message id="Message_13h1tlo" name="WorkflowMessage" />
90   <bpmndi:BPMNDiagram id="BPMNDiagram_1">
91     <bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="Collaboration_1d0w8lf">
92       <bpmndi:BPMNShape id="Participant_1egg397_di" bpmnElement="Participant_1egg397">
93         <dc:Bounds x="-113" y="0" width="1601" height="438" />
94       </bpmndi:BPMNShape>
95       <bpmndi:BPMNShape id="ExclusiveGateway_1cttgdo_di" bpmnElement="DoesAaiContainInfoAboutPnf" isMarkerVisible="true">
96         <dc:Bounds x="390" y="182" width="50" height="50" />
97         <bpmndi:BPMNLabel>
98           <dc:Bounds x="372" y="283" width="85" height="27" />
99         </bpmndi:BPMNLabel>
100       </bpmndi:BPMNShape>
101       <bpmndi:BPMNShape id="EndEvent_0k52gr7_di" bpmnElement="AaiEntryUpdated">
102         <dc:Bounds x="1312" y="189" width="36" height="36" />
103         <bpmndi:BPMNLabel>
104           <dc:Bounds x="1287" y="230" width="88" height="14" />
105         </bpmndi:BPMNLabel>
106       </bpmndi:BPMNShape>
107       <bpmndi:BPMNShape id="StartEvent_0j5ok9h_di" bpmnElement="CreateAndActivatePnf_StartEvent">
108         <dc:Bounds x="-54" y="189" width="36" height="36" />
109         <bpmndi:BPMNLabel>
110           <dc:Bounds x="-80" y="228" width="90" height="20" />
111         </bpmndi:BPMNLabel>
112       </bpmndi:BPMNShape>
113       <bpmndi:BPMNShape id="ServiceTask_0a5uk9o_di" bpmnElement="CheckAiiForCorrelationId">
114         <dc:Bounds x="219" y="167" width="100" height="80" />
115       </bpmndi:BPMNShape>
116       <bpmndi:BPMNShape id="ServiceTask_0iimk5v_di" bpmnElement="CreateAndActivatePnf_CreateAaiEntry">
117         <dc:Bounds x="511" y="167" width="100" height="80" />
118       </bpmndi:BPMNShape>
119       <bpmndi:BPMNEdge id="SequenceFlow_1j4r3zt_di" bpmnElement="SequenceFlow_1j4r3zt">
120         <di:waypoint x="319" y="207" />
121         <di:waypoint x="390" y="207" />
122         <bpmndi:BPMNLabel>
123           <dc:Bounds x="309.5" y="187" width="90" height="10" />
124         </bpmndi:BPMNLabel>
125       </bpmndi:BPMNEdge>
126       <bpmndi:BPMNEdge id="SequenceFlow_1l1t6ak_di" bpmnElement="SequenceFlow_1l1t6ak">
127         <di:waypoint x="415" y="207" />
128         <di:waypoint x="415" y="66" />
129         <di:waypoint x="707" y="66" />
130         <di:waypoint x="707" y="189" />
131         <bpmndi:BPMNLabel>
132           <dc:Bounds x="430" y="180" width="19" height="14" />
133         </bpmndi:BPMNLabel>
134       </bpmndi:BPMNEdge>
135       <bpmndi:BPMNEdge id="SequenceFlow_0v5ffpe_di" bpmnElement="SequenceFlow_0v5ffpe">
136         <di:waypoint x="440" y="207" />
137         <di:waypoint x="511" y="207" />
138         <bpmndi:BPMNLabel>
139           <dc:Bounds x="448" y="210" width="14" height="14" />
140         </bpmndi:BPMNLabel>
141       </bpmndi:BPMNEdge>
142       <bpmndi:BPMNEdge id="SequenceFlow_1qr6cmf_di" bpmnElement="SequenceFlow_1qr6cmf">
143         <di:waypoint x="611" y="207" />
144         <di:waypoint x="689" y="207" />
145         <bpmndi:BPMNLabel>
146           <dc:Bounds x="605" y="187" width="90" height="10" />
147         </bpmndi:BPMNLabel>
148       </bpmndi:BPMNEdge>
149       <bpmndi:BPMNEdge id="SequenceFlow_0j5ksz1_di" bpmnElement="SequenceFlow_0j5ksz1">
150         <di:waypoint x="-18" y="207" />
151         <di:waypoint x="48" y="207" />
152         <bpmndi:BPMNLabel>
153           <dc:Bounds x="-30" y="187" width="90" height="10" />
154         </bpmndi:BPMNLabel>
155       </bpmndi:BPMNEdge>
156       <bpmndi:BPMNShape id="Participant_0i9ban2_di" bpmnElement="Participant_0atuyq0">
157         <dc:Bounds x="123" y="523" width="502" height="60" />
158       </bpmndi:BPMNShape>
159       <bpmndi:BPMNEdge id="MessageFlow_1h3xu88_di" bpmnElement="MessageFlow_1h3xu88">
160         <di:waypoint x="561" y="247" />
161         <di:waypoint x="561" y="523" />
162         <bpmndi:BPMNLabel>
163           <dc:Bounds x="531" y="380" width="90" height="10" />
164         </bpmndi:BPMNLabel>
165       </bpmndi:BPMNEdge>
166       <bpmndi:BPMNEdge id="MessageFlow_09ibv5a_di" bpmnElement="MessageFlow_09ibv5a">
167         <di:waypoint x="250" y="247" />
168         <di:waypoint x="250" y="523" />
169         <bpmndi:BPMNLabel>
170           <dc:Bounds x="220" y="380" width="90" height="10" />
171         </bpmndi:BPMNLabel>
172       </bpmndi:BPMNEdge>
173       <bpmndi:BPMNEdge id="MessageFlow_0vjul4t_di" bpmnElement="MessageFlow_0vjul4t">
174         <di:waypoint x="289" y="523" />
175         <di:waypoint x="289" y="247" />
176         <bpmndi:BPMNLabel>
177           <dc:Bounds x="259" y="380" width="90" height="10" />
178         </bpmndi:BPMNLabel>
179       </bpmndi:BPMNEdge>
180       <bpmndi:BPMNShape id="Participant_0vmrrhf_di" bpmnElement="Participant_19w87ws">
181         <dc:Bounds x="804" y="523" width="463" height="60" />
182       </bpmndi:BPMNShape>
183       <bpmndi:BPMNShape id="EndEvent_0wbx6tt_di" bpmnElement="ThrowTimeoutException">
184         <dc:Bounds x="1312" y="345" width="36" height="36" />
185         <bpmndi:BPMNLabel>
186           <dc:Bounds x="1305" y="382" width="70" height="27" />
187         </bpmndi:BPMNLabel>
188       </bpmndi:BPMNShape>
189       <bpmndi:BPMNShape id="IntermediateThrowEvent_0fjcdy4_di" bpmnElement="AaiEntryExists">
190         <dc:Bounds x="689" y="189" width="36" height="36" />
191         <bpmndi:BPMNLabel>
192           <dc:Bounds x="672" y="235" width="77" height="14" />
193         </bpmndi:BPMNLabel>
194       </bpmndi:BPMNShape>
195       <bpmndi:BPMNShape id="TextAnnotation_1eyzes8_di" bpmnElement="TextAnnotation_1eyzes8">
196         <dc:Bounds x="-37" y="70" width="243" height="54" />
197       </bpmndi:BPMNShape>
198       <bpmndi:BPMNEdge id="Association_0d7oxnz_di" bpmnElement="Association_0d7oxnz">
199         <di:waypoint x="-36" y="189" />
200         <di:waypoint x="-36" y="124" />
201       </bpmndi:BPMNEdge>
202       <bpmndi:BPMNEdge id="MessageFlow_1vrcp2d_di" bpmnElement="MessageFlow_1vrcp2d">
203         <di:waypoint x="1060" y="523" />
204         <di:waypoint x="1060" y="247" />
205         <bpmndi:BPMNLabel>
206           <dc:Bounds x="996" y="380" width="90" height="10" />
207         </bpmndi:BPMNLabel>
208       </bpmndi:BPMNEdge>
209       <bpmndi:BPMNEdge id="SequenceFlow_17s9025_di" bpmnElement="SequenceFlow_17s9025">
210         <di:waypoint x="725" y="207" />
211         <di:waypoint x="803" y="207" />
212         <bpmndi:BPMNLabel>
213           <dc:Bounds x="719" y="187" width="90" height="10" />
214         </bpmndi:BPMNLabel>
215       </bpmndi:BPMNEdge>
216       <bpmndi:BPMNShape id="BoundaryEvent_15eo1k9_di" bpmnElement="WaitForDmaapTimeout">
217         <dc:Bounds x="1074" y="229" width="36" height="36" />
218         <bpmndi:BPMNLabel>
219           <dc:Bounds x="1117" y="240" width="40" height="14" />
220         </bpmndi:BPMNLabel>
221       </bpmndi:BPMNShape>
222       <bpmndi:BPMNEdge id="SequenceFlow_1kc34bc_di" bpmnElement="SequenceFlow_1kc34bc">
223         <di:waypoint x="1092" y="265" />
224         <di:waypoint x="1092" y="363" />
225         <di:waypoint x="1145" y="363" />
226         <bpmndi:BPMNLabel>
227           <dc:Bounds x="1028" y="309" width="90" height="10" />
228         </bpmndi:BPMNLabel>
229       </bpmndi:BPMNEdge>
230       <bpmndi:BPMNShape id="ReceiveTask_1sfysua_di" bpmnElement="WaitForDmaapPnfReadyNotification">
231         <dc:Bounds x="1008" y="167" width="100" height="80" />
232       </bpmndi:BPMNShape>
233       <bpmndi:BPMNEdge id="SequenceFlow_0p09qgm_di" bpmnElement="SequenceFlow_0p09qgm">
234         <di:waypoint x="1108" y="207" />
235         <di:waypoint x="1312" y="207" />
236         <bpmndi:BPMNLabel>
237           <dc:Bounds x="1148" y="187" width="90" height="10" />
238         </bpmndi:BPMNLabel>
239       </bpmndi:BPMNEdge>
240       <bpmndi:BPMNEdge id="SequenceFlow_1o8od8e_di" bpmnElement="SequenceFlow_1o8od8e">
241         <di:waypoint x="903" y="207" />
242         <di:waypoint x="1008" y="207" />
243         <bpmndi:BPMNLabel>
244           <dc:Bounds x="893.5" y="187" width="90" height="10" />
245         </bpmndi:BPMNLabel>
246       </bpmndi:BPMNEdge>
247       <bpmndi:BPMNEdge id="MessageFlow_0tg4hw9_di" bpmnElement="MessageFlow_0tg4hw9">
248         <di:waypoint x="853" y="247" />
249         <di:waypoint x="853" y="523" />
250         <bpmndi:BPMNLabel>
251           <dc:Bounds x="823" y="380" width="90" height="10" />
252         </bpmndi:BPMNLabel>
253       </bpmndi:BPMNEdge>
254       <bpmndi:BPMNShape id="ServiceTask_1iax11n_di" bpmnElement="InformDmaapClient">
255         <dc:Bounds x="803" y="167" width="100" height="80" />
256       </bpmndi:BPMNShape>
257       <bpmndi:BPMNEdge id="SequenceFlow_1miyzfe_di" bpmnElement="SequenceFlow_1miyzfe">
258         <di:waypoint x="1245" y="363" />
259         <di:waypoint x="1312" y="363" />
260         <bpmndi:BPMNLabel>
261           <dc:Bounds x="1233.5" y="343" width="90" height="10" />
262         </bpmndi:BPMNLabel>
263       </bpmndi:BPMNEdge>
264       <bpmndi:BPMNEdge id="MessageFlow_1py54jr_di" bpmnElement="MessageFlow_1py54jr">
265         <di:waypoint x="1195" y="403" />
266         <di:waypoint x="1195" y="523" />
267         <bpmndi:BPMNLabel>
268           <dc:Bounds x="1165" y="458" width="90" height="10" />
269         </bpmndi:BPMNLabel>
270       </bpmndi:BPMNEdge>
271       <bpmndi:BPMNShape id="ServiceTask_12j7hox_di" bpmnElement="CancelDmaapClientSubscription">
272         <dc:Bounds x="1145" y="323" width="100" height="80" />
273       </bpmndi:BPMNShape>
274       <bpmndi:BPMNEdge id="SequenceFlow_0967g8p_di" bpmnElement="SequenceFlow_0967g8p">
275         <di:waypoint x="148" y="207" />
276         <di:waypoint x="219" y="207" />
277         <bpmndi:BPMNLabel>
278           <dc:Bounds x="183.5" y="187" width="0" height="10" />
279         </bpmndi:BPMNLabel>
280       </bpmndi:BPMNEdge>
281       <bpmndi:BPMNShape id="ServiceTask_0lx02qn_di" bpmnElement="CheckInputs">
282         <dc:Bounds x="48" y="167" width="100" height="80" />
283       </bpmndi:BPMNShape>
284     </bpmndi:BPMNPlane>
285   </bpmndi:BPMNDiagram>
286 </bpmn:definitions>