1 <?xml version="1.0" encoding="UTF-8"?>
2 <bpmn2:definitions xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:bpmn2="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:dc="http://www.omg.org/spec/DD/20100524/DC" xmlns:di="http://www.omg.org/spec/DD/20100524/DI" id="_FatVcHn0EeaH6vX1RRdc_w" targetNamespace="http://camunda.org/schema/1.0/bpmn" exporter="Camunda Modeler" exporterVersion="1.4.0" xsi:schemaLocation="http://www.omg.org/spec/BPMN/20100524/MODEL BPMN20.xsd">
3 <bpmn2:process id="GenericPutService" name="GenericPutService" isExecutable="true">
4 <bpmn2:startEvent id="StartEvent_1">
5 <bpmn2:outgoing>SequenceFlow_1</bpmn2:outgoing>
7 <bpmn2:sequenceFlow id="SequenceFlow_1" name="" sourceRef="StartEvent_1" targetRef="Initialization" />
8 <bpmn2:endEvent id="EndEvent_1">
9 <bpmn2:incoming>SequenceFlow_5</bpmn2:incoming>
10 <bpmn2:terminateEventDefinition id="TerminateEventDefinition_1" />
12 <bpmn2:scriptTask id="toggleSuccess" name="Toggle Success Indicator" scriptFormat="groovy">
13 <bpmn2:incoming>SequenceFlow_4</bpmn2:incoming>
14 <bpmn2:outgoing>SequenceFlow_5</bpmn2:outgoing>
15 <bpmn2:script><![CDATA[import org.onap.so.bpmn.common.scripts.*
17 def serviceInstance= new GenericPutService()
18 serviceInstance.setSuccessIndicator(execution, true)
20 execution.setVariable("WorkflowResponse", " ") //for junits]]></bpmn2:script>
22 <bpmn2:sequenceFlow id="SequenceFlow_5" name="" sourceRef="toggleSuccess" targetRef="EndEvent_1" />
23 <bpmn2:scriptTask id="putServiceInstance" name="Put Service Instance" scriptFormat="groovy">
24 <bpmn2:incoming>SequenceFlow_3</bpmn2:incoming>
25 <bpmn2:outgoing>SequenceFlow_4</bpmn2:outgoing>
26 <bpmn2:script><![CDATA[import org.onap.so.bpmn.common.scripts.*
28 def serviceInstance= new GenericPutService()
29 serviceInstance.putServiceInstance(execution)]]></bpmn2:script>
31 <bpmn2:sequenceFlow id="SequenceFlow_4" name="" sourceRef="putServiceInstance" targetRef="toggleSuccess" />
32 <bpmn2:scriptTask id="Initialization" name="Initialization" scriptFormat="groovy">
33 <bpmn2:incoming>SequenceFlow_1</bpmn2:incoming>
34 <bpmn2:outgoing>SequenceFlow_3</bpmn2:outgoing>
35 <bpmn2:script><![CDATA[import org.onap.so.bpmn.common.scripts.*
37 def serviceInstance= new GenericPutService()
38 serviceInstance.preProcessRequest(execution)
41 <bpmn2:sequenceFlow id="SequenceFlow_3" name="" sourceRef="Initialization" targetRef="putServiceInstance" />
42 <bpmn2:subProcess id="bpmnExceptionHandlingSubProcess" name="Error Handling Sub Process" triggeredByEvent="true">
43 <bpmn2:startEvent id="StartEvent_2">
44 <bpmn2:outgoing>SequenceFlow_6</bpmn2:outgoing>
45 <bpmn2:errorEventDefinition id="ErrorEventDefinition_1" />
47 <bpmn2:sequenceFlow id="SequenceFlow_6" name="" sourceRef="StartEvent_2" targetRef="processError" />
48 <bpmn2:endEvent id="EndEvent_2">
49 <bpmn2:incoming>SequenceFlow_7</bpmn2:incoming>
51 <bpmn2:scriptTask id="processError" name="Process Error" scriptFormat="groovy">
52 <bpmn2:incoming>SequenceFlow_6</bpmn2:incoming>
53 <bpmn2:outgoing>SequenceFlow_7</bpmn2:outgoing>
54 <bpmn2:script><![CDATA[import org.onap.so.bpmn.common.scripts.*
56 ExceptionUtil ex = new ExceptionUtil()
57 ex.processSubflowsBPMNException(execution)]]></bpmn2:script>
59 <bpmn2:sequenceFlow id="SequenceFlow_7" name="" sourceRef="processError" targetRef="EndEvent_2" />
61 <bpmn2:subProcess id="javaExceptionSubProcess" name="Java Exception Handling Sub Process" triggeredByEvent="true">
62 <bpmn2:startEvent id="catchJavaExcep">
63 <bpmn2:outgoing>SequenceFlow_9</bpmn2:outgoing>
64 <bpmn2:errorEventDefinition id="ErrorEventDefinition_2" errorRef="Error_2" />
66 <bpmn2:sequenceFlow id="SequenceFlow_9" name="" sourceRef="catchJavaExcep" targetRef="processJavaError" />
67 <bpmn2:scriptTask id="processJavaError" name="Process Java Error" scriptFormat="groovy">
68 <bpmn2:incoming>SequenceFlow_9</bpmn2:incoming>
69 <bpmn2:outgoing>SequenceFlow_10</bpmn2:outgoing>
70 <bpmn2:script><![CDATA[import org.onap.so.bpmn.common.scripts.*
72 ExceptionUtil ex = new ExceptionUtil()
73 ex.processJavaException(execution)]]></bpmn2:script>
75 <bpmn2:endEvent id="EndEvent_3">
76 <bpmn2:incoming>SequenceFlow_10</bpmn2:incoming>
77 <bpmn2:terminateEventDefinition id="TerminateEventDefinition_2" />
79 <bpmn2:sequenceFlow id="SequenceFlow_10" name="" sourceRef="processJavaError" targetRef="EndEvent_3" />
82 <bpmn2:error id="Error_1" name="MSO Workflow Exception" errorCode="MSOWorkflowException" />
83 <bpmn2:error id="Error_2" name="Java Lang Exception" errorCode="java.lang.Exception" />
84 <bpmndi:BPMNDiagram id="BPMNDiagram_1">
85 <bpmndi:BPMNPlane id="BPMNPlane_1" bpmnElement="GenericPutService">
86 <bpmndi:BPMNShape id="_BPMNShape_StartEvent_71" bpmnElement="StartEvent_1">
87 <dc:Bounds x="182" y="180" width="36" height="36" />
89 <dc:Bounds x="200" y="221" width="0" height="0" />
92 <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_302" bpmnElement="Initialization">
93 <dc:Bounds x="324" y="158" width="100" height="80" />
95 <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_1" bpmnElement="SequenceFlow_1" sourceElement="_BPMNShape_StartEvent_71" targetElement="_BPMNShape_ScriptTask_302">
96 <di:waypoint xsi:type="dc:Point" x="218" y="198" />
97 <di:waypoint xsi:type="dc:Point" x="324" y="198" />
99 <dc:Bounds x="250" y="198" width="6" height="6" />
102 <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_304" bpmnElement="putServiceInstance">
103 <dc:Bounds x="528" y="158" width="100" height="80" />
105 <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_3" bpmnElement="SequenceFlow_3" sourceElement="_BPMNShape_ScriptTask_302" targetElement="_BPMNShape_ScriptTask_304">
106 <di:waypoint xsi:type="dc:Point" x="424" y="198" />
107 <di:waypoint xsi:type="dc:Point" x="528" y="198" />
109 <dc:Bounds x="446" y="198" width="6" height="6" />
112 <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_305" bpmnElement="toggleSuccess">
113 <dc:Bounds x="732" y="158" width="100" height="80" />
115 <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_4" bpmnElement="SequenceFlow_4" sourceElement="_BPMNShape_ScriptTask_304" targetElement="_BPMNShape_ScriptTask_305">
116 <di:waypoint xsi:type="dc:Point" x="628" y="198" />
117 <di:waypoint xsi:type="dc:Point" x="732" y="198" />
119 <dc:Bounds x="650" y="198" width="6" height="6" />
122 <bpmndi:BPMNShape id="_BPMNShape_EndEvent_230" bpmnElement="EndEvent_1">
123 <dc:Bounds x="908" y="180" width="36" height="36" />
125 <dc:Bounds x="926" y="221" width="0" height="0" />
128 <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_5" bpmnElement="SequenceFlow_5" sourceElement="_BPMNShape_ScriptTask_305" targetElement="_BPMNShape_EndEvent_230">
129 <di:waypoint xsi:type="dc:Point" x="832" y="198" />
130 <di:waypoint xsi:type="dc:Point" x="908" y="198" />
132 <dc:Bounds x="854" y="198" width="6" height="6" />
135 <bpmndi:BPMNShape id="_BPMNShape_SubProcess_27" bpmnElement="bpmnExceptionHandlingSubProcess" isExpanded="true">
136 <dc:Bounds x="324" y="312" width="418" height="150" />
138 <bpmndi:BPMNShape id="_BPMNShape_StartEvent_72" bpmnElement="StartEvent_2">
139 <dc:Bounds x="357" y="370" width="36" height="36" />
141 <dc:Bounds x="375" y="411" width="0" height="0" />
144 <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_306" bpmnElement="processError">
145 <dc:Bounds x="466" y="348" width="100" height="80" />
147 <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_6" bpmnElement="SequenceFlow_6" sourceElement="_BPMNShape_StartEvent_72" targetElement="_BPMNShape_ScriptTask_306">
148 <di:waypoint xsi:type="dc:Point" x="393" y="388" />
149 <di:waypoint xsi:type="dc:Point" x="466" y="388" />
151 <dc:Bounds x="415" y="388" width="6" height="6" />
154 <bpmndi:BPMNShape id="_BPMNShape_EndEvent_231" bpmnElement="EndEvent_2">
155 <dc:Bounds x="615" y="370" width="36" height="36" />
157 <dc:Bounds x="633" y="411" width="0" height="0" />
160 <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_7" bpmnElement="SequenceFlow_7" sourceElement="_BPMNShape_ScriptTask_306" targetElement="_BPMNShape_EndEvent_231">
161 <di:waypoint xsi:type="dc:Point" x="566" y="388" />
162 <di:waypoint xsi:type="dc:Point" x="615" y="388" />
164 <dc:Bounds x="588" y="388" width="6" height="6" />
167 <bpmndi:BPMNShape id="_BPMNShape_SubProcess_28" bpmnElement="javaExceptionSubProcess" isExpanded="true">
168 <dc:Bounds x="323" y="486" width="419" height="150" />
170 <bpmndi:BPMNShape id="_BPMNShape_StartEvent_73" bpmnElement="catchJavaExcep">
171 <dc:Bounds x="357" y="538" width="36" height="36" />
173 <dc:Bounds x="375" y="579" width="0" height="0" />
176 <bpmndi:BPMNShape id="_BPMNShape_ScriptTask_308" bpmnElement="processJavaError">
177 <dc:Bounds x="465" y="516" width="100" height="80" />
179 <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_9" bpmnElement="SequenceFlow_9" sourceElement="_BPMNShape_StartEvent_73" targetElement="_BPMNShape_ScriptTask_308">
180 <di:waypoint xsi:type="dc:Point" x="393" y="556" />
181 <di:waypoint xsi:type="dc:Point" x="465" y="556" />
183 <dc:Bounds x="415" y="556" width="6" height="6" />
186 <bpmndi:BPMNShape id="_BPMNShape_EndEvent_232" bpmnElement="EndEvent_3">
187 <dc:Bounds x="615" y="538" width="36" height="36" />
189 <dc:Bounds x="633" y="579" width="0" height="0" />
192 <bpmndi:BPMNEdge id="BPMNEdge_SequenceFlow_10" bpmnElement="SequenceFlow_10" sourceElement="_BPMNShape_ScriptTask_308" targetElement="_BPMNShape_EndEvent_232">
193 <di:waypoint xsi:type="dc:Point" x="565" y="556" />
194 <di:waypoint xsi:type="dc:Point" x="615" y="556" />
196 <dc:Bounds x="587" y="556" width="6" height="6" />
200 </bpmndi:BPMNDiagram>