Fix ss-generate-name DG
[sdnc/oam.git] / platform-logic / generic-resource-api / src / main / json / sotn / GENERIC-RESOURCE-API_sotn-network-topology-operation-reoptimize.json
1 [
2   {
3     "id": "75921ba5.e84f04",
4     "type": "dgstart",
5     "name": "DGSTART",
6     "outputs": 1,
7     "x": 127,
8     "y": 31,
9     "z": "4c77a098.14bed",
10     "wires": [
11       [
12         "67179bf.f30bb64"
13       ]
14     ]
15   },
16   {
17     "id": "67179bf.f30bb64",
18     "type": "service-logic",
19     "name": "GENERIC-RESOURCE-API ${project.version}",
20     "module": "GENERIC-RESOURCE-API",
21     "version": "${project.version}",
22     "comments": "",
23     "xml": "<service-logic xmlns='http://www.onap.org/sdnc/svclogic' xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xsi:schemaLocation='http://www.onap.org/sdnc/svclogic ./svclogic.xsd' module='GENERIC-RESOURCE-API' version='${project.version}'>",
24     "outputs": 1,
25     "x": 345.49999237060547,
26     "y": 111.99999287677929,
27     "z": "4c77a098.14bed",
28     "wires": [
29       [
30         "df585947.1b0688"
31       ]
32     ]
33   },
34   {
35     "id": "df585947.1b0688",
36     "type": "method",
37     "name": "sotn-network-topology-operation-reoptimize",
38     "xml": "<method rpc='sotn-network-topology-operation-reoptimize' mode='sync'>\n",
39     "comments": "",
40     "outputs": 1,
41     "x": 346.5,
42     "y": 165,
43     "z": "4c77a098.14bed",
44     "wires": [
45       [
46         "970cf081.0efd5"
47       ]
48     ]
49   },
50   {
51     "id": "970cf081.0efd5",
52     "type": "block",
53     "name": "block : atomic",
54     "xml": "<block atomic=\"true\">\n",
55     "atomic": "false",
56     "comments": "",
57     "outputs": 1,
58     "x": 424.50000762939453,
59     "y": 223.000009059906,
60     "z": "4c77a098.14bed",
61     "wires": [
62       [
63         "32a56503.ce58fa",
64         "b0b6546.423eca8",
65         "103fcffc.47e2d",
66         "77dde683.c05af8",
67         "c64a9e95.de368",
68         "f4c6a746.18c888"
69       ]
70     ]
71   },
72   {
73     "id": "32a56503.ce58fa",
74     "type": "set",
75     "name": "set tmp.network.parent-network-id,etc",
76     "xml": "<set>\n<parameter name='tmp.network.network-id' value='`$network-topology-operation-input.network-information.network-id`' />\n<parameter name='tmp.network.service-instance-id' value='`$network-topology-operation-input.service-information.service-instance-id`' />\n\n\n",
77     "comments": "",
78     "x": 772.0000152587891,
79     "y": 118.00000476837158,
80     "z": "4c77a098.14bed",
81     "wires": []
82   },
83   {
84     "id": "21fcd909.4488b6",
85     "type": "comment",
86     "name": "set tmp connectivity-id to fetch resource from MDSAL",
87     "info": "",
88     "comments": "",
89     "x": 841.9603424072266,
90     "y": 83.03180408477783,
91     "z": "4c77a098.14bed",
92     "wires": []
93   },
94   {
95     "id": "b0b6546.423eca8",
96     "type": "execute",
97     "name": "execute Properties",
98     "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.prop.PropertiesNode' method='readProperties' >\n    <parameter name='fileName' value='%SDNC_CONFIG_DIR%/generic-resource-api-dg.properties' />\n    <parameter name='contextPrefix' value='prop' />\n",
99     "comments": "",
100     "outputs": 1,
101     "x": 715.9999542236328,
102     "y": 201.00000476837158,
103     "z": "4c77a098.14bed",
104     "wires": [
105       []
106     ]
107   },
108   {
109     "id": "deead92.2e05028",
110     "type": "comment",
111     "name": "Obtain different URL, template location etc",
112     "info": "For saving resource information to MDSAL & for AAI",
113     "comments": "",
114     "x": 811.7380523681641,
115     "y": 166.22217273712158,
116     "z": "4c77a098.14bed",
117     "wires": []
118   },
119   {
120     "id": "103fcffc.47e2d",
121     "type": "for",
122     "name": "for pidx..mdsal-psd.service-data.provided-allotted-resources.provided-allotted-resource[]",
123     "xml": "<for index='pidx' start='0' end='1' >\n",
124     "comments": "",
125     "outputs": 1,
126     "x": 926.0000991821289,
127     "y": 283.0000705718994,
128     "z": "4c77a098.14bed",
129     "wires": [
130       [
131         "4ff3cba6.0577e4"
132       ]
133     ]
134   },
135   {
136     "id": "4ff3cba6.0577e4",
137     "type": "block",
138     "name": "block atomic",
139     "xml": "<block atomic=\"true\">\n",
140     "atomic": "false",
141     "comments": "",
142     "outputs": 1,
143     "x": 897.8459091186523,
144     "y": 339.224645614624,
145     "z": "4c77a098.14bed",
146     "wires": [
147       [
148         "efb008da.002a38",
149         "56cd0f49.c1db2",
150         "1e3aa974.204b57",
151         "c0e08604.031d68",
152         "b2b348e8.930c38",
153         "ea908538.cdcb68",
154         "63bd98b8.1ea0d8",
155         "9da5cea0.60ef2",
156         "a382c856.52c0b8",
157         "4d332c82.ad3af4"
158       ]
159     ]
160   },
161   {
162     "id": "efb008da.002a38",
163     "type": "set",
164     "name": "set prop.ar.provided-allotted-resource-id",
165     "xml": "<set>\n<parameter name='prop.ar.provided-allotted-resource-id' value='`$service-data.provided-allotted-resources.provided-allotted-resource[$pidx].allotted-resource-id`' />\n\n",
166     "comments": "",
167     "x": 1167.8153915405273,
168     "y": 322.02744245529175,
169     "z": "4c77a098.14bed",
170     "wires": []
171   },
172   {
173     "id": "56cd0f49.c1db2",
174     "type": "execute",
175     "name": "generate tmp.ar-url-connection url",
176     "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >\n    <parameter name=\"source\" value=\"`$prop.restapi.connection-attachment-allottedresource`\"/>\n    <parameter name=\"outputPath\" value=\"tmp.ar-url-connection\"/>\n    <parameter name=\"target\" value=\"{allotted-resource-id}\"/>\n    <parameter name=\"replacement\" value='`$prop.ar.provided-allotted-resource-id`'/>\n",
177     "comments": "",
178     "outputs": 1,
179     "x": 1156.815284729004,
180     "y": 374.5724229812622,
181     "z": "4c77a098.14bed",
182     "wires": [
183       []
184     ]
185   },
186   {
187     "id": "1e3aa974.204b57",
188     "type": "execute",
189     "name": "execute RestApiCallNode - get-resource connection-attachment-allotted-resource",
190     "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n    <parameter name='restapiUrl' value='`$prop.controller.url + $tmp.ar-url-connection`' />\n    <parameter name='restapiUser' value='`$prop.controller.user`' />\n    <parameter name='restapiPassword' value='`$prop.controller.pwd`' />\n    <parameter name='format' value='json' />\n    <parameter name='httpMethod' value='GET' />\n    <parameter name=\"responsePrefix\" value=\"mdsal-providedAr\" />\n",
191     "comments": "",
192     "outputs": 1,
193     "x": 1297.8151321411133,
194     "y": 430.2390090227127,
195     "z": "4c77a098.14bed",
196     "wires": [
197       [
198         "4145e899.11bf48",
199         "75032056.67182"
200       ]
201     ]
202   },
203   {
204     "id": "4145e899.11bf48",
205     "type": "success",
206     "name": "success",
207     "xml": "<outcome value='success'>\n",
208     "comments": "",
209     "outputs": 1,
210     "x": 1673.185203552246,
211     "y": 430.7611274719238,
212     "z": "4c77a098.14bed",
213     "wires": [
214       [
215         "a6a898ea.1345e8"
216       ]
217     ]
218   },
219   {
220     "id": "75032056.67182",
221     "type": "other",
222     "name": "other",
223     "xml": "<outcome value='Other'>\n",
224     "comments": "",
225     "outputs": 1,
226     "x": 1665.0370063781738,
227     "y": 465.8272123336792,
228     "z": "4c77a098.14bed",
229     "wires": [
230       [
231         "b38b08ff.bf1c28"
232       ]
233     ]
234   },
235   {
236     "id": "a6a898ea.1345e8",
237     "type": "block",
238     "name": "block",
239     "xml": "<block>\n",
240     "atomic": "false",
241     "comments": "",
242     "outputs": 1,
243     "x": 1804.1852989196777,
244     "y": 430.7611885070801,
245     "z": "4c77a098.14bed",
246     "wires": [
247       []
248     ]
249   },
250   {
251     "id": "b38b08ff.bf1c28",
252     "type": "returnFailure",
253     "name": "return failure",
254     "xml": "<return status='failure'>\n\t<parameter name='ack-final' value='Y'/>\n\t<parameter name=\"error-code\" value=\"404\" />\n    <parameter name=\"error-message\" value=\"Error: Parent service data not available\" />\n    \n",
255     "comments": "",
256     "x": 1811.1857872009277,
257     "y": 465.0946235656738,
258     "z": "4c77a098.14bed",
259     "wires": []
260   },
261   {
262     "id": "ea908538.cdcb68",
263     "type": "set",
264     "name": "set model-data to input",
265     "xml": "<set>\n<parameter name='connection-attachment-topology-operation-input.allotted-resource-information.onap-model-information.' value=\"`$mdsal-providedAr.connection-attachment-allotted-resource[0].allotted-resource-data.connection-attachment-topology.onap-model-information.` \" />",
266     "comments": "",
267     "x": 1138.0001907348633,
268     "y": 565.0000371932983,
269     "z": "4c77a098.14bed",
270     "wires": []
271   },
272   {
273     "id": "b2b348e8.930c38",
274     "type": "set",
275     "name": "set connection-attachment-ar-identifiers to input",
276     "xml": "<set>\n<parameter name='connection-attachment-topology-operation-input.service-information.service-instance-id' value=\"`$mdsal-providedAr.connection-attachment-allotted-resource[0].allotted-resource-data.connection-attachment-topology.allotted-resource-identifiers.consuming-service-instance-id` \" />\n<parameter name='connection-attachment-topology-operation-input.allotted-resource-information.parent-service-instance-id' value=\"`$mdsal-providedAr.connection-attachment-allotted-resource[0].allotted-resource-data.connection-attachment-topology.allotted-resource-identifiers.parent-service-instance-id` \" />\n<parameter name='connection-attachment-topology-operation-input.allotted-resource-information.allotted-resource-type' value=\"`$mdsal-providedAr.connection-attachment-allotted-resource[0].allotted-resource-data.connection-attachment-topology.allotted-resource-identifiers.allotted-resource-type` \" />\n<parameter name='connection-attachment-topology-operation-input.allotted-resource-information.allotted-resource-id' value=\"`$mdsal-providedAr.connection-attachment-allotted-resource[0].allotted-resource-data.connection-attachment-topology.allotted-resource-identifiers.allotted-resource-id` \" />\n",
277     "comments": "",
278     "x": 1213.301872253418,
279     "y": 527.0159864425659,
280     "z": "4c77a098.14bed",
281     "wires": []
282   },
283   {
284     "id": "c0e08604.031d68",
285     "type": "set",
286     "name": "set ar-data to input",
287     "xml": "<set>\n<parameter name='connection-attachment-topology-operation-input.request-information.request-action' value=\"`$mdsal-providedAr.connection-attachment-allotted-resource[0].allotted-resource-status.action` \" />\n<parameter name='connection-attachment-topology-operation-input.sdnc-request-header.svc-action' value=\"`$mdsal-providedAr.connection-attachment-allotted-resource[0].allotted-resource-status.rpc-action` \" />\n<parameter name='connection-attachment-topology-operation-input.request-information.' value=\"`$mdsal-providedAr.connection-attachment-allotted-resource[0].allotted-resource-data.allotted-resource-operation-information.request-information.` \" />\n<parameter name='connection-attachment-topology-operation-input.sdnc-request-header.' value=\"`$mdsal-providedAr.connection-attachment-allotted-resource[0].allotted-resource-data.allotted-resource-operation-information.sdnc-request-header.` \" />\n<parameter name='connection-attachment-topology-operation-input.service-information.' value=\"`$mdsal-providedAr.connection-attachment-allotted-resource[0].allotted-resource-data.allotted-resource-operation-information.service-information.` \" />\n<parameter name='connection-attachment-topology-operation-input.allotted-resource-information.' value=\"`$mdsal-providedAr.connection-attachment-allotted-resource[0].allotted-resource-data.allotted-resource-operation-information.allotted-resource-information.` \" />\n<parameter name='connection-attachment-topology-operation-input.connection-attachment-request-input.' value=\"`$mdsal-providedAr.connection-attachment-allotted-resource[0].allotted-resource-data.allotted-resource-operation-information.connection-attachment-request-input.` \" />\n",
288     "comments": "",
289     "x": 1120.1586456298828,
290     "y": 485.8253927230835,
291     "z": "4c77a098.14bed",
292     "wires": []
293   },
294   {
295     "id": "4d332c82.ad3af4",
296     "type": "call",
297     "name": "call sotn-attachment-topology-operation-activate",
298     "xml": "<call module='GENERIC-RESOURCE-API' rpc='sotn-attachment-topology-operation-activate' mode='sync' >\n",
299     "comments": "",
300     "outputs": 1,
301     "x": 1214.0001945495605,
302     "y": 740.0000486373901,
303     "z": "4c77a098.14bed",
304     "wires": [
305       []
306     ]
307   },
308   {
309     "id": "9da5cea0.60ef2",
310     "type": "call",
311     "name": "call sotn-attachment-topology-operation-deactivate",
312     "xml": "<call module='GENERIC-RESOURCE-API' rpc='sotn-attachment-topology-operation-deactivate' mode='sync' >\n",
313     "comments": "",
314     "outputs": 1,
315     "x": 1223.0002746582031,
316     "y": 649.0000429153442,
317     "z": "4c77a098.14bed",
318     "wires": [
319       []
320     ]
321   },
322   {
323     "id": "a382c856.52c0b8",
324     "type": "set",
325     "name": "set request-action and svc-action",
326     "xml": "<set>\n<parameter name='connection-attachment-topology-operation-input.sdnc-request-header.svc-action' value=\"activate\" />\n<parameter name='connection-attachment-topology-operation-input.request-information.request-action' value=\"ActivateSOTNAttachmentInstance\" />\n\n\n",
327     "comments": "",
328     "x": 1169.0002746582031,
329     "y": 694.0000457763672,
330     "z": "4c77a098.14bed",
331     "wires": []
332   },
333   {
334     "id": "63bd98b8.1ea0d8",
335     "type": "set",
336     "name": "set request-action and svc-action",
337     "xml": "<set>\n<parameter name='connection-attachment-topology-operation-input.sdnc-request-header.svc-action' value=\"deactivate\" />\n<parameter name='connection-attachment-topology-operation-input.request-information.request-action' value=\"DeactivateSOTNAttachmentInstance\" />\n<parameter name='connection-attachment-topology-operation-input.service-information.global-customer-id' value=\"`$service-data.service-information.global-customer-id` \" />\n<parameter name='connection-attachment-topology-operation-input.service-information.subscription-service-type' value=\"`$service-data.service-information.subscription-service-type` \" />\n<parameter name='connection-attachment-topology-operation-input.service-information.subscriber-name' value=\"`$service-data.service-information.subscriber-name` \" />",
338     "comments": "",
339     "x": 1169.000114440918,
340     "y": 608.0000410079956,
341     "z": "4c77a098.14bed",
342     "wires": []
343   },
344   {
345     "id": "77dde683.c05af8",
346     "type": "set",
347     "name": "set service-data in tmp var",
348     "xml": "<set>\n<parameter name = 'tmp.service-data.' value=\"`$service-data.`\"/>\n",
349     "comments": "",
350     "x": 734.0001983642578,
351     "y": 237.00009441375732,
352     "z": "4c77a098.14bed",
353     "wires": []
354   },
355   {
356     "id": "c64a9e95.de368",
357     "type": "set",
358     "name": "set tmp.service-data to service-data",
359     "xml": "<set>\n<parameter name = 'service-data. '  value = \"`$tmp.service-data.`\"/>\n",
360     "comments": "",
361     "x": 837.0003814697266,
362     "y": 816.0001068115234,
363     "z": "4c77a098.14bed",
364     "wires": []
365   },
366   {
367     "id": "f4c6a746.18c888",
368     "type": "returnSuccess",
369     "name": "return success",
370     "xml": "<return status='success'>\n<parameter name=\"ack-final-indicator\" value=\"Y\" />\n<parameter name=\"error-code\" value=\"200\" />\n<parameter name=\"error-message\" value=\"`$error-message`\" />\n",
371     "comments": "",
372     "x": 758.0001831054688,
373     "y": 860.0000267028809,
374     "z": "4c77a098.14bed",
375     "wires": []
376   }
377 ]