1f6af4fef518c569d79bde910f570c91c4c62b98
[sdnc/oam.git] / platform-logic / generic-resource-api / src / main / json / GENERIC-RESOURCE-API_sdwan-vnf-topology-operation-wanport-activate.json
1 [
2   {
3     "id": "fea5a9bd.a03d18",
4     "type": "dgstart",
5     "name": "DGSTART",
6     "outputs": 1,
7     "x": 86.00390625,
8     "y": 44.999999046325684,
9     "z": "3545e2b7.8c73ce",
10     "wires": [
11       [
12         "e45f8bd6.497e68"
13       ]
14     ]
15   },
16   {
17     "id": "e45f8bd6.497e68",
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": 234.2895965576172,
26     "y": 95.23810768127441,
27     "z": "3545e2b7.8c73ce",
28     "wires": [
29       [
30         "f0f23207.f8f43"
31       ]
32     ]
33   },
34   {
35     "id": "f0f23207.f8f43",
36     "type": "method",
37     "name": "method sdwan-vnf-topology-operation-wanport-activate",
38     "xml": "<method rpc='sdwan-vnf-topology-operation-wanport-activate' mode='sync'>\n",
39     "comments": "",
40     "outputs": 1,
41     "x": 237.43252563476562,
42     "y": 180.00003147125244,
43     "z": "3545e2b7.8c73ce",
44     "wires": [
45       [
46         "32849d64.f1ae32"
47       ]
48     ]
49   },
50   {
51     "id": "32849d64.f1ae32",
52     "type": "block",
53     "name": "block : atomic",
54     "xml": "<block atomic=\"true\">",
55     "atomic": "true",
56     "outputs": 1,
57     "x": 300.67066192626953,
58     "y": 785.6669883728027,
59     "z": "3545e2b7.8c73ce",
60     "wires": [
61       [
62         "dc92d74f.dca7a8",
63         "1cf85990.ed3b86",
64         "b4c4037f.4ac1e",
65         "f3c230b1.3312b",
66         "ac816a8a.6fb1f8",
67         "e9d0f6cd.99c098",
68         "62f05310.c79d2c",
69         "ca279788.45f118",
70         "aece4931.30eed8",
71         "d9e42142.36e4c",
72         "eaa46981.c8da08",
73         "2847803.c88858",
74         "a3465abe.51b3e8",
75         "ea6762c6.702c5",
76         "33c90daa.1c8182",
77         "81b0e70b.0576d8",
78         "e220c2f5.e3641",
79         "cd49784f.a3cd48"
80       ]
81     ]
82   },
83   {
84     "id": "dc92d74f.dca7a8",
85     "type": "returnSuccess",
86     "name": "return success",
87     "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",
88     "comments": "",
89     "x": 639.3383979797363,
90     "y": 1527.3344058990479,
91     "z": "3545e2b7.8c73ce",
92     "wires": []
93   },
94   {
95     "id": "eaa46981.c8da08",
96     "type": "execute",
97     "name": "execute RestApiCallNode device port create",
98     "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/sdwan-port.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/net/ports'`\" />\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=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"portResp\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.openecomp.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />",
99     "comments": "",
100     "outputs": 1,
101     "x": 715.3380165100098,
102     "y": 780.8894968032837,
103     "z": "3545e2b7.8c73ce",
104     "wires": [
105       [
106         "65c0152d.40a98c",
107         "6523c3cc.277f2c"
108       ]
109     ]
110   },
111   {
112     "id": "65c0152d.40a98c",
113     "type": "success",
114     "name": "success",
115     "xml": "<outcome value='success'>\n",
116     "comments": "",
117     "outputs": 1,
118     "x": 964.3380756378174,
119     "y": 794.889702796936,
120     "z": "3545e2b7.8c73ce",
121     "wires": [
122       [
123         "9cca9a95.c82758"
124       ]
125     ]
126   },
127   {
128     "id": "6523c3cc.277f2c",
129     "type": "failure",
130     "name": "failure",
131     "xml": "<outcome value='failure'>\n",
132     "comments": "",
133     "outputs": 1,
134     "x": 964.3380756378174,
135     "y": 756.8895382881165,
136     "z": "3545e2b7.8c73ce",
137     "wires": [
138       [
139         "d75e1634.f465a8"
140       ]
141     ]
142   },
143   {
144     "id": "d75e1634.f465a8",
145     "type": "returnFailure",
146     "name": "return failure",
147     "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=\"Error executing Create device port rest api\" />\n",
148     "comments": "",
149     "x": 1108.3384094238281,
150     "y": 755.8895378112793,
151     "z": "3545e2b7.8c73ce",
152     "wires": []
153   },
154   {
155     "id": "9cca9a95.c82758",
156     "type": "block",
157     "name": "block : atomic",
158     "xml": "<block atomic=\"true\">",
159     "atomic": "true",
160     "comments": "",
161     "outputs": 1,
162     "x": 1111.3380870819092,
163     "y": 795.8895416259766,
164     "z": "3545e2b7.8c73ce",
165     "wires": [
166       []
167     ]
168   },
169   {
170     "id": "a3465abe.51b3e8",
171     "type": "execute",
172     "name": "execute RestApiCallNode get transport network info",
173     "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/sdwan-network-orchestration.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/net/network-orchestration-resources'`\" />\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=\"get\"/>\n<parameter name=\"responsePrefix\" value=\"transportNetworksResp\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.openecomp.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />",
174     "comments": "",
175     "outputs": 1,
176     "x": 738.0043678283691,
177     "y": 960.0006022453308,
178     "z": "3545e2b7.8c73ce",
179     "wires": [
180       [
181         "91b71ecc.ea421",
182         "dad0aff7.4b6c2"
183       ]
184     ]
185   },
186   {
187     "id": "81b0e70b.0576d8",
188     "type": "execute",
189     "name": "execute RestApiCallNode wan port create",
190     "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/sdwan-wan-port.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/net/transport-network-ports'`\" />\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=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"wanPortResp\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.openecomp.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />",
191     "comments": "",
192     "outputs": 1,
193     "x": 711.0044593811035,
194     "y": 1197.0006504058838,
195     "z": "3545e2b7.8c73ce",
196     "wires": [
197       [
198         "b0038d4b.581a3",
199         "fdc236b1.efb848"
200       ]
201     ]
202   },
203   {
204     "id": "1cf85990.ed3b86",
205     "type": "switchNode",
206     "name": "switch service-data.vnfs.vnf_length",
207     "xml": "<switch test='`$service-data.vnfs.vnf_length`'>\n",
208     "comments": "",
209     "outputs": 1,
210     "x": 697.0248413085938,
211     "y": 124.02091121673584,
212     "z": "3545e2b7.8c73ce",
213     "wires": [
214       [
215         "d1aa4aa.5bcccb8",
216         "7a701067.ec473",
217         "6e75ccb1.58cf34"
218       ]
219     ]
220   },
221   {
222     "id": "d1aa4aa.5bcccb8",
223     "type": "other",
224     "name": "Null",
225     "xml": "<outcome value=''>\n",
226     "comments": "",
227     "outputs": 1,
228     "x": 949.0248756408691,
229     "y": 125.02099227905273,
230     "z": "3545e2b7.8c73ce",
231     "wires": [
232       [
233         "4988f92c.8e1ab8"
234       ]
235     ]
236   },
237   {
238     "id": "4988f92c.8e1ab8",
239     "type": "returnFailure",
240     "name": "return failure",
241     "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",
242     "comments": "",
243     "x": 1110.8026237487793,
244     "y": 104.90993928909302,
245     "z": "3545e2b7.8c73ce",
246     "wires": []
247   },
248   {
249     "id": "7a701067.ec473",
250     "type": "other",
251     "name": "other",
252     "xml": "<outcome value='Other'>\n",
253     "comments": "",
254     "outputs": 1,
255     "x": 942.0252838134766,
256     "y": 158.02099609375,
257     "z": "3545e2b7.8c73ce",
258     "wires": [
259       [
260         "ba03b0d7.0be36"
261       ]
262     ]
263   },
264   {
265     "id": "ba03b0d7.0be36",
266     "type": "block",
267     "name": "block : atomic",
268     "xml": "<block atomic=\"true\">",
269     "atomic": "true",
270     "outputs": 1,
271     "x": 960.2947769165039,
272     "y": 320.5755786895752,
273     "z": "3545e2b7.8c73ce",
274     "wires": [
275       [
276         "24648014.ff824",
277         "5aa1ffdc.05015",
278         "a65a9125.dc54c",
279         "ae97242b.dc5558",
280         "acc92682.3c6fd8"
281       ]
282     ]
283   },
284   {
285     "id": "24648014.ff824",
286     "type": "for",
287     "name": "for vidx..service-data.vnfs.vnf_length[]",
288     "xml": "<for index='vidx' start='0' end='`$service-data.vnfs.vnf_length`' >\n",
289     "comments": "",
290     "outputs": 1,
291     "x": 1245.3109436035156,
292     "y": 150.44955730438232,
293     "z": "3545e2b7.8c73ce",
294     "wires": [
295       [
296         "1aa311e.b073aee"
297       ]
298     ]
299   },
300   {
301     "id": "5aa1ffdc.05015",
302     "type": "switchNode",
303     "name": "switch tmp.vidx ",
304     "xml": "<switch test=\"`$tmp.vidx`\">\n\n",
305     "comments": "",
306     "outputs": 1,
307     "x": 1171.612247467041,
308     "y": 296.4327926635742,
309     "z": "3545e2b7.8c73ce",
310     "wires": [
311       [
312         "93a97c9.4fbf08"
313       ]
314     ]
315   },
316   {
317     "id": "93a97c9.4fbf08",
318     "type": "outcome",
319     "name": "NULL",
320     "xml": "<outcome value=''>\n",
321     "comments": "",
322     "outputs": 1,
323     "x": 1319.0408897399902,
324     "y": 296.0042028427124,
325     "z": "3545e2b7.8c73ce",
326     "wires": [
327       [
328         "c3cf31a6.b52f"
329       ]
330     ]
331   },
332   {
333     "id": "b192d0.2d48dd3",
334     "type": "switchNode",
335     "name": "switch vnfid found",
336     "xml": "<switch test=\"`$service-data.vnfs.vnf[$vidx].vnf-id == $vnf-topology-operation-input.vnf-information.vnf-id`\">\n\n",
337     "comments": "",
338     "outputs": 1,
339     "x": 1618.7401733398438,
340     "y": 149.6997194290161,
341     "z": "3545e2b7.8c73ce",
342     "wires": [
343       [
344         "801ede81.82f43"
345       ]
346     ]
347   },
348   {
349     "id": "c3cf31a6.b52f",
350     "type": "returnFailure",
351     "name": "return failure",
352     "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",
353     "comments": "",
354     "x": 1468.4696159362793,
355     "y": 297.14712047576904,
356     "z": "3545e2b7.8c73ce",
357     "wires": []
358   },
359   {
360     "id": "801ede81.82f43",
361     "type": "outcomeTrue",
362     "name": "true",
363     "xml": "<outcome value='true'>\n",
364     "comments": "",
365     "outputs": 1,
366     "x": 1773.6921653747559,
367     "y": 150.59239864349365,
368     "z": "3545e2b7.8c73ce",
369     "wires": [
370       [
371         "7772ec9b.efcac4"
372       ]
373     ]
374   },
375   {
376     "id": "db3e11bd.eb0ca",
377     "type": "set",
378     "name": "set tmp.vidx and ctx.vnf-data",
379     "xml": "<set>\n<parameter name='tmp.vidx' value='`$vidx`' />\n<parameter name='ctx.vnf-data.' value='`$service-data.vnfs.vnf[$vidx].`' />\n",
380     "comments": "",
381     "x": 2181.224250793457,
382     "y": 60.34245681762695,
383     "z": "3545e2b7.8c73ce",
384     "wires": []
385   },
386   {
387     "id": "6e75ccb1.58cf34",
388     "type": "outcome",
389     "name": "0",
390     "xml": "<outcome value='0'>\n",
391     "comments": "",
392     "outputs": 1,
393     "x": 950.9936256408691,
394     "y": 88.98967838287354,
395     "z": "3545e2b7.8c73ce",
396     "wires": [
397       [
398         "4988f92c.8e1ab8"
399       ]
400     ]
401   },
402   {
403     "id": "cd49784f.a3cd48",
404     "type": "set",
405     "name": "set device PortId and wan portId to service data",
406     "xml": "<set>\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length].name' value='devicePortId' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length].value' value='`$prop.wan.devicePortId`' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length + 1].name' value='wanPortId' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length + 1].value' value='`$prop.wan.wanPortId`' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length' value='`$service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length + 2`' />\n\n\n\n\n",
407     "comments": "",
408     "x": 734.9947814941406,
409     "y": 1318.9909219741821,
410     "z": "3545e2b7.8c73ce",
411     "wires": []
412   },
413   {
414     "id": "abae1674.12b3d8",
415     "type": "comment",
416     "name": "Get siteId from site resource created for this service",
417     "info": "",
418     "comments": "",
419     "x": 722.9938888549805,
420     "y": 309.32321548461914,
421     "z": "3545e2b7.8c73ce",
422     "wires": []
423   },
424   {
425     "id": "1aa311e.b073aee",
426     "type": "block",
427     "name": "block",
428     "xml": "<block>\n",
429     "atomic": "false",
430     "comments": "",
431     "outputs": 1,
432     "x": 1464.6605758666992,
433     "y": 149.98963737487793,
434     "z": "3545e2b7.8c73ce",
435     "wires": [
436       [
437         "b192d0.2d48dd3"
438       ]
439     ]
440   },
441   {
442     "id": "b4c4037f.4ac1e",
443     "type": "set",
444     "name": "set vnfId and vnf-object-path",
445     "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/'  + $vnf-topology-operation-input.service-information.service-instance-id  + '/service-data/vnfs/vnf/'  + $vnf-topology-operation-input.vnf-information.vnf-id  + '/vnf-data/'` \" />",
446     "comments": "",
447     "x": 672.5501022338867,
448     "y": 1406.2128171920776,
449     "z": "3545e2b7.8c73ce",
450     "wires": []
451   },
452   {
453     "id": "f3c230b1.3312b",
454     "type": "set",
455     "name": "set vnf-level-oper-status to Active",
456     "xml": "<set>\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-level-oper-status.order-status' value='Active' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-level-oper-status.last-rpc-action' value='`$vnf-topology-operation-input.sdnc-request-header.svc-action`' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.vnf-level-oper-status.last-action' value='`$vnf-topology-operation-input.request-information.request-action`' />\n",
457     "comments": "",
458     "x": 689.9945640563965,
459     "y": 1445.990653038025,
460     "z": "3545e2b7.8c73ce",
461     "wires": []
462   },
463   {
464     "id": "da8588c8.55f098",
465     "type": "update",
466     "name": "save SDWAN wan port instance configuration in AAI",
467     "xml": "<update plugin='org.onap.ccsdk.sli.adaptors.aai.AAIService' resource='wan-port-config' \n      key='wan-port-config.id = $service-data.vnfs.vnf[$tmp.vidx].vnf-id' >\n<parameter name=\"id\" value=\"`$service-data.vnfs.vnf[$tmp.vidx].vnf-id`\" />\n<parameter name='operational-status' value='Active' />\n<parameter name='device-port-id' value='`$prop.wan.devicePortId`' />\n<parameter name='wan-port-id' value='`$prop.wan.wanPortId`' />\n<parameter name='model-customization-id' value='`$vnf-topology-operation-input.vnf-information.onap-model-information.model-customization-uuid`' />\n<parameter name='model-invariant-id' value='`$vnf-topology-operation-input.vnf-information.onap-model-information.model-invariant-uuid`' />\n<parameter name='model-version-id' value='`$vnf-topology-operation-input.vnf-information.onap-model-information.model-uuid`' />\n",
468     "comments": "",
469     "outputs": 1,
470     "x": 752.6574897766113,
471     "y": 1485.1381149291992,
472     "z": "3545e2b7.8c73ce",
473     "wires": [
474       []
475     ]
476   },
477   {
478     "id": "d902b620.732c58",
479     "type": "set",
480     "name": "set prop.wan.transportNetworkId",
481     "xml": "<set>\n<parameter name='prop.wan.transportNetworkId' value='`$transportNetworksResp[$tidx].id`' />\n",
482     "comments": "",
483     "x": 1492.995449066162,
484     "y": 1036.9906740188599,
485     "z": "3545e2b7.8c73ce",
486     "wires": []
487   },
488   {
489     "id": "ac816a8a.6fb1f8",
490     "type": "for",
491     "name": "for loop sidx - Get siteId from servicedata",
492     "xml": "<for index=\"sidx\" start=\"0\" end=\"`$ctx.site.vnf-data.vnf-request-input.vnf-input-parameters.param_length`\">\n    \n    \n",
493     "comments": "",
494     "outputs": 1,
495     "x": 702.9939117431641,
496     "y": 459.98987197875977,
497     "z": "3545e2b7.8c73ce",
498     "wires": [
499       [
500         "f946d98b.8721e8"
501       ]
502     ]
503   },
504   {
505     "id": "6e3361b7.a1918",
506     "type": "switchNode",
507     "name": "switch siteId",
508     "xml": "<switch test=\"`$ctx.site.vnf-data.vnf-request-input.vnf-input-parameters.param[$sidx].name == 'siteId'`\">\n",
509     "comments": "",
510     "outputs": 1,
511     "x": 1133.994239807129,
512     "y": 460.9900026321411,
513     "z": "3545e2b7.8c73ce",
514     "wires": [
515       [
516         "628588c5.8c4528"
517       ]
518     ]
519   },
520   {
521     "id": "628588c5.8c4528",
522     "type": "outcomeTrue",
523     "name": "true",
524     "xml": "<outcome value='true'>\n",
525     "comments": "",
526     "outputs": 1,
527     "x": 1271.9946975708008,
528     "y": 458.98998737335205,
529     "z": "3545e2b7.8c73ce",
530     "wires": [
531       [
532         "b0597272.0a65f"
533       ]
534     ]
535   },
536   {
537     "id": "b0597272.0a65f",
538     "type": "set",
539     "name": "set prop.wan.siteId",
540     "xml": "<set>\n<parameter name='prop.wan.siteId' value='`$ctx.site.vnf-data.vnf-request-input.vnf-input-parameters.param[$sidx].value`' />\n\n\n",
541     "comments": "",
542     "x": 1435.9947319030762,
543     "y": 460.58984088897705,
544     "z": "3545e2b7.8c73ce",
545     "wires": []
546   },
547   {
548     "id": "33c90daa.1c8182",
549     "type": "execute",
550     "name": "execute split ip and mask",
551     "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='split' >\n<parameter name=\"original_string\" value='`$prop.ipAddress`'/>\n<parameter name=\"regex\" value=\"/\"/>\n<parameter name=\"ctx_memory_result_key\" value=\"ipandMask\"/>\n",
552     "comments": "",
553     "outputs": 1,
554     "x": 661.9942359924316,
555     "y": 1105.323642730713,
556     "z": "3545e2b7.8c73ce",
557     "wires": [
558       [
559         "d21f243c.e29608",
560         "61bef1c0.f032f"
561       ]
562     ]
563   },
564   {
565     "id": "61bef1c0.f032f",
566     "type": "failure",
567     "name": "success",
568     "xml": "<outcome value='success'>\n",
569     "comments": "",
570     "outputs": 1,
571     "x": 862.994255065918,
572     "y": 1083.323634147644,
573     "z": "3545e2b7.8c73ce",
574     "wires": [
575       [
576         "dba59ea6.fb87c"
577       ]
578     ]
579   },
580   {
581     "id": "d21f243c.e29608",
582     "type": "failure",
583     "name": "failure",
584     "xml": "<outcome value='failure'>\n",
585     "comments": "",
586     "outputs": 1,
587     "x": 862.9942588806152,
588     "y": 1124.3236379623413,
589     "z": "3545e2b7.8c73ce",
590     "wires": [
591       [
592         "5e04d6ae.a87ea8"
593       ]
594     ]
595   },
596   {
597     "id": "dba59ea6.fb87c",
598     "type": "set",
599     "name": "set ipAddress prefixLength",
600     "xml": "<set>\n<parameter name='prop.wan.ip-address' value='`$ipandMask[0]`' />\n<parameter name='prop.wan.prefixLength' value='`$ipandMask[1]`' />",
601     "comments": "",
602     "x": 1059.9942741394043,
603     "y": 1081.323634147644,
604     "z": "3545e2b7.8c73ce",
605     "wires": []
606   },
607   {
608     "id": "5e04d6ae.a87ea8",
609     "type": "returnFailure",
610     "name": "return failure",
611     "xml": "<return status='failure'>\n<parameter name='error-code' value='' />\n<parameter name='error-message' value=\"An error occured while splitting sna1_route\" />\n",
612     "comments": "",
613     "x": 1017.9942665100098,
614     "y": 1121.323637008667,
615     "z": "3545e2b7.8c73ce",
616     "wires": []
617   },
618   {
619     "id": "aece4931.30eed8",
620     "type": "get-resource",
621     "name": "get-resource esr-thirdparty-sdnc",
622     "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 = SDWAN-Controller AND \n\t\t     depth = '1'\"\n        pfx='tmp.aai.esr-thirdparty-sdnc' local-only='false' >\n\n",
623     "comments": "",
624     "outputs": 1,
625     "x": 696.4940643310547,
626     "y": 559.9899234771729,
627     "z": "3545e2b7.8c73ce",
628     "wires": [
629       [
630         "acfff48e.adde88",
631         "cfdab1ae.df7ca",
632         "3d21e606.ef145a"
633       ]
634     ]
635   },
636   {
637     "id": "acfff48e.adde88",
638     "type": "success",
639     "name": "success",
640     "xml": "<outcome value='success'>\n",
641     "comments": "",
642     "outputs": 1,
643     "x": 909.4941635131836,
644     "y": 521.989951133728,
645     "z": "3545e2b7.8c73ce",
646     "wires": [
647       [
648         "caaa91ba.7a205"
649       ]
650     ]
651   },
652   {
653     "id": "cfdab1ae.df7ca",
654     "type": "not-found",
655     "name": "not-found",
656     "xml": "<outcome value='not-found'>\n",
657     "comments": "",
658     "outputs": 1,
659     "x": 911.9850463867188,
660     "y": 557.5639877319336,
661     "z": "3545e2b7.8c73ce",
662     "wires": [
663       [
664         "43a0c2ab.03d7fc"
665       ]
666     ]
667   },
668   {
669     "id": "3d21e606.ef145a",
670     "type": "other",
671     "name": "other",
672     "xml": "<outcome value='Other'>\n",
673     "comments": "",
674     "outputs": 1,
675     "x": 907.3180541992188,
676     "y": 593.897346496582,
677     "z": "3545e2b7.8c73ce",
678     "wires": [
679       [
680         "5c31ca17.841574"
681       ]
682     ]
683   },
684   {
685     "id": "5c31ca17.841574",
686     "type": "returnFailure",
687     "name": "return failure",
688     "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=\"`'Unexpected error occurred while querying esr-thirdparty-sdnc from AnAI with thirdparty-sdnc-id = ' + $tmp.thirdparty-sdnc-id`\" />\n\n",
689     "comments": "",
690     "x": 1061.0905456542969,
691     "y": 591.3364334106445,
692     "z": "3545e2b7.8c73ce",
693     "wires": []
694   },
695   {
696     "id": "43a0c2ab.03d7fc",
697     "type": "returnFailure",
698     "name": "return failure",
699     "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=\"`'An error occurred while querying esr-thirdparty-sdnc from AnAI with thirdparty-sdnc-id = ' + $tmp.thirdparty-sdnc-id`\" />\n\n",
700     "comments": "",
701     "x": 1057.5564422607422,
702     "y": 555.8496751785278,
703     "z": "3545e2b7.8c73ce",
704     "wires": []
705   },
706   {
707     "id": "caaa91ba.7a205",
708     "type": "set",
709     "name": "set controller data",
710     "xml": "<set>\n<parameter name='prop.sdncRestApi.thirdpartySdnc.url' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].service-url`\" />\n<parameter name='prop.sdncRestApi.thirdpartySdnc.user' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].user-name`\" />\n<parameter name='prop.sdncRestApi.thirdpartySdnc.password' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].password`\" />\n",
711     "comments": "",
712     "x": 1069.9942741394043,
713     "y": 519.9898910522461,
714     "z": "3545e2b7.8c73ce",
715     "wires": []
716   },
717   {
718     "id": "e9d0f6cd.99c098",
719     "type": "record",
720     "name": "record",
721     "xml": "<record plugin=\"org.onap.ccsdk.sli.core.sli.recording.FileRecorder\">\n<parameter name=\"file\" value=\"/opt/opendaylight/current/data/log/svclogic.log\"/>\n<parameter name=\"field1\" value=\"__TIMESTAMP__\"/>\n<parameter name=\"field2\" value=\"sdwan-wanport-vnf-topology-operation-activate\"/>\n<parameter name=\"field3\" value=\"SDWAN-Activate\"/>\n",
722     "comments": "",
723     "outputs": 1,
724     "x": 615.0040016174316,
725     "y": 180.00002908706665,
726     "z": "3545e2b7.8c73ce",
727     "wires": [
728       []
729     ]
730   },
731   {
732     "id": "62f05310.c79d2c",
733     "type": "execute",
734     "name": "execute Properties",
735     "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",
736     "comments": "",
737     "outputs": 1,
738     "x": 651.3061256408691,
739     "y": 215.0000729560852,
740     "z": "3545e2b7.8c73ce",
741     "wires": [
742       []
743     ]
744   },
745   {
746     "id": "d9e42142.36e4c",
747     "type": "execute",
748     "name": "execute RestApiCallNode Get token",
749     "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/actokentemplate.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/v2/tokens'`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"token-result\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.openecomp.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>",
750     "comments": "",
751     "outputs": 1,
752     "x": 699.004207611084,
753     "y": 649.6669254302979,
754     "z": "3545e2b7.8c73ce",
755     "wires": [
756       [
757         "dbf3792f.06d4c8",
758         "ba692605.0e2fb8"
759       ]
760     ]
761   },
762   {
763     "id": "dbf3792f.06d4c8",
764     "type": "success",
765     "name": "success",
766     "xml": "<outcome value='success'>\n",
767     "comments": "",
768     "outputs": 1,
769     "x": 927.004337310791,
770     "y": 631.6669187545776,
771     "z": "3545e2b7.8c73ce",
772     "wires": [
773       [
774         "2ce328a2.bcfc88"
775       ]
776     ]
777   },
778   {
779     "id": "2ce328a2.bcfc88",
780     "type": "set",
781     "name": "set token-id",
782     "xml": "<set>\n<parameter name='prop.sdncRestApi.token_id' value='`$token-result.data.token_id`' />\n",
783     "comments": "",
784     "x": 1069.0043449401855,
785     "y": 630.666919708252,
786     "z": "3545e2b7.8c73ce",
787     "wires": []
788   },
789   {
790     "id": "eb7128c2.0605b8",
791     "type": "returnFailure",
792     "name": "return failure",
793     "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=\"Error executing get token rest api\" />\n",
794     "comments": "",
795     "x": 1075.0043449401855,
796     "y": 668.059907913208,
797     "z": "3545e2b7.8c73ce",
798     "wires": []
799   },
800   {
801     "id": "ba692605.0e2fb8",
802     "type": "failure",
803     "name": "failure",
804     "xml": "<outcome value='failure'>\n",
805     "comments": "",
806     "outputs": 1,
807     "x": 926.254337310791,
808     "y": 667.3098258972168,
809     "z": "3545e2b7.8c73ce",
810     "wires": [
811       [
812         "eb7128c2.0605b8"
813       ]
814     ]
815   },
816   {
817     "id": "ea6762c6.702c5",
818     "type": "for",
819     "name": "for loop tidx - Get transportNetwork ID",
820     "xml": "<for index=\"tidx\" start=\"0\" end=\"`$transportNetworksResp.transportNetworks_length`\">\n    \n    \n",
821     "comments": "",
822     "outputs": 1,
823     "x": 695.0043983459473,
824     "y": 995.3335218429565,
825     "z": "3545e2b7.8c73ce",
826     "wires": [
827       [
828         "f45abeac.b55fa"
829       ]
830     ]
831   },
832   {
833     "id": "f45abeac.b55fa",
834     "type": "block",
835     "name": "block",
836     "xml": "<block>\n",
837     "atomic": "false",
838     "comments": "",
839     "outputs": 1,
840     "x": 911.0047798156738,
841     "y": 996.3337659835815,
842     "z": "3545e2b7.8c73ce",
843     "wires": [
844       [
845         "8c6e090d.8c7a88"
846       ]
847     ]
848   },
849   {
850     "id": "8c6e090d.8c7a88",
851     "type": "switchNode",
852     "name": "switch transportNetworkName same",
853     "xml": "<switch test=\"`$transportNetworksResp.transportNetworks[$tidx].name == $prop.wan.transportNetworkName`\">\n\n",
854     "comments": "",
855     "outputs": 1,
856     "x": 1132.0050621032715,
857     "y": 994.6670722961426,
858     "z": "3545e2b7.8c73ce",
859     "wires": [
860       [
861         "9c44e433.9ec8a8"
862       ]
863     ]
864   },
865   {
866     "id": "9c44e433.9ec8a8",
867     "type": "outcomeTrue",
868     "name": "true",
869     "xml": "<outcome value='true'>\n",
870     "comments": "",
871     "outputs": 1,
872     "x": 1345.0045127868652,
873     "y": 994.6669902801514,
874     "z": "3545e2b7.8c73ce",
875     "wires": [
876       [
877         "d902b620.732c58"
878       ]
879     ]
880   },
881   {
882     "id": "570db1f7.cbe77",
883     "type": "switchNode",
884     "name": "switch ActivateSDWANDeviceInstance",
885     "xml": "<switch test=\"`$service-data.vnfs.vnf[$vidx].vnf-data.request-information.request-action == 'ActivateSDWANDeviceInstance'`\">\n    \n    \n\n",
886     "comments": "",
887     "outputs": 1,
888     "x": 1559.3375091552734,
889     "y": 227.00005626678467,
890     "z": "3545e2b7.8c73ce",
891     "wires": [
892       [
893         "8b1ff3eb.69d25"
894       ]
895     ]
896   },
897   {
898     "id": "8b1ff3eb.69d25",
899     "type": "outcomeTrue",
900     "name": "true",
901     "xml": "<outcome value='true'>\n",
902     "comments": "",
903     "outputs": 1,
904     "x": 1782.3375186920166,
905     "y": 227.00005626678467,
906     "z": "3545e2b7.8c73ce",
907     "wires": [
908       [
909         "48e7d6a0.748938"
910       ]
911     ]
912   },
913   {
914     "id": "c26d092c.4da7c8",
915     "type": "set",
916     "name": "set tmp.devicevidx",
917     "xml": "<set>\n<parameter name='tmp.devicevidx' value='`$vidx`' />\n\n",
918     "comments": "",
919     "x": 2747.3368530273438,
920     "y": 658.0000810623169,
921     "z": "3545e2b7.8c73ce",
922     "wires": []
923   },
924   {
925     "id": "a65a9125.dc54c",
926     "type": "switchNode",
927     "name": "switch tmp.devicevidx",
928     "xml": "<switch test=\"`$tmp.devicevidx`\">\n\n",
929     "comments": "",
930     "outputs": 1,
931     "x": 1212.3374366760254,
932     "y": 385.0001187324524,
933     "z": "3545e2b7.8c73ce",
934     "wires": [
935       [
936         "432fe6b0.129348"
937       ]
938     ]
939   },
940   {
941     "id": "432fe6b0.129348",
942     "type": "outcome",
943     "name": "NULL",
944     "xml": "<outcome value=''>\n",
945     "comments": "",
946     "outputs": 1,
947     "x": 1396.7660026550293,
948     "y": 385.57155561447144,
949     "z": "3545e2b7.8c73ce",
950     "wires": [
951       [
952         "4e59531.7ac0fac"
953       ]
954     ]
955   },
956   {
957     "id": "4e59531.7ac0fac",
958     "type": "returnFailure",
959     "name": "return failure",
960     "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=\"ActivateSDWANDeviceInstance not found in service-data\" />\n",
961     "comments": "",
962     "x": 1537.1947441101074,
963     "y": 385.7144351005554,
964     "z": "3545e2b7.8c73ce",
965     "wires": []
966   },
967   {
968     "id": "81f1ba7c.aa1808",
969     "type": "comment",
970     "name": "Get deviceId from device resource created for this service",
971     "info": "",
972     "comments": "",
973     "x": 2196.6707916259766,
974     "y": 324.3333349227905,
975     "z": "3545e2b7.8c73ce",
976     "wires": []
977   },
978   {
979     "id": "c653d564.103fb8",
980     "type": "for",
981     "name": "for loop didx - Get deviceId from servicedata",
982     "xml": "<for index=\"didx\" start=\"0\" end=\"`$service-data.vnfs.vnf[$vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length`\">\n    \n    \n",
983     "comments": "",
984     "outputs": 1,
985     "x": 2182.671001434326,
986     "y": 247.99997901916504,
987     "z": "3545e2b7.8c73ce",
988     "wires": [
989       [
990         "b9b11207.7934a"
991       ]
992     ]
993   },
994   {
995     "id": "7c90973.05bfa68",
996     "type": "switchNode",
997     "name": "switch name (DeviceName)",
998     "xml": "<switch test=\"`$service-data.vnfs.vnf[$vidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$didx].name == 'name'`\">\n",
999     "comments": "",
1000     "outputs": 1,
1001     "x": 2200.671600341797,
1002     "y": 386.00022411346436,
1003     "z": "3545e2b7.8c73ce",
1004     "wires": [
1005       [
1006         "41a73401.a0e75c"
1007       ]
1008     ]
1009   },
1010   {
1011     "id": "41a73401.a0e75c",
1012     "type": "outcomeTrue",
1013     "name": "true",
1014     "xml": "<outcome value='true'>\n",
1015     "comments": "",
1016     "outputs": 1,
1017     "x": 2402.672092437744,
1018     "y": 380.0002841949463,
1019     "z": "3545e2b7.8c73ce",
1020     "wires": [
1021       [
1022         "edf1bf9c.83bf3"
1023       ]
1024     ]
1025   },
1026   {
1027     "id": "f946d98b.8721e8",
1028     "type": "block",
1029     "name": "block : atomic",
1030     "xml": "<block atomic=\"true\">",
1031     "atomic": "true",
1032     "outputs": 1,
1033     "x": 965.0041046142578,
1034     "y": 460.6666965484619,
1035     "z": "3545e2b7.8c73ce",
1036     "wires": [
1037       [
1038         "6e3361b7.a1918"
1039       ]
1040     ]
1041   },
1042   {
1043     "id": "b9b11207.7934a",
1044     "type": "block",
1045     "name": "block : atomic",
1046     "xml": "<block atomic=\"true\">",
1047     "atomic": "true",
1048     "outputs": 1,
1049     "x": 1975.003890991211,
1050     "y": 384.6667251586914,
1051     "z": "3545e2b7.8c73ce",
1052     "wires": [
1053       [
1054         "7c90973.05bfa68"
1055       ]
1056     ]
1057   },
1058   {
1059     "id": "f5314270.2417a",
1060     "type": "switchNode",
1061     "name": "switch deviceId",
1062     "xml": "<switch test=\"`$service-data.vnfs.vnf[$vidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$deviceidx].name == 'deviceId'`\">\n",
1063     "comments": "",
1064     "outputs": 1,
1065     "x": 3046.0050506591797,
1066     "y": 598.6670217514038,
1067     "z": "3545e2b7.8c73ce",
1068     "wires": [
1069       [
1070         "6eb2a758.9628c8"
1071       ]
1072     ]
1073   },
1074   {
1075     "id": "6eb2a758.9628c8",
1076     "type": "outcomeTrue",
1077     "name": "true",
1078     "xml": "<outcome value='true'>\n",
1079     "comments": "",
1080     "outputs": 1,
1081     "x": 3199.0054206848145,
1082     "y": 599.6670989990234,
1083     "z": "3545e2b7.8c73ce",
1084     "wires": [
1085       [
1086         "2a323a58.ea63c6"
1087       ]
1088     ]
1089   },
1090   {
1091     "id": "2a323a58.ea63c6",
1092     "type": "set",
1093     "name": "set prop.wan.deviceId",
1094     "xml": "<set>\n<parameter name='prop.wan.deviceId' value='`$service-data.vnfs.vnf[$vidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$deviceidx].value`' />\n",
1095     "comments": "",
1096     "x": 3368.0060272216797,
1097     "y": 598.2671337127686,
1098     "z": "3545e2b7.8c73ce",
1099     "wires": []
1100   },
1101   {
1102     "id": "48e7d6a0.748938",
1103     "type": "block",
1104     "name": "block : atomic",
1105     "xml": "<block atomic=\"true\">",
1106     "atomic": "true",
1107     "outputs": 1,
1108     "x": 1923.6708374023438,
1109     "y": 249.0000762939453,
1110     "z": "3545e2b7.8c73ce",
1111     "wires": [
1112       [
1113         "c653d564.103fb8"
1114       ]
1115     ]
1116   },
1117   {
1118     "id": "edf1bf9c.83bf3",
1119     "type": "block",
1120     "name": "block : atomic",
1121     "xml": "<block atomic=\"true\">",
1122     "atomic": "true",
1123     "outputs": 1,
1124     "x": 2221.0051345825195,
1125     "y": 463.00025367736816,
1126     "z": "3545e2b7.8c73ce",
1127     "wires": [
1128       [
1129         "8e851a14.33c2e8"
1130       ]
1131     ]
1132   },
1133   {
1134     "id": "15e6beda.ef5931",
1135     "type": "outcomeTrue",
1136     "name": "true",
1137     "xml": "<outcome value='true'>\n",
1138     "comments": "",
1139     "outputs": 1,
1140     "x": 2610.0058403015137,
1141     "y": 466.0003786087036,
1142     "z": "3545e2b7.8c73ce",
1143     "wires": [
1144       [
1145         "8b8e8a8.6844f78"
1146       ]
1147     ]
1148   },
1149   {
1150     "id": "7772ec9b.efcac4",
1151     "type": "block",
1152     "name": "block : atomic",
1153     "xml": "<block atomic=\"true\">",
1154     "atomic": "true",
1155     "outputs": 1,
1156     "x": 1912.3376846313477,
1157     "y": 151.00003242492676,
1158     "z": "3545e2b7.8c73ce",
1159     "wires": [
1160       [
1161         "db3e11bd.eb0ca",
1162         "3f24458e.06f9fa",
1163         "a565af06.127cb",
1164         "9a2c7dc6.4b893"
1165       ]
1166     ]
1167   },
1168   {
1169     "id": "e220c2f5.e3641",
1170     "type": "for",
1171     "name": "for loop wanPortidx - Get wanPortId",
1172     "xml": "<for index=\"wanPortidx\" start=\"0\" end=\"`$wanPortResp_length`\">\n    \n    \n",
1173     "comments": "",
1174     "outputs": 1,
1175     "x": 693.3374061584473,
1176     "y": 1231.0003681182861,
1177     "z": "3545e2b7.8c73ce",
1178     "wires": [
1179       [
1180         "50e167ac.c7e768"
1181       ]
1182     ]
1183   },
1184   {
1185     "id": "50e167ac.c7e768",
1186     "type": "block",
1187     "name": "block",
1188     "xml": "<block>\n",
1189     "atomic": "false",
1190     "comments": "",
1191     "outputs": 1,
1192     "x": 910.3379402160645,
1193     "y": 1232.000452041626,
1194     "z": "3545e2b7.8c73ce",
1195     "wires": [
1196       [
1197         "97aa93ae.f7018"
1198       ]
1199     ]
1200   },
1201   {
1202     "id": "97aa93ae.f7018",
1203     "type": "switchNode",
1204     "name": "switch deviceId same",
1205     "xml": "<switch test=\"`$wanPortResp[$wanPortidx].deviceId == $prop.deviceId`\">\n\n",
1206     "comments": "",
1207     "outputs": 1,
1208     "x": 1084.3385925292969,
1209     "y": 1239.3339138031006,
1210     "z": "3545e2b7.8c73ce",
1211     "wires": [
1212       [
1213         "3a30ba64.e39ed6"
1214       ]
1215     ]
1216   },
1217   {
1218     "id": "3a30ba64.e39ed6",
1219     "type": "outcomeTrue",
1220     "name": "true",
1221     "xml": "<outcome value='true'>\n",
1222     "comments": "",
1223     "outputs": 1,
1224     "x": 1252.3377742767334,
1225     "y": 1228.333701133728,
1226     "z": "3545e2b7.8c73ce",
1227     "wires": [
1228       [
1229         "3ba0cd34.c2b072"
1230       ]
1231     ]
1232   },
1233   {
1234     "id": "3ba0cd34.c2b072",
1235     "type": "set",
1236     "name": "set prop.wan.wanPortId",
1237     "xml": "<set>\n<parameter name='prop.wan.wanPortId' value='`$wanPortResp[$wanPortidx].id`' />\n",
1238     "comments": "",
1239     "x": 1334.3284950256348,
1240     "y": 1278.6572723388672,
1241     "z": "3545e2b7.8c73ce",
1242     "wires": []
1243   },
1244   {
1245     "id": "2847803.c88858",
1246     "type": "for",
1247     "name": "for loop portidx - Get device portId",
1248     "xml": "<for index=\"portidx\" start=\"0\" end=\"`$portResp_length`\">\n    \n    \n",
1249     "comments": "",
1250     "outputs": 1,
1251     "x": 686.0040702819824,
1252     "y": 831.333553314209,
1253     "z": "3545e2b7.8c73ce",
1254     "wires": [
1255       [
1256         "ec540fb0.f5947"
1257       ]
1258     ]
1259   },
1260   {
1261     "id": "ec540fb0.f5947",
1262     "type": "block",
1263     "name": "block",
1264     "xml": "<block>\n",
1265     "atomic": "false",
1266     "comments": "",
1267     "outputs": 1,
1268     "x": 887.0044059753418,
1269     "y": 832.3337163925171,
1270     "z": "3545e2b7.8c73ce",
1271     "wires": [
1272       [
1273         "b9169b7.ff5dd68"
1274       ]
1275     ]
1276   },
1277   {
1278     "id": "b9169b7.ff5dd68",
1279     "type": "switchNode",
1280     "name": "switch deviceId same",
1281     "xml": "<switch test=\"`$portResp[$portidx].deviceId == $prop.deviceId`\">\n\n",
1282     "comments": "",
1283     "outputs": 1,
1284     "x": 1046.0049057006836,
1285     "y": 830.6671323776245,
1286     "z": "3545e2b7.8c73ce",
1287     "wires": [
1288       [
1289         "165db6.9ea6824a"
1290       ]
1291     ]
1292   },
1293   {
1294     "id": "165db6.9ea6824a",
1295     "type": "outcomeTrue",
1296     "name": "true",
1297     "xml": "<outcome value='true'>\n",
1298     "comments": "",
1299     "outputs": 1,
1300     "x": 1219.0042743682861,
1301     "y": 831.6669683456421,
1302     "z": "3545e2b7.8c73ce",
1303     "wires": [
1304       [
1305         "a1161094.a324"
1306       ]
1307     ]
1308   },
1309   {
1310     "id": "a1161094.a324",
1311     "type": "set",
1312     "name": "set prop.wan.devicePortId",
1313     "xml": "<set>\n<parameter name='prop.wan.devicePortId' value='`$portResp[$portidx].id`' />\n",
1314     "comments": "",
1315     "x": 1379.99515914917,
1316     "y": 882.9906177520752,
1317     "z": "3545e2b7.8c73ce",
1318     "wires": []
1319   },
1320   {
1321     "id": "69fec1ed.0fee",
1322     "type": "comment",
1323     "name": "Create port",
1324     "info": "",
1325     "comments": "",
1326     "x": 617.0039558410645,
1327     "y": 747.3335208892822,
1328     "z": "3545e2b7.8c73ce",
1329     "wires": []
1330   },
1331   {
1332     "id": "595aa329.443d7c",
1333     "type": "comment",
1334     "name": "Get network id",
1335     "info": "",
1336     "comments": "",
1337     "x": 613.0039558410645,
1338     "y": 922.3334903717041,
1339     "z": "3545e2b7.8c73ce",
1340     "wires": []
1341   },
1342   {
1343     "id": "a89f747e.6de7f8",
1344     "type": "comment",
1345     "name": "Create wan port",
1346     "info": "",
1347     "comments": "",
1348     "x": 628.0041046142578,
1349     "y": 1069.3336572647095,
1350     "z": "3545e2b7.8c73ce",
1351     "wires": []
1352   },
1353   {
1354     "id": "fdc236b1.efb848",
1355     "type": "failure",
1356     "name": "failure",
1357     "xml": "<outcome value='failure'>\n",
1358     "comments": "",
1359     "outputs": 1,
1360     "x": 997.0040283203125,
1361     "y": 1157.000238418579,
1362     "z": "3545e2b7.8c73ce",
1363     "wires": [
1364       [
1365         "a6e9f6d5.ea4dd8"
1366       ]
1367     ]
1368   },
1369   {
1370     "id": "b0038d4b.581a3",
1371     "type": "success",
1372     "name": "success",
1373     "xml": "<outcome value='success'>\n",
1374     "comments": "",
1375     "outputs": 1,
1376     "x": 997.0040245056152,
1377     "y": 1197.0004034042358,
1378     "z": "3545e2b7.8c73ce",
1379     "wires": [
1380       [
1381         "be9a3635.dfb8c8"
1382       ]
1383     ]
1384   },
1385   {
1386     "id": "be9a3635.dfb8c8",
1387     "type": "block",
1388     "name": "block : atomic",
1389     "xml": "<block atomic=\"true\">",
1390     "atomic": "true",
1391     "comments": "",
1392     "outputs": 1,
1393     "x": 1141.0040397644043,
1394     "y": 1196.0002403259277,
1395     "z": "3545e2b7.8c73ce",
1396     "wires": [
1397       []
1398     ]
1399   },
1400   {
1401     "id": "a6e9f6d5.ea4dd8",
1402     "type": "returnFailure",
1403     "name": "return failure",
1404     "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=\"Error executing Create wan port rest api\" />\n",
1405     "comments": "",
1406     "x": 1139.0043601989746,
1407     "y": 1156.000238418579,
1408     "z": "3545e2b7.8c73ce",
1409     "wires": []
1410   },
1411   {
1412     "id": "dad0aff7.4b6c2",
1413     "type": "failure",
1414     "name": "failure",
1415     "xml": "<outcome value='failure'>\n",
1416     "comments": "",
1417     "outputs": 1,
1418     "x": 1044.0039558410645,
1419     "y": 908.0001773834229,
1420     "z": "3545e2b7.8c73ce",
1421     "wires": [
1422       [
1423         "63d1b7a0.e4fbc8"
1424       ]
1425     ]
1426   },
1427   {
1428     "id": "91b71ecc.ea421",
1429     "type": "success",
1430     "name": "success",
1431     "xml": "<outcome value='success'>\n",
1432     "comments": "",
1433     "outputs": 1,
1434     "x": 1044.0039520263672,
1435     "y": 948.0003423690796,
1436     "z": "3545e2b7.8c73ce",
1437     "wires": [
1438       [
1439         "45c0e517.c6f5ac"
1440       ]
1441     ]
1442   },
1443   {
1444     "id": "45c0e517.c6f5ac",
1445     "type": "block",
1446     "name": "block : atomic",
1447     "xml": "<block atomic=\"true\">",
1448     "atomic": "true",
1449     "comments": "",
1450     "outputs": 1,
1451     "x": 1188.0039672851562,
1452     "y": 947.0001792907715,
1453     "z": "3545e2b7.8c73ce",
1454     "wires": [
1455       []
1456     ]
1457   },
1458   {
1459     "id": "63d1b7a0.e4fbc8",
1460     "type": "returnFailure",
1461     "name": "return failure",
1462     "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=\"Error executing Get transport network info rest api\" />\n",
1463     "comments": "",
1464     "x": 1186.0042877197266,
1465     "y": 907.0001773834229,
1466     "z": "3545e2b7.8c73ce",
1467     "wires": []
1468   },
1469   {
1470     "id": "a565af06.127cb",
1471     "type": "call",
1472     "name": "call sdwan-get-wan-param",
1473     "xml": "<call module='GENERIC-RESOURCE-API' rpc='sdwan-get-wan-param' mode='sync' >\n",
1474     "comments": "",
1475     "outputs": 1,
1476     "x": 2184.670539855957,
1477     "y": 157.000075340271,
1478     "z": "3545e2b7.8c73ce",
1479     "wires": [
1480       []
1481     ]
1482   },
1483   {
1484     "id": "3f24458e.06f9fa",
1485     "type": "set",
1486     "name": "set vnf-request-input.",
1487     "xml": "<set>\n<parameter name='vnf-request-input.' value='`$ctx.vnf-data.vnf-data.vnf-request-input.`' />\n\n",
1488     "comments": "",
1489     "x": 2153.670539855957,
1490     "y": 107.00009250640869,
1491     "z": "3545e2b7.8c73ce",
1492     "wires": []
1493   },
1494   {
1495     "id": "7cd20fc3.2681b",
1496     "type": "comment",
1497     "name": "This is also required for template parameters update",
1498     "info": "",
1499     "comments": "",
1500     "x": 2549.0043029785156,
1501     "y": 203.0000352859497,
1502     "z": "3545e2b7.8c73ce",
1503     "wires": []
1504   },
1505   {
1506     "id": "400dec0b.3df124",
1507     "type": "switchNode",
1508     "name": "switch ActivateSiteInstance",
1509     "xml": "<switch test=\"`$service-data.vnfs.vnf[$vidx].vnf-data.request-information.request-action == 'ActivateSiteInstance'`\">\n    \n    \n\n",
1510     "comments": "",
1511     "outputs": 1,
1512     "x": 1522.0043487548828,
1513     "y": 192.00004863739014,
1514     "z": "3545e2b7.8c73ce",
1515     "wires": [
1516       [
1517         "a948b445.19bab8"
1518       ]
1519     ]
1520   },
1521   {
1522     "id": "a948b445.19bab8",
1523     "type": "outcomeTrue",
1524     "name": "true",
1525     "xml": "<outcome value='true'>\n",
1526     "comments": "",
1527     "outputs": 1,
1528     "x": 1718.0045318603516,
1529     "y": 193.00004863739014,
1530     "z": "3545e2b7.8c73ce",
1531     "wires": [
1532       [
1533         "50e42e52.250bb"
1534       ]
1535     ]
1536   },
1537   {
1538     "id": "50e42e52.250bb",
1539     "type": "set",
1540     "name": "set tmp.siteVidx",
1541     "xml": "<set>\n<parameter name='tmp.siteVidx' value='`$vidx`' />\n<parameter name='ctx.site.' value='`$service-data.vnfs.vnf[$vidx].`' />\n\n",
1542     "comments": "",
1543     "x": 1904.0038299560547,
1544     "y": 190.0000524520874,
1545     "z": "3545e2b7.8c73ce",
1546     "wires": []
1547   },
1548   {
1549     "id": "ae97242b.dc5558",
1550     "type": "switchNode",
1551     "name": "switch tmp.siteVidx",
1552     "xml": "<switch test=\"`$tmp.siteVidx`\">\n\n",
1553     "comments": "",
1554     "outputs": 1,
1555     "x": 1195.6706581115723,
1556     "y": 334.00006914138794,
1557     "z": "3545e2b7.8c73ce",
1558     "wires": [
1559       [
1560         "31115c1a.df8dd4"
1561       ]
1562     ]
1563   },
1564   {
1565     "id": "31115c1a.df8dd4",
1566     "type": "outcome",
1567     "name": "NULL",
1568     "xml": "<outcome value=''>\n",
1569     "comments": "",
1570     "outputs": 1,
1571     "x": 1370.0993690490723,
1572     "y": 334.5715208053589,
1573     "z": "3545e2b7.8c73ce",
1574     "wires": [
1575       [
1576         "efdc94d7.becbf8"
1577       ]
1578     ]
1579   },
1580   {
1581     "id": "efdc94d7.becbf8",
1582     "type": "returnFailure",
1583     "name": "return failure",
1584     "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=\"ActivateSiteInstance not found in service-data\" />\n",
1585     "comments": "",
1586     "x": 1512.5280876159668,
1587     "y": 333.71438360214233,
1588     "z": "3545e2b7.8c73ce",
1589     "wires": []
1590   },
1591   {
1592     "id": "8e851a14.33c2e8",
1593     "type": "switchNode",
1594     "name": "switch deviceName match",
1595     "xml": "<switch test=\"`$prop.wan.deviceName == $service-data.vnfs.vnf[$vidx].vnf-data.vnf-request-input.vnf-input-parameters.param[$didx].value`\">\n\n\n",
1596     "comments": "",
1597     "outputs": 1,
1598     "x": 2426.671859741211,
1599     "y": 464.00031757354736,
1600     "z": "3545e2b7.8c73ce",
1601     "wires": [
1602       [
1603         "15e6beda.ef5931"
1604       ]
1605     ]
1606   },
1607   {
1608     "id": "8b8e8a8.6844f78",
1609     "type": "block",
1610     "name": "block : atomic",
1611     "xml": "<block atomic=\"true\">",
1612     "atomic": "true",
1613     "outputs": 1,
1614     "x": 2509.3377990722656,
1615     "y": 538.0001611709595,
1616     "z": "3545e2b7.8c73ce",
1617     "wires": [
1618       [
1619         "7124d1e8.c1afc",
1620         "c26d092c.4da7c8"
1621       ]
1622     ]
1623   },
1624   {
1625     "id": "7124d1e8.c1afc",
1626     "type": "for",
1627     "name": "for loop deviceidx - Get deviceId from servicedata",
1628     "xml": "<for index=\"deviceidx\" start=\"0\" end=\"`$service-data.vnfs.vnf[$vidx].vnf-data.vnf-request-input.vnf-input-parameters.param_length`\">\n    \n    \n",
1629     "comments": "",
1630     "outputs": 1,
1631     "x": 2789.5349502563477,
1632     "y": 533.0313501358032,
1633     "z": "3545e2b7.8c73ce",
1634     "wires": [
1635       [
1636         "29242480.1ab1ec"
1637       ]
1638     ]
1639   },
1640   {
1641     "id": "29242480.1ab1ec",
1642     "type": "block",
1643     "name": "block : atomic",
1644     "xml": "<block atomic=\"true\">",
1645     "atomic": "true",
1646     "outputs": 1,
1647     "x": 2866.5356826782227,
1648     "y": 597.0314493179321,
1649     "z": "3545e2b7.8c73ce",
1650     "wires": [
1651       [
1652         "f5314270.2417a"
1653       ]
1654     ]
1655   },
1656   {
1657     "id": "9a2c7dc6.4b893",
1658     "type": "record",
1659     "name": "record",
1660     "xml": "<record plugin=\"org.onap.ccsdk.sli.core.sli.recording.FileRecorder\">\n<parameter name=\"file\" value=\"/opt/opendaylight/current/data/log/svclogic.log\"/>\n<parameter name=\"field1\" value=\"__TIMESTAMP__\"/>\n<parameter name=\"field2\" value=\".....\"/>\n<parameter name=\"field3\" value=\"prop.wan.deviceName\"/>\n<parameter name=\"field4\" value='`$prop.wan.deviceName`'/>\n",
1661     "comments": "",
1662     "outputs": 1,
1663     "x": 2112.535285949707,
1664     "y": 205.03126621246338,
1665     "z": "3545e2b7.8c73ce",
1666     "wires": [
1667       []
1668     ]
1669   },
1670   {
1671     "id": "acc92682.3c6fd8",
1672     "type": "for",
1673     "name": "for vidx..service-data.vnfs.vnf_length[]",
1674     "xml": "<for index='vidx' start='0' end='`$service-data.vnfs.vnf_length`' >\n",
1675     "comments": "",
1676     "outputs": 1,
1677     "x": 1238.003978729248,
1678     "y": 228.00001621246338,
1679     "z": "3545e2b7.8c73ce",
1680     "wires": [
1681       [
1682         "570db1f7.cbe77",
1683         "400dec0b.3df124"
1684       ]
1685     ]
1686   },
1687   {
1688     "id": "ca279788.45f118",
1689     "type": "set",
1690     "name": "copy input data to service data",
1691     "xml": "<set>\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-id' value='`$service-data.vnfs.vnf[$tmp.vidx].vnf-id`' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.sdnc-request-header.' value='$vnf-topology-operation-input.sdnc-request-header.' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.request-information.' value='$vnf-topology-operation-input.request-information.' />\n<parameter name='service-data.vnfs.vnf[$tmp.vidx].vnf-data.service-information.' value='$vnf-topology-operation-input.service-information.' />",
1692     "comments": "",
1693     "x": 685.03515625,
1694     "y": 1360.5311269760132,
1695     "z": "3545e2b7.8c73ce",
1696     "wires": []
1697   },
1698   {
1699     "id": "a2ce1e1.66d8de",
1700     "type": "comment",
1701     "name": "TODO: split ip/mask",
1702     "info": "",
1703     "comments": "",
1704     "x": 1059.00390625,
1705     "y": 1043.50390625,
1706     "z": "3545e2b7.8c73ce",
1707     "wires": []
1708   }
1709 ]