SDWAN flow based end-end test and issue fix
[sdnc/oam.git] / platform-logic / generic-resource-api / src / main / json / GENERIC-RESOURCE-API_sdwan-vnf-topology-operation-device-delete.json
1 [
2   {
3     "id": "a1df0c8c.e610f",
4     "type": "switchNode",
5     "name": "switch service-data.vnfs.vnf_length",
6     "xml": "<switch test='`$service-data.vnfs.vnf_length`'>\n",
7     "comments": "",
8     "outputs": 1,
9     "x": 652.5634536743164,
10     "y": 312.26116919517517,
11     "z": "42785b1.0f2e6a4",
12     "wires": [
13       [
14         "a23f9932.76df28",
15         "eec5abe1.727dc8"
16       ]
17     ]
18   },
19   {
20     "id": "dda3e77b.e1de28",
21     "type": "dgstart",
22     "name": "DGSTART",
23     "outputs": 1,
24     "x": 114.46875,
25     "y": 76.9999988079071,
26     "z": "42785b1.0f2e6a4",
27     "wires": [
28       [
29         "b55d96f3.653dc8"
30       ]
31     ]
32   },
33   {
34     "id": "b55d96f3.653dc8",
35     "type": "service-logic",
36     "name": "GENERIC-RESOURCE-API ${project.version}",
37     "module": "GENERIC-RESOURCE-API",
38     "version": "${project.version}",
39     "comments": "",
40     "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}'>",
41     "outputs": 1,
42     "x": 189.75445556640625,
43     "y": 117.23811030387878,
44     "z": "42785b1.0f2e6a4",
45     "wires": [
46       [
47         "e0c2d3e0.8a2bb"
48       ]
49     ]
50   },
51   {
52     "id": "8ad52b68.cd0138",
53     "type": "comment",
54     "name": "wan port-vnf-topology-operation-delete",
55     "info": "",
56     "comments": "",
57     "x": 563.8136672973633,
58     "y": 150.58639788627625,
59     "z": "42785b1.0f2e6a4",
60     "wires": []
61   },
62   {
63     "id": "c136d1d8.af3e6",
64     "type": "block",
65     "name": "block : atomic",
66     "xml": "<block atomic=\"true\">",
67     "atomic": "true",
68     "outputs": 1,
69     "x": 191.13541412353516,
70     "y": 378.6666705608368,
71     "z": "42785b1.0f2e6a4",
72     "wires": [
73       [
74         "a72c9897.585208",
75         "d19a177f.7de988",
76         "30536e3.568f592",
77         "a1df0c8c.e610f",
78         "9db50f7b.a0897",
79         "4dffba9e.fd0434",
80         "28632f25.b7972",
81         "af6ad43e.5c24e8",
82         "743e7718.e7f968",
83         "4b8bdd76.d28184",
84         "cb6608fc.bd5f68"
85       ]
86     ]
87   },
88   {
89     "id": "a23f9932.76df28",
90     "type": "other",
91     "name": "outcome Null",
92     "xml": "<outcome value=''>\n",
93     "comments": "",
94     "outputs": 1,
95     "x": 917.2857666015625,
96     "y": 294.81679129600525,
97     "z": "42785b1.0f2e6a4",
98     "wires": [
99       [
100         "81cc943f.50f958"
101       ]
102     ]
103   },
104   {
105     "id": "81cc943f.50f958",
106     "type": "returnFailure",
107     "name": "return failure",
108     "xml": "<return status='failure'>\n\t<parameter name='ack-final' value='Y'/>\n\t<parameter name=\"error-code\" value=\"500\" />\n    <parameter name=\"error-message\" value=\"vnf-topology-operation-input.vnf-request-input.vnf-id not found in service-data\" />\n",
109     "comments": "",
110     "x": 1098.2856369018555,
111     "y": 289.81666922569275,
112     "z": "42785b1.0f2e6a4",
113     "wires": []
114   },
115   {
116     "id": "eec5abe1.727dc8",
117     "type": "other",
118     "name": "other",
119     "xml": "<outcome value='Other'>\n",
120     "comments": "",
121     "outputs": 1,
122     "x": 902.7857666015625,
123     "y": 346.8167541027069,
124     "z": "42785b1.0f2e6a4",
125     "wires": [
126       [
127         "679d4612.15d218"
128       ]
129     ]
130   },
131   {
132     "id": "679d4612.15d218",
133     "type": "block",
134     "name": "block : atomic",
135     "xml": "<block atomic=\"true\">",
136     "atomic": "true",
137     "outputs": 1,
138     "x": 1074.785472869873,
139     "y": 346.8167521953583,
140     "z": "42785b1.0f2e6a4",
141     "wires": [
142       [
143         "862951df.5fe1d",
144         "dc6fa4c3.5ecea8"
145       ]
146     ]
147   },
148   {
149     "id": "dc6fa4c3.5ecea8",
150     "type": "switchNode",
151     "name": "switch tmp.vidx ",
152     "xml": "<switch test=\"`$tmp.vidx`\">\n\n",
153     "comments": "",
154     "outputs": 1,
155     "x": 1249.78564453125,
156     "y": 365.81667399406433,
157     "z": "42785b1.0f2e6a4",
158     "wires": [
159       [
160         "1c173742.b90799"
161       ]
162     ]
163   },
164   {
165     "id": "30536e3.568f592",
166     "type": "switchNode",
167     "name": "switch vnf-level-oper-status",
168     "xml": "<switch test='`$service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-level-oper-status.order-status`'>\n",
169     "comments": "",
170     "outputs": 1,
171     "x": 622.9524536132812,
172     "y": 386.70563292503357,
173     "z": "42785b1.0f2e6a4",
174     "wires": [
175       [
176         "ba7f62e0.c87a8",
177         "246d8ed1.13b9e2"
178       ]
179     ]
180   },
181   {
182     "id": "ba7f62e0.c87a8",
183     "type": "outcome",
184     "name": "outcome PendingDelete",
185     "xml": "<outcome value='PendingDelete'>\n",
186     "comments": "",
187     "outputs": 1,
188     "x": 913.7857208251953,
189     "y": 390.81675601005554,
190     "z": "42785b1.0f2e6a4",
191     "wires": [
192       [
193         "7fe1211e.ac713"
194       ]
195     ]
196   },
197   {
198     "id": "246d8ed1.13b9e2",
199     "type": "other",
200     "name": "other",
201     "xml": "<outcome value='Other'>\n",
202     "comments": "",
203     "outputs": 1,
204     "x": 880.7858581542969,
205     "y": 442.8168087005615,
206     "z": "42785b1.0f2e6a4",
207     "wires": [
208       [
209         "7d27948.1b45c6c"
210       ]
211     ]
212   },
213   {
214     "id": "7d27948.1b45c6c",
215     "type": "returnFailure",
216     "name": "return failure",
217     "xml": "<return status='failure'>\n\t<parameter name='ack-final' value='Y'/>\n\t<parameter name=\"error-code\" value=\"500\" />\n    <parameter name=\"error-message\" value=\"`'VNF is not in appropriate state for activate. Current state is ' + $service-data.vnfs.vnf[$tmp.nidx].vnf-data.vnf-level-oper-status.order-status`\" />",
218     "comments": "",
219     "x": 1040.2856254577637,
220     "y": 445.8168077468872,
221     "z": "42785b1.0f2e6a4",
222     "wires": []
223   },
224   {
225     "id": "9db50f7b.a0897",
226     "type": "switchNode",
227     "name": "switch vnf-id",
228     "xml": "<switch test=\"`$vnf-topology-operation-input.vnf-information.vnf-id`\">\n",
229     "comments": "",
230     "outputs": 1,
231     "x": 588.7857704162598,
232     "y": 267.81676268577576,
233     "z": "42785b1.0f2e6a4",
234     "wires": [
235       [
236         "2d92055a.30ffda"
237       ]
238     ]
239   },
240   {
241     "id": "2d92055a.30ffda",
242     "type": "outcome",
243     "name": "NULL",
244     "xml": "<outcome value=''>",
245     "comments": "",
246     "outputs": 1,
247     "x": 786.7858352661133,
248     "y": 257.81677508354187,
249     "z": "42785b1.0f2e6a4",
250     "wires": [
251       [
252         "889ae61d.096b48"
253       ]
254     ]
255   },
256   {
257     "id": "889ae61d.096b48",
258     "type": "returnFailure",
259     "name": "return failure",
260     "xml": "<return status='failure'>\n\t<parameter name='ack-final' value='Y'/>\n\t<parameter name=\"error-code\" value=\"500\" />\n    <parameter name=\"error-message\" value=\"vnf-request-input.vnf-input-parameters.name is a required input\" />\n",
261     "comments": "",
262     "x": 953.2857208251953,
263     "y": 254.81676936149597,
264     "z": "42785b1.0f2e6a4",
265     "wires": []
266   },
267   {
268     "id": "862951df.5fe1d",
269     "type": "for",
270     "name": "for vidx..service-data.vnfs.vnf[]",
271     "xml": "<for index='vidx' start='0' end='`$service-data.vnfs.vnf_length`' >\n",
272     "comments": "",
273     "outputs": 1,
274     "x": 1310.2856483459473,
275     "y": 301.81667017936707,
276     "z": "42785b1.0f2e6a4",
277     "wires": [
278       [
279         "91f5b0d9.94102"
280       ]
281     ]
282   },
283   {
284     "id": "91f5b0d9.94102",
285     "type": "switchNode",
286     "name": "switch vnf-id found",
287     "xml": "<switch test=\"`$service-data.vnfs.vnf[$vidx].vnf-id == $vnf-topology-operation-input.vnf-information.vnf-id`\">\n\n",
288     "comments": "",
289     "outputs": 1,
290     "x": 1566.2856674194336,
291     "y": 301.81667017936707,
292     "z": "42785b1.0f2e6a4",
293     "wires": [
294       [
295         "8dc7c708.bc5718"
296       ]
297     ]
298   },
299   {
300     "id": "8dc7c708.bc5718",
301     "type": "outcomeTrue",
302     "name": "true",
303     "xml": "<outcome value='true'>\n",
304     "comments": "",
305     "outputs": 1,
306     "x": 1742.7857208251953,
307     "y": 304.81667017936707,
308     "z": "42785b1.0f2e6a4",
309     "wires": [
310       [
311         "2d4f17e9.19c368"
312       ]
313     ]
314   },
315   {
316     "id": "dd40fac0.73a058",
317     "type": "set",
318     "name": "set tmp.vidx and ctx.vnf-data",
319     "xml": "<set>\n<parameter name='tmp.vidx' value='`$vidx`' />\n<parameter name='ctx.vnf-data.' value='`$service-data.vnfs.vnf[$vidx].vnf-data.`' />\n",
320     "comments": "",
321     "x": 2159.785934448242,
322     "y": 383.8167221546173,
323     "z": "42785b1.0f2e6a4",
324     "wires": []
325   },
326   {
327     "id": "59a5fc66.f24204",
328     "type": "returnFailure",
329     "name": "return failure",
330     "xml": "<return status='failure'>\n\t<parameter name='ack-final' value='Y'/>\n\t<parameter name=\"error-code\" value=\"500\" />\n    <parameter name=\"error-message\" value=\"vnf-topology-operation-input.vnf-request-input.vnf-id not found in service-data\" />\n",
331     "comments": "",
332     "x": 1555.285659790039,
333     "y": 365.81667399406433,
334     "z": "42785b1.0f2e6a4",
335     "wires": []
336   },
337   {
338     "id": "1c173742.b90799",
339     "type": "outcome",
340     "name": "NULL",
341     "xml": "<outcome value=''>\n",
342     "comments": "",
343     "outputs": 1,
344     "x": 1417.785659790039,
345     "y": 365.81667399406433,
346     "z": "42785b1.0f2e6a4",
347     "wires": [
348       [
349         "59a5fc66.f24204"
350       ]
351     ]
352   },
353   {
354     "id": "a72c9897.585208",
355     "type": "set",
356     "name": "set vnfId and vnf-object-path",
357     "xml": "<set>\n<parameter name='vnfId' value='`$vnf-topology-operation-input.vnf-information.vnf-id`' />\n<parameter name='vnf-object-path' value=\"`'restconf/config/GENERIC-RESOURCE-API:services/service/'\n + $vnf-topology-operation-input.service-information.service-instance-id\n + '/service-data/service-topology/'` \" />",
358     "comments": "",
359     "x": 596.8022003173828,
360     "y": 689.3334522247314,
361     "z": "42785b1.0f2e6a4",
362     "wires": []
363   },
364   {
365     "id": "d19a177f.7de988",
366     "type": "returnSuccess",
367     "name": "return success",
368     "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",
369     "comments": "",
370     "x": 545.9133987426758,
371     "y": 808.8889608383179,
372     "z": "42785b1.0f2e6a4",
373     "wires": []
374   },
375   {
376     "id": "7fe1211e.ac713",
377     "type": "block",
378     "name": "block : atomic",
379     "xml": "<block atomic=\"true\">",
380     "atomic": "true",
381     "outputs": 1,
382     "x": 1111.0921211242676,
383     "y": 401.14191031455994,
384     "z": "42785b1.0f2e6a4",
385     "wires": [
386       []
387     ]
388   },
389   {
390     "id": "e0c2d3e0.8a2bb",
391     "type": "method",
392     "name": "method sdwan-vnf-topology-operation-device-delete",
393     "xml": "<method rpc='sdwan-vnf-topology-operation-device-delete' mode='sync'>\n",
394     "comments": "",
395     "outputs": 1,
396     "x": 195,
397     "y": 233.26116919517517,
398     "z": "42785b1.0f2e6a4",
399     "wires": [
400       [
401         "c136d1d8.af3e6"
402       ]
403     ]
404   },
405   {
406     "id": "4dffba9e.fd0434",
407     "type": "execute",
408     "name": "execute requiredParameters",
409     "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliPluginUtils' method='requiredParameters' >\n<parameter name=\"vnf-topology-operation-input.vnf-information.vnf-id\" value=\"$vnf-topology-operation-input.vnf-information.vnf-id\"/>\n\n",
410     "comments": "",
411     "outputs": 1,
412     "x": 646.2858276367188,
413     "y": 207.81676173210144,
414     "z": "42785b1.0f2e6a4",
415     "wires": [
416       []
417     ]
418   },
419   {
420     "id": "7385dfef.35179",
421     "type": "delete",
422     "name": "delete wan port instance configuration in AAI",
423     "xml": "<delete plugin=\"org.onap.ccsdk.sli.adaptors.aai.AAIService\" resource='device' \n        key='device.id = $vnf-topology-operation-input.vnf-information.vnf-id'>\n",
424     "comments": "",
425     "outputs": 1,
426     "x": 1073.0003051757812,
427     "y": 744.261435508728,
428     "z": "42785b1.0f2e6a4",
429     "wires": [
430       []
431     ]
432   },
433   {
434     "id": "3c959d82.f7e672",
435     "type": "call",
436     "name": "call sdwan-get-device-param",
437     "xml": "<call module='GENERIC-RESOURCE-API' rpc='sdwan-get-device-param' mode='sync' >\n",
438     "comments": "",
439     "outputs": 1,
440     "x": 2151.5635147094727,
441     "y": 328.2611758708954,
442     "z": "42785b1.0f2e6a4",
443     "wires": [
444       []
445     ]
446   },
447   {
448     "id": "5f3e6fd4.e37e8",
449     "type": "set",
450     "name": "set vnf-request-input.",
451     "xml": "<set>\n<parameter name='vnf-request-input.' value='`$ctx.vnf-data.vnf-data.vnf-request-input.`' />\n\n",
452     "comments": "",
453     "x": 2146.923065185547,
454     "y": 265.81170535087585,
455     "z": "42785b1.0f2e6a4",
456     "wires": []
457   },
458   {
459     "id": "94ec2391.e8ee4",
460     "type": "set",
461     "name": "set tmp.vidx and ctx.vnf-data",
462     "xml": "<set>\n<parameter name='tmp.vidx' value='`$vidx`' />\n<parameter name='ctx.vnf-data.' value='`$service-data.vnfs.vnf[$vidx].`' />\n",
463     "comments": "",
464     "x": 2174.476776123047,
465     "y": 219.15406966209412,
466     "z": "42785b1.0f2e6a4",
467     "wires": []
468   },
469   {
470     "id": "2d4f17e9.19c368",
471     "type": "block",
472     "name": "block : atomic",
473     "xml": "<block atomic=\"true\">",
474     "atomic": "true",
475     "outputs": 1,
476     "x": 1912.563331604004,
477     "y": 306.26116919517517,
478     "z": "42785b1.0f2e6a4",
479     "wires": [
480       [
481         "dd40fac0.73a058",
482         "3c959d82.f7e672",
483         "5f3e6fd4.e37e8",
484         "94ec2391.e8ee4"
485       ]
486     ]
487   },
488   {
489     "id": "28632f25.b7972",
490     "type": "switchNode",
491     "name": "switch prop.device.sdncCreate",
492     "xml": "<switch test=\"`$prop.device.sdncCreate`\">\n",
493     "comments": "",
494     "outputs": 1,
495     "x": 597.5636672973633,
496     "y": 752.2614345550537,
497     "z": "42785b1.0f2e6a4",
498     "wires": [
499       [
500         "d02123b.6bfe7e"
501       ]
502     ]
503   },
504   {
505     "id": "d02123b.6bfe7e",
506     "type": "outcomeTrue",
507     "name": "true",
508     "xml": "<outcome value='true'>\n",
509     "comments": "",
510     "outputs": 1,
511     "x": 804.5635223388672,
512     "y": 749.2612714767456,
513     "z": "42785b1.0f2e6a4",
514     "wires": [
515       [
516         "7385dfef.35179"
517       ]
518     ]
519   },
520   {
521     "id": "af6ad43e.5c24e8",
522     "type": "set",
523     "name": "set prop.vnfNewidx",
524     "xml": "<set>\n<parameter name='prop.vnfidxLen' value='`0`' />\n",
525     "comments": "",
526     "x": 589.0000381469727,
527     "y": 454.0000276565552,
528     "z": "42785b1.0f2e6a4",
529     "wires": []
530   },
531   {
532     "id": "743e7718.e7f968",
533     "type": "for",
534     "name": "for lidx..service-data.vnfs.vnf[]",
535     "xml": "<for index='lidx' start='0' end='`$service-data.vnfs.vnf_length`' >\n",
536     "comments": "",
537     "outputs": 1,
538     "x": 615.9999580383301,
539     "y": 518.0000123977661,
540     "z": "42785b1.0f2e6a4",
541     "wires": [
542       [
543         "25a69c7c.cd2204"
544       ]
545     ]
546   },
547   {
548     "id": "25a69c7c.cd2204",
549     "type": "block",
550     "name": "block : atomic",
551     "xml": "<block atomic=\"true\">",
552     "atomic": "true",
553     "outputs": 1,
554     "x": 859.9999389648438,
555     "y": 543.9999718666077,
556     "z": "42785b1.0f2e6a4",
557     "wires": [
558       [
559         "2e7532f9.d7b9be"
560       ]
561     ]
562   },
563   {
564     "id": "2e7532f9.d7b9be",
565     "type": "switchNode",
566     "name": "switch vnf-id found",
567     "xml": "<switch test=\"`$service-data.vnfs.vnf[$lidx].vnf-id == $vnf-topology-operation-input.vnf-information.vnf-id`\">\n\n",
568     "comments": "",
569     "outputs": 1,
570     "x": 1051.999885559082,
571     "y": 553.0000162124634,
572     "z": "42785b1.0f2e6a4",
573     "wires": [
574       [
575         "fb34ff49.abebe"
576       ]
577     ]
578   },
579   {
580     "id": "4b8bdd76.d28184",
581     "type": "set",
582     "name": "set new vnf length",
583     "xml": "<set>\n\t<parameter name=\"service-data.vnfs.vnf_length\" value='`$prop.vnfidxLen`'/>\n\n\t\n",
584     "comments": "",
585     "x": 582.1013412475586,
586     "y": 568.8043041229248,
587     "z": "42785b1.0f2e6a4",
588     "wires": []
589   },
590   {
591     "id": "fb34ff49.abebe",
592     "type": "outcomeFalse",
593     "name": "false",
594     "xml": "<outcome value='false'>\n",
595     "comments": "",
596     "outputs": 1,
597     "x": 1237.999900817871,
598     "y": 536.9999027252197,
599     "z": "42785b1.0f2e6a4",
600     "wires": [
601       [
602         "aa789605.e97ae8"
603       ]
604     ]
605   },
606   {
607     "id": "aa789605.e97ae8",
608     "type": "block",
609     "name": "block : atomic",
610     "xml": "<block atomic=\"true\">",
611     "atomic": "true",
612     "outputs": 1,
613     "x": 1388.9998245239258,
614     "y": 537.9999389648438,
615     "z": "42785b1.0f2e6a4",
616     "wires": [
617       [
618         "79843b9d.c445e4",
619         "fcd82b9e.5e0628"
620       ]
621     ]
622   },
623   {
624     "id": "79843b9d.c445e4",
625     "type": "set",
626     "name": "set  vnf data",
627     "xml": "<set>\n<parameter name='service-data.vnfs.vnf[$prop.vnfidxLen].vnf-id' value='`$service-data.vnfs.vnf[$lidx].vnf-id`' />\n<parameter name='service-data.vnfs.vnf[$prop.vnfidxLen].vnf-data.' value='`$service-data.vnfs.vnf[$lidx].vnf-data.`' />\n",
628     "comments": "",
629     "x": 1553.9999198913574,
630     "y": 513.0000944137573,
631     "z": "42785b1.0f2e6a4",
632     "wires": []
633   },
634   {
635     "id": "fcd82b9e.5e0628",
636     "type": "set",
637     "name": "set prop.vnfNewidx",
638     "xml": "<set>\n<parameter name='prop.vnfidxLen' value='`$prop.vnfidxLen + 1`' />\n",
639     "comments": "",
640     "x": 1575.9999198913574,
641     "y": 569.0000581741333,
642     "z": "42785b1.0f2e6a4",
643     "wires": []
644   },
645   {
646     "id": "cb6608fc.bd5f68",
647     "type": "set",
648     "name": "Remove vnf from ServiceData",
649     "xml": "<set>\n\t<parameter name=\"service-data.vnfs.vnf[$prop.vnfidxLen].\" value=\"\"/>\n\n",
650     "comments": "",
651     "x": 621,
652     "y": 630,
653     "z": "42785b1.0f2e6a4",
654     "wires": []
655   }
656 ]