cfccd825c6a06c9c6a0b9d5cf9b21e510db79dc9
[sdnc/oam.git] / platform-logic / generic-resource-api / src / main / json / GENERIC-RESOURCE-API_dci-connects-network-topology-operation-deactivate.json
1 [
2   {
3     "id":"148f01b9.7651be",
4     "type":"dgstart",
5     "name":"DGSTART",
6     "outputs":1,
7     "x":127.66666412353516,
8     "y":59.666664123535156,
9     "z":"b8d6a9b7.54bca8",
10     "wires":[
11       [
12         "75389724.73d1d8"
13       ]
14     ]
15   },
16   {
17     "id":"75389724.73d1d8",
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":388.66666412353516,
26     "y":130.66666412353516,
27     "z":"b8d6a9b7.54bca8",
28     "wires":[
29       [
30         "c572bb07.b4aab8"
31       ]
32     ]
33   },
34   {
35     "id":"c572bb07.b4aab8",
36     "type":"method",
37     "name":"method dci-connects-network-topology-operation-deactivate",
38     "xml":"<method rpc='dci-connects-network-topology-operation-deactivate' mode='sync'>\n",
39     "comments":"",
40     "outputs":1,
41     "x":278.66666412353516,
42     "y":215.66666412353516,
43     "z":"b8d6a9b7.54bca8",
44     "wires":[
45       [
46         "2e7d9d36.9e8932"
47       ]
48     ]
49   },
50   {
51     "id":"2e7d9d36.9e8932",
52     "type":"block",
53     "name":"block : atomic",
54     "xml":"<block atomic=\"true\">",
55     "atomic":"true",
56     "outputs":1,
57     "x":613.6666793823242,
58     "y":215.66667366027832,
59     "z":"b8d6a9b7.54bca8",
60     "wires":[
61       [
62         "b8044390.c16c5",
63         "d126698a.8dba88",
64         "3c585b18.c1b394",
65         "17e0f0e1.f4a85f",
66         "c13afebf.e4af7"
67       ]
68     ]
69   },
70   {
71     "id":"b8044390.c16c5",
72     "type":"call",
73     "name":"call GENERIC-RESOURCE-API:validate-network-input-parameters",
74     "xml":"<call module='GENERIC-RESOURCE-API' rpc='validate-network-input-parameters' mode='sync' >\n",
75     "comments":"",
76     "outputs":1,
77     "x":948.6666641235352,
78     "y":84.66666412353516,
79     "z":"b8d6a9b7.54bca8",
80     "wires":[
81       [
82
83       ]
84     ]
85   },
86   {
87     "id":"d126698a.8dba88",
88     "type":"returnSuccess",
89     "name":"return success",
90     "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",
91     "comments":"",
92     "x":814.6666412353516,
93     "y":863.6666374206543,
94     "z":"b8d6a9b7.54bca8",
95     "wires":[
96
97     ]
98   },
99   {
100     "id":"a0179072.b0699",
101     "type":"block",
102     "name":"block : sendRequest",
103     "xml":"<block atomic=\"true\">",
104     "atomic":"true",
105     "comments":"",
106     "outputs":1,
107     "x":1010.1666946411133,
108     "y":559.1823291778564,
109     "z":"b8d6a9b7.54bca8",
110     "wires":[
111       [
112         "2004f909.4303c6",
113         "8f1e5d77.2d978",
114         "db4a772d.b48518",
115         "a9badb26.f8ff08"
116       ]
117     ]
118   },
119   {
120     "id":"48d3ef18.744f9",
121     "type":"success",
122     "name":"success",
123     "xml":"<outcome value='success'>\n",
124     "comments":"",
125     "outputs":1,
126     "x":1542.666591644287,
127     "y":356.1818552017212,
128     "z":"b8d6a9b7.54bca8",
129     "wires":[
130       [
131         "f3e0b35b.ac7e6"
132       ]
133     ]
134   },
135   {
136     "id":"1f0ce6e6.d7e319",
137     "type":"not-found",
138     "name":"not-found",
139     "xml":"<outcome value='not-found'>\n",
140     "comments":"",
141     "outputs":1,
142     "x":1549.666591644287,
143     "y":394.1818552017212,
144     "z":"b8d6a9b7.54bca8",
145     "wires":[
146       [
147         "25422e06.a06362"
148       ]
149     ]
150   },
151   {
152     "id":"c9371824.9cf4a8",
153     "type":"other",
154     "name":"other",
155     "xml":"<outcome value='Other'>\n",
156     "comments":"",
157     "outputs":1,
158     "x":1541.666591644287,
159     "y":436.1818552017212,
160     "z":"b8d6a9b7.54bca8",
161     "wires":[
162       [
163         "caa6b2ac.fdad4"
164       ]
165     ]
166   },
167   {
168     "id":"f3e0b35b.ac7e6",
169     "type":"block",
170     "name":"block : atomic",
171     "xml":"<block atomic=\"true\">\n",
172     "atomic":"false",
173     "comments":"",
174     "outputs":1,
175     "x":1707.666591644287,
176     "y":345.1818552017212,
177     "z":"b8d6a9b7.54bca8",
178     "wires":[
179       [
180
181       ]
182     ]
183   },
184   {
185     "id":"25422e06.a06362",
186     "type":"returnFailure",
187     "name":"return failure",
188     "xml":"<return status='failure'>\n<parameter name='error-code' value='' />\n<parameter name='error-message' value='' />\n",
189     "comments":"",
190     "x":1706.666591644287,
191     "y":398.1818552017212,
192     "z":"b8d6a9b7.54bca8",
193     "wires":[
194
195     ]
196   },
197   {
198     "id":"caa6b2ac.fdad4",
199     "type":"returnFailure",
200     "name":"return failure",
201     "xml":"<return status='failure'>\n<parameter name='error-code' value='' />\n<parameter name='error-message' value='' />\n",
202     "comments":"",
203     "x":1699.666591644287,
204     "y":445.1818552017212,
205     "z":"b8d6a9b7.54bca8",
206     "wires":[
207
208     ]
209   },
210   {
211     "id":"2004f909.4303c6",
212     "type":"get-resource",
213     "name":"get-resource esr-thirdparty-sdnc",
214     "xml":"<get-resource plugin=\"org.onap.ccsdk.sli.adaptors.aai.AAIService\" \n\t\tresource=\"esr-thirdparty-sdnc\" \n\t\tkey=\"esr-thirdparty-sdnc.thirdparty-sdnc-id = $prop.dci-connects.id AND \n\t\t     depth = '1'\"\n        pfx='tmp.aai.esr-thirdparty-sdnc' local-only='false' >\n",
215     "comments":"",
216     "outputs":1,
217     "x":1318.6666793823242,
218     "y":403.18186211586,
219     "z":"b8d6a9b7.54bca8",
220     "wires":[
221       [
222         "48d3ef18.744f9",
223         "1f0ce6e6.d7e319",
224         "c9371824.9cf4a8"
225       ]
226     ]
227   },
228   {
229     "id":"8f1e5d77.2d978",
230     "type":"set",
231     "name":"set controller data",
232     "xml":"<set>\n<parameter name='prop.sdncRestApi.thirdpartySdnc.url' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list[0].esr-system-info.serviceUrl`\" />\n<parameter name='prop.sdncRestApi.templateDir' value='/opt/onap/sdnc/data' />\n<parameter name='prop.sdncRestApi.thirdpartySdnc.user' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list[0].esr-system-info.user-name`\" />\n<parameter name='prop.sdncRestApi.thirdpartySdnc.password' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list[0].esr-system-info.password`\" />\n\n",
233     "comments":"",
234     "x":1290.1665306091309,
235     "y":504.6818163394928,
236     "z":"b8d6a9b7.54bca8",
237     "wires":[
238
239     ]
240   },
241   {
242     "id":"fc904692.6194d8",
243     "type":"execute",
244     "name":"execute RestApiCallNode De-Activate Vxlan Tunnel",
245     "xml":"<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"restapiUrl\" value=\"$prop.sdncRestApi.thirdpartySdnc.url + '/v2.0/l3-dci-connects/' + $prop.dci-connects.id\"/>\n<parameter name=\"restapiUser\" value=\"$prop.sdncRestApi.thirdpartySdnc.user\"/>\n<parameter name=\"restapiPassword\" value=\"$prop.sdncRestApi.thirdpartySdnc.password\"/>\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"delete\"/>\n<parameter name=\"responsePrefix\" value=\"restapi-result\"/>\n",
246     "comments":"",
247     "outputs":1,
248     "x":1818.1669692993164,
249     "y":622.1822843551636,
250     "z":"b8d6a9b7.54bca8",
251     "wires":[
252       [
253
254       ]
255     ]
256   },
257   {
258     "id":"db4a772d.b48518",
259     "type":"switchNode",
260     "name":"switch tunnelType",
261     "xml":"<switch test=\"`$prop.dci-connects.tunnelType`\">\n",
262     "comments":"",
263     "outputs":1,
264     "x":1281.1664276123047,
265     "y":646.6817951202393,
266     "z":"b8d6a9b7.54bca8",
267     "wires":[
268       [
269         "435458d3.7f7428",
270         "ac616ba.5114198"
271       ]
272     ]
273   },
274   {
275     "id":"435458d3.7f7428",
276     "type":"outcomeTrue",
277     "name":"L3-DCI",
278     "xml":"<outcome value='L3-DCI'>\n",
279     "comments":"",
280     "outputs":1,
281     "x":1494.1665573120117,
282     "y":626.6817951202393,
283     "z":"b8d6a9b7.54bca8",
284     "wires":[
285       [
286         "fc904692.6194d8"
287       ]
288     ]
289   },
290   {
291     "id":"ac616ba.5114198",
292     "type":"outcomeTrue",
293     "name":"L2-DCI",
294     "xml":"<outcome value='L2-DCI'>\n",
295     "comments":"",
296     "outputs":1,
297     "x":1492.1663780212402,
298     "y":698.6817951202393,
299     "z":"b8d6a9b7.54bca8",
300     "wires":[
301       [
302         "43446998.00c4b8"
303       ]
304     ]
305   },
306   {
307     "id":"43446998.00c4b8",
308     "type":"execute",
309     "name":"execute RestApiCallNode De-Activate Vxlan Tunnel",
310     "xml":"<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"restapiUrl\" value=\"$prop.sdncRestApi.thirdpartySdnc.url + '/v2.0/l2-dci-connects/' + $prop.dci-connects.id\"/>\n<parameter name=\"restapiUser\" value=\"$prop.sdncRestApi.thirdpartySdnc.user\"/>\n<parameter name=\"restapiPassword\" value=\"$prop.sdncRestApi.thirdpartySdnc.password\"/>\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"delete\"/>\n<parameter name=\"responsePrefix\" value=\"restapi-result\"/>",
311     "comments":"",
312     "outputs":1,
313     "x":1812.1669235229492,
314     "y":699.1822204589844,
315     "z":"b8d6a9b7.54bca8",
316     "wires":[
317       [
318
319       ]
320     ]
321   },
322   {
323     "id":"f950c622.50d2c8",
324     "type":"for",
325     "name":"for each network-input-parameters",
326     "xml":"<for index='idx' start='0' end='`$service-data.networks.network[$tmp.nidx].network-data.network-request-input.network-input-parameters.param_length`' >\n\n",
327     "comments":"",
328     "outputs":1,
329     "x":1072.666648864746,
330     "y":160.18229579925537,
331     "z":"b8d6a9b7.54bca8",
332     "wires":[
333       [
334         "2803809e.cd6f9"
335       ]
336     ]
337   },
338   {
339     "id":"a9badb26.f8ff08",
340     "type":"record",
341     "name":"record",
342     "xml":"<record plugin=\"org.onap.ccsdk.sli.core.sli.recording.Slf4jRecorder\">\n<parameter name=\"logger\" value=\"message-log\"/>\n<parameter name=\"field1\" value=\"__TIMESTAMP__\"/>\n<parameter name=\"field2\" value=\"dci-network-topology-operation-deactivate\"/>\n<parameter name=\"field3\" value=\"dci-connects.id\" />\n<parameter name=\"field4\" value=\"`$prop.dci-connects.id`\"/>\n<parameter name=\"field5\" value=\"dci-connects.tunnelType\" />\n<parameter name=\"field6\" value=\"`$prop.dci-connects.tunnelType`\"/>\n<parameter name=\"field7\" value=\"dci-connects.tunnelType\" />\n<parameter name=\"field8\" value=\"`$prop.dci-connects.tunnelType`\"/>\n<parameter name=\"field9\" value=\"sdncRestApi.thirdpartySdnc.url\"/>\n<parameter name=\"field10\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url`\"/>",
343     "comments":"",
344     "outputs":1,
345     "x":1255.0000305175781,
346     "y":578.6666641235352,
347     "z":"b8d6a9b7.54bca8",
348     "wires":[
349       [
350
351       ]
352     ]
353   },
354   {
355     "id":"2803809e.cd6f9",
356     "type":"block",
357     "name":"block",
358     "xml":"<block>\n",
359     "atomic":"false",
360     "comments":"",
361     "outputs":1,
362     "x":1306.0000915527344,
363     "y":159.6666717529297,
364     "z":"b8d6a9b7.54bca8",
365     "wires":[
366       [
367         "b059e691.786878",
368         "e3c86ec7.af8ef"
369       ]
370     ]
371   },
372   {
373     "id":"b059e691.786878",
374     "type":"switchNode",
375     "name":"switch site1_id",
376     "xml":"<switch test=\"`$service-data.networks.network[$tmp.nidx].network-data.network-request-input.network-input-parameters.param[$idx].name == 'site1_id'`\">\n",
377     "comments":"",
378     "outputs":1,
379     "x":1512.3333015441895,
380     "y":128.66666793823242,
381     "z":"b8d6a9b7.54bca8",
382     "wires":[
383       [
384         "6b8958be.1a4d18"
385       ]
386     ]
387   },
388   {
389     "id":"6b8958be.1a4d18",
390     "type":"outcomeTrue",
391     "name":"true",
392     "xml":"<outcome value='true'>\n",
393     "comments":"",
394     "outputs":1,
395     "x":1713.333396911621,
396     "y":127.6666669845581,
397     "z":"b8d6a9b7.54bca8",
398     "wires":[
399       [
400         "4c747d09.9d8e34"
401       ]
402     ]
403   },
404   {
405     "id":"4c747d09.9d8e34",
406     "type":"set",
407     "name":"set id",
408     "xml":"<set>\n<parameter name='prop.dci-connects.id' value='`$service-data.networks.network[$tmp.nidx].network-data.network-request-input.network-input-parameters.param[$idx].value`' />\n",
409     "comments":"",
410     "x":1886.9997482299805,
411     "y":127.33321189880371,
412     "z":"b8d6a9b7.54bca8",
413     "wires":[
414
415     ]
416   },
417   {
418     "id":"e3c86ec7.af8ef",
419     "type":"switchNode",
420     "name":"switch tunnelType",
421     "xml":"<switch test=\"`$service-data.networks.network[$tmp.nidx].network-data.network-request-input.network-input-parameters.param[$idx].name == 'tunnelType'`\">\n",
422     "comments":"",
423     "outputs":1,
424     "x":1522.333381652832,
425     "y":181.6666738986969,
426     "z":"b8d6a9b7.54bca8",
427     "wires":[
428       [
429         "53a3a5f5.60a92c"
430       ]
431     ]
432   },
433   {
434     "id":"53a3a5f5.60a92c",
435     "type":"outcomeTrue",
436     "name":"true",
437     "xml":"<outcome value='true'>\n",
438     "comments":"",
439     "outputs":1,
440     "x":1728.333381652832,
441     "y":181.6666738986969,
442     "z":"b8d6a9b7.54bca8",
443     "wires":[
444       [
445         "e41570df.a2318"
446       ]
447     ]
448   },
449   {
450     "id":"e41570df.a2318",
451     "type":"set",
452     "name":"set tunnelType",
453     "xml":"<set>\n<parameter name='prop.dci-connects.tunnelType' value='`$service-data.networks.network[$tmp.nidx].network-data.network-request-input.network-input-parameters.param[$idx].value`' />\n",
454     "comments":"",
455     "x":1897.333480834961,
456     "y":181.66668915748596,
457     "z":"b8d6a9b7.54bca8",
458     "wires":[
459
460     ]
461   },
462   {
463     "id":"3c585b18.c1b394",
464     "type":"block",
465     "name":"block : executeSite1",
466     "xml":"<block atomic=\"true\">",
467     "atomic":"true",
468     "comments":"",
469     "outputs":1,
470     "x":802,
471     "y":161.3333282470703,
472     "z":"b8d6a9b7.54bca8",
473     "wires":[
474       [
475         "f950c622.50d2c8",
476         "a0179072.b0699"
477       ]
478     ]
479   },
480   {
481     "id":"3cc5f533.01012a",
482     "type":"for",
483     "name":"for each network-input-parameters",
484     "xml":"<for index='idx' start='0' end='`$service-data.networks.network[$tmp.nidx].network-data.network-request-input.network-input-parameters.param_length`' >\n\n",
485     "comments":"",
486     "outputs":1,
487     "x":1077.666732788086,
488     "y":266.3332996368408,
489     "z":"b8d6a9b7.54bca8",
490     "wires":[
491       [
492         "38542283.614a3e"
493       ]
494     ]
495   },
496   {
497     "id":"38542283.614a3e",
498     "type":"block",
499     "name":"block",
500     "xml":"<block>\n",
501     "atomic":"false",
502     "comments":"",
503     "outputs":1,
504     "x":1306.000099182129,
505     "y":268.81767559051514,
506     "z":"b8d6a9b7.54bca8",
507     "wires":[
508       [
509         "4cb30828.1cc3b8"
510       ]
511     ]
512   },
513   {
514     "id":"4cb30828.1cc3b8",
515     "type":"switchNode",
516     "name":"switch site2_id",
517     "xml":"<switch test=\"`$service-data.networks.network[$tmp.nidx].network-data.network-request-input.network-input-parameters.param[$idx].name == 'site2_id'`\">\n",
518     "comments":"",
519     "outputs":1,
520     "x":1507.0000495910645,
521     "y":268.8176612854004,
522     "z":"b8d6a9b7.54bca8",
523     "wires":[
524       [
525         "dd6bc853.9b86f8"
526       ]
527     ]
528   },
529   {
530     "id":"dd6bc853.9b86f8",
531     "type":"outcomeTrue",
532     "name":"true",
533     "xml":"<outcome value='true'>\n",
534     "comments":"",
535     "outputs":1,
536     "x":1708.000144958496,
537     "y":267.8176603317261,
538     "z":"b8d6a9b7.54bca8",
539     "wires":[
540       [
541         "eabf42ba.5e4d4"
542       ]
543     ]
544   },
545   {
546     "id":"eabf42ba.5e4d4",
547     "type":"set",
548     "name":"set id",
549     "xml":"<set>\n<parameter name='prop.dci-connects.id' value='`$service-data.networks.network[$tmp.nidx].network-data.network-request-input.network-input-parameters.param[$idx].value`' />\n",
550     "comments":"",
551     "x":1881.6664962768555,
552     "y":267.4842052459717,
553     "z":"b8d6a9b7.54bca8",
554     "wires":[
555
556     ]
557   },
558   {
559     "id":"17e0f0e1.f4a85f",
560     "type":"block",
561     "name":"block : executeSite1",
562     "xml":"<block atomic=\"true\">",
563     "atomic":"true",
564     "comments":"",
565     "outputs":1,
566     "x":802.0000076293945,
567     "y":270.48433208465576,
568     "z":"b8d6a9b7.54bca8",
569     "wires":[
570       [
571         "3cc5f533.01012a",
572         "a0179072.b0699"
573       ]
574     ]
575   },
576   {
577     "id":"ba49b6c1.a72218",
578     "type":"set",
579     "name":"set object-path",
580     "xml":"<set>\n<parameter name='network-object-path' value=\"`'restconf/config/GENERIC-RESOURCE-API:services/service/'\n + $network-topology-operation-input.service-information.service-instance-id\n + '/service-data/networks/network/'\n + $networkId\n + '/network-data/network-topology/'` \" />\n \n",
581     "comments":"",
582     "x":1117.0039901733398,
583     "y":791.5274066925049,
584     "z":"b8d6a9b7.54bca8",
585     "wires":[
586
587     ]
588   },
589   {
590     "id":"378e343e.0cb45c",
591     "type":"set",
592     "name":"set networkId",
593     "xml":"<set>\n<parameter name='networkId' value='`$network-topology-operation-input.network-information.network-id`' />\n",
594     "comments":"",
595     "x":1111.289623260498,
596     "y":754.3845148086548,
597     "z":"b8d6a9b7.54bca8",
598     "wires":[
599
600     ]
601   },
602   {
603     "id":"c13afebf.e4af7",
604     "type":"block",
605     "name":"block : saveNetworkData",
606     "xml":"<block atomic=\"true\">",
607     "atomic":"true",
608     "comments":"",
609     "outputs":1,
610     "x":854.0000610351562,
611     "y":730.3333559036255,
612     "z":"b8d6a9b7.54bca8",
613     "wires":[
614       [
615         "378e343e.0cb45c",
616         "ba49b6c1.a72218",
617         "44d19a8f.ba7544",
618         "e247e731.bf5fd8"
619       ]
620     ]
621   },
622   {
623     "id":"74d41b77.b05d54",
624     "type":"comment",
625     "name":"TODO",
626     "info":"Currently deactivate does deletion too, later divide in two phases.",
627     "comments":"",
628     "x":736,
629     "y":23.666664123535156,
630     "z":"b8d6a9b7.54bca8",
631     "wires":[
632
633     ]
634   },
635   {
636     "id":"44d19a8f.ba7544",
637     "type":"set",
638     "name":"copy input to service-data",
639     "xml":"<set>\n<parameter name='service-data.networks.network[$tmp.nidx].network-data.sdnc-request-header.' value='`$network-topology-operation-input.sdnc-request-header.`' />\n<parameter name='service-data.networks.network[$tmp.nidx].network-data.request-information.' value='`$network-topology-operation-input.request-information.`' />\n",
640     "comments":"",
641     "x":1147.0000686645508,
642     "y":710.6666679382324,
643     "z":"b8d6a9b7.54bca8",
644     "wires":[
645
646     ]
647   },
648   {
649     "id":"e247e731.bf5fd8",
650     "type":"set",
651     "name":"set network-level-oper-status",
652     "xml":"<set>\n<parameter name='service-data.networks.network[$tmp.nidx].network-data.network-level-oper-status.order-status' value='Deleted' />\n<parameter name='service-data.networks.network[$tmp.nidx].network-data.network-level-oper-status.last-rpc-action' value='`$network-topology-operation-input.sdnc-request-header.svc-action`' />\n<parameter name='service-data.networks.network[$tmp.nidx].network-data.network-level-oper-status.last-action' value='`$network-topology-operation-input.request-information.request-action`' />\n",
653     "comments":"",
654     "x":1161,
655     "y":838.6666259765625,
656     "z":"b8d6a9b7.54bca8",
657     "wires":[
658
659     ]
660   }
661 ]