e0c246b3bebfe8fafd9c3ec29bcc1dde87765053
[sdnc/oam.git] / platform-logic / generic-resource-api / src / main / json / GENERIC-RESOURCE-API_brg-topology-operation-assign.json
1 [
2   {
3     "id":"e5ee9a68.8f74a8",
4     "type":"dgstart",
5     "name":"DGSTART",
6     "outputs":1,
7     "x":125,
8     "y":52.5,
9     "z":"25bf3deb.2eabd2",
10     "wires":[
11       [
12         "393cc04a.70965"
13       ]
14     ]
15   },
16   {
17     "id":"393cc04a.70965",
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":221.23807907104492,
26     "y":113.45239067077637,
27     "z":"25bf3deb.2eabd2",
28     "wires":[
29       [
30         "8d790a6c.626248"
31       ]
32     ]
33   },
34   {
35     "id":"8d790a6c.626248",
36     "type":"method",
37     "name":"brg-topology-operation-assign",
38     "xml":"<method rpc='brg-topology-operation-assign' mode='sync'>\n",
39     "comments":"",
40     "outputs":1,
41     "x":267.15485763549805,
42     "y":148.69044589996338,
43     "z":"25bf3deb.2eabd2",
44     "wires":[
45       [
46         "709e013b.ec7ed"
47       ]
48     ]
49   },
50   {
51     "id":"709e013b.ec7ed",
52     "type":"block",
53     "name":"block : atomic",
54     "xml":"<block atomic=\"true\">",
55     "atomic":"true",
56     "comments":"",
57     "outputs":1,
58     "x":175.47619247436523,
59     "y":292.0237879753113,
60     "z":"25bf3deb.2eabd2",
61     "wires":[
62       [
63         "5341126d.beb3cc",
64         "18e0684.02efa98",
65         "3d25a078.5fbfa",
66         "4f907ab1.9b90b4",
67         "8f923afe.9146b8"
68       ]
69     ]
70   },
71   {
72     "id":"3cb0dbf.eb62a24",
73     "type":"returnSuccess",
74     "name":"return success",
75     "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",
76     "comments":"",
77     "x":1018.6666564941406,
78     "y":2219.0477046966553,
79     "z":"25bf3deb.2eabd2",
80     "wires":[
81
82     ]
83   },
84   {
85     "id":"b4a4d9bb.64b1c8",
86     "type":"set",
87     "name":"set output to api handler",
88     "xml":"<set>\n<parameter name='allotted-resource-id' value='`$tmp.ar.allotted-resource-id`' />\n<parameter name='tunnelxconn-object-path' value=\"`$tmp.ar.self-link`\"/>\n<parameter name='service-object-path' value=\"`'restconf/config/GENERIC-RESOURCE-API:services/service/'\n + $brg-topology-operation-input.service-information.service-instance-id\n + '/service-data/service-topology/'`\"/>\n \n",
89     "comments":"",
90     "x":1055.7540550231934,
91     "y":2097.932439804077,
92     "z":"25bf3deb.2eabd2",
93     "wires":[
94
95     ]
96   },
97   {
98     "id":"77739892.271138",
99     "type":"set",
100     "name":"set allotted-resource-oper-status",
101     "xml":"<set>\n<parameter name='brg-ar.allotted-resource-data.allotted-resource-oper-status.order-status' value='PendingCreate' />\n<parameter name='brg-ar.allotted-resource-data.allotted-resource-oper-status.last-action' value='`$brg-topology-operation-input.request-information.request-action`' />\n<parameter name='brg-ar.allotted-resource-data.allotted-resource-oper-status.last-rpc-action' value='`$brg-topology-operation-input.sdnc-request-header.svc-action`' />\n<parameter name='brg-ar.allotted-resource-data.allotted-resource-oper-status.last-svc-request-id' value='`$brg-topology-operation-input.sdnc-request-header.svc-request-id`' />\n<parameter name='brg-ar.allotted-resource-data.allotted-resource-oper-status.create-timestamp' value='`$tmp.current-time`' />\n",
102     "comments":"",
103     "x":1127.468376159668,
104     "y":1515.1228160858154,
105     "z":"25bf3deb.2eabd2",
106     "wires":[
107
108     ]
109   },
110   {
111     "id":"18e0684.02efa98",
112     "type":"set",
113     "name":"set tmp.ar.self-link",
114     "xml":"<set>\n<parameter name='tmp.ar.self-link' value=\"`'restconf/config/GENERIC-RESOURCE-API:tunnelxconn-allotted-resources/tunnelxconn-allotted-resource/'\n + $tmp.ar.allotted-resource-id\n + '/allotted-resource-data/tunnelxconn-topology/'` \" />\n\n",
115     "comments":"",
116     "x":605.7380676269531,
117     "y":183.83331298828125,
118     "z":"25bf3deb.2eabd2",
119     "wires":[
120
121     ]
122   },
123   {
124     "id":"5341126d.beb3cc",
125     "type":"set",
126     "name":"set tmp.ar.allotted-resource-id,etc",
127     "xml":"<set>\n<parameter name='tmp.ar.allotted-resource-id' value='`$brg-topology-operation-input.allotted-resource-information.allotted-resource-id`' />\n<parameter name='tmp.ar.parent-service-instance-id' value='`$brg-topology-operation-input.allotted-resource-information.parent-service-instance-id`' />\n\n\n",
128     "comments":"",
129     "x":658.997314453125,
130     "y":146.09259033203125,
131     "z":"25bf3deb.2eabd2",
132     "wires":[
133
134     ]
135   },
136   {
137     "id":"2eb376c7.9249fa",
138     "type":"success",
139     "name":"success",
140     "xml":"<outcome value='success'>\n",
141     "comments":"",
142     "outputs":1,
143     "x":808.8148803710938,
144     "y":331.76727294921875,
145     "z":"25bf3deb.2eabd2",
146     "wires":[
147       [
148         "bfb84d8.6226eb"
149       ]
150     ]
151   },
152   {
153     "id":"98be663.e803998",
154     "type":"execute",
155     "name":"execute RestApiCallNode - PUT AR by id",
156     "xml":"<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n    <parameter name='templateFileName' value=\"`$prop.restapi.templateDir + '/' + $prop.restapi.brg.templatefile`\" />\n    <parameter name='restapiUrl' value='`$prop.controller.url + $tmp.ar-url`' />\n    <parameter name='restapiUser' value='`$prop.controller.user`' />\n    <parameter name='restapiPassword' value='`$prop.controller.pwd`' />\n    <parameter name='format' value='json' />\n    <parameter name='httpMethod' value='PUT' />\n    <parameter name=\"responsePrefix\" value=\"mdsal-ar\" />\n\n",
157     "comments":"",
158     "outputs":1,
159     "x":1148.8626251220703,
160     "y":1739.6008231639862,
161     "z":"25bf3deb.2eabd2",
162     "wires":[
163       [
164         "567616cd.4d0bc8",
165         "34674551.1ef96a",
166         "c49baabf.6ac098"
167       ]
168     ]
169   },
170   {
171     "id":"567616cd.4d0bc8",
172     "type":"not-found",
173     "name":"not-found",
174     "xml":"<outcome value='not-found'>\n",
175     "comments":"",
176     "outputs":1,
177     "x":1417.5040016174316,
178     "y":1790.9322349056602,
179     "z":"25bf3deb.2eabd2",
180     "wires":[
181       [
182         "1afb211c.3db5af"
183       ]
184     ]
185   },
186   {
187     "id":"34674551.1ef96a",
188     "type":"failure",
189     "name":"failure",
190     "xml":"<outcome value='failure'>\n",
191     "comments":"",
192     "outputs":1,
193     "x":1408.504051208496,
194     "y":1759.4322606548667,
195     "z":"25bf3deb.2eabd2",
196     "wires":[
197       [
198         "1afb211c.3db5af"
199       ]
200     ]
201   },
202   {
203     "id":"c49baabf.6ac098",
204     "type":"success",
205     "name":"success",
206     "xml":"<outcome value='success'>\n",
207     "comments":"",
208     "outputs":1,
209     "x":1412.2540893554688,
210     "y":1729.789365530014,
211     "z":"25bf3deb.2eabd2",
212     "wires":[
213       [
214         "24c4fc44.bfefd4"
215       ]
216     ]
217   },
218   {
219     "id":"1afb211c.3db5af",
220     "type":"returnFailure",
221     "name":"return failure",
222     "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 updating md-sal for tunnelxconn-allotted-resource\" />\n",
223     "comments":"",
224     "x":1578.2540893554688,
225     "y":1760.1822844967246,
226     "z":"25bf3deb.2eabd2",
227     "wires":[
228
229     ]
230   },
231   {
232     "id":"b9913138.178af",
233     "type":"set",
234     "name":"set oper-status",
235     "xml":"<set>\n<parameter name='brg-ar.allotted-resource-data.allotted-resource-oper-status.last-action' value='`$brg-ar.allotted-resource-data.allotted-resource-operation-information.request-information.request-action`' />\n<parameter name='brg-ar.allotted-resource-data.allotted-resource-oper-status.last-rpc-action' value='`$brg-ar.allotted-resource-status.rpc-action`' />\n<parameter name='brg-ar.allotted-resource-data.allotted-resource-oper-status.last-svc-request-id' value='`$brg-ar.allotted-resource-data.allotted-resource-operation-information.sdnc-request-header.svc-request-id`' />\n\n",
236     "comments":"",
237     "x":1158.5294189453125,
238     "y":432.55291748046875,
239     "z":"25bf3deb.2eabd2",
240     "wires":[
241
242     ]
243   },
244   {
245     "id":"23613fee.e7e3c",
246     "type":"comment",
247     "name":"Save consumed-allotted-resources to mdsal",
248     "info":"",
249     "comments":"",
250     "x":1226.2434692382812,
251     "y":1114.2196044921875,
252     "z":"25bf3deb.2eabd2",
253     "wires":[
254
255     ]
256   },
257   {
258     "id":"c3ce8536.056418",
259     "type":"comment",
260     "name":"GET tunnelxconn-allotted-resource from mdsal",
261     "info":"",
262     "comments":"",
263     "x":531.8148193359375,
264     "y":302.2672119140625,
265     "z":"25bf3deb.2eabd2",
266     "wires":[
267
268     ]
269   },
270   {
271     "id":"bfb84d8.6226eb",
272     "type":"returnFailure",
273     "name":"return failure - tunnelxconn already exists",
274     "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\" \n    value=\"`'Existing brg-allotted-resource with order status of ' + $mdsal-ar.allotted-resource-data.allotted-resource-oper-status.order-status + '.'`\" />\n",
275     "comments":"",
276     "x":1118.129150390625,
277     "y":328.1243896484375,
278     "z":"25bf3deb.2eabd2",
279     "wires":[
280
281     ]
282   },
283   {
284     "id":"adfbfac.9b9f208",
285     "type":"set",
286     "name":"set brg-ar-identifiers",
287     "xml":"<set>\n<parameter name='brg-ar-identifiers.consuming-service-instance-id' value=\"`$brg-topology-operation-input.service-information.service-instance-id` \" />\n<parameter name='brg-ar-identifiers.parent-service-instance-id' value=\"`$brg-topology-operation-input.allotted-resource-information.parent-service-instance-id` \" />\n<parameter name='brg-ar-identifiers.allotted-resource-type' value=\"`$brg-topology-operation-input.allotted-resource-information.allotted-resource-type` \" />\n<parameter name='brg-ar-identifiers.allotted-resource-id' value=\"`$tmp.ar.allotted-resource-id` \" />\n\n",
288     "comments":"",
289     "x":1168.38623046875,
290     "y":526.1243896484375,
291     "z":"25bf3deb.2eabd2",
292     "wires":[
293
294     ]
295   },
296   {
297     "id":"dfee41c5.0d9b3",
298     "type":"comment",
299     "name":"Set allotted-resource-identifiers",
300     "info":"",
301     "comments":"",
302     "x":1195.338623046875,
303     "y":484.838623046875,
304     "z":"25bf3deb.2eabd2",
305     "wires":[
306
307     ]
308   },
309   {
310     "id":"ea01d74e.35b878",
311     "type":"set",
312     "name":"set identifiers in overall structure",
313     "xml":"<set>\n<parameter name='brg-ar.allotted-resource-data.brg-topology.allotted-resource-identifiers.' \nvalue=\"`$brg-ar-identifiers.`\" />\n\n\n",
314     "comments":"",
315     "x":1185.38623046875,
316     "y":834.410400390625,
317     "z":"25bf3deb.2eabd2",
318     "wires":[
319
320     ]
321   },
322   {
323     "id":"33b72d9b.8a20c2",
324     "type":"set",
325     "name":"set onap model information from input",
326     "xml":"<set>\n<parameter name='tx-ar.allotted-resource-data.brg-topology.onap-model-information.' \nvalue=\"`$brg-topology-operation-input.allotted-resource-information.onap-model-information.`\" />\n\n\n",
327     "comments":"",
328     "x":1213.957763671875,
329     "y":569.4100952148438,
330     "z":"25bf3deb.2eabd2",
331     "wires":[
332
333     ]
334   },
335   {
336     "id":"afbfed3a.08159",
337     "type":"switchNode",
338     "name":"switch model-invariant-uuid is null",
339     "xml":"<switch test='$brg-topology-operation-input.allotted-resource-information.onap-model-information.model-invariant-uuid'>\n",
340     "comments":"",
341     "outputs":1,
342     "x":1193.8148193359375,
343     "y":608.69580078125,
344     "z":"25bf3deb.2eabd2",
345     "wires":[
346       [
347         "40b2b772.23c3f8"
348       ]
349     ]
350   },
351   {
352     "id":"40b2b772.23c3f8",
353     "type":"outcome",
354     "name":"outcome null",
355     "xml":"<outcome value=''>\n",
356     "comments":"",
357     "outputs":1,
358     "x":1421.9576988220215,
359     "y":610.1243271827698,
360     "z":"25bf3deb.2eabd2",
361     "wires":[
362       [
363         "853c921b.506c8"
364       ]
365     ]
366   },
367   {
368     "id":"853c921b.506c8",
369     "type":"set",
370     "name":"set model-invariant-uuid",
371     "xml":"<set>\n<parameter name='brg-ar.allotted-resource-data.brg-topology.onap-model-information.model-invariant-uuid' \nvalue=\"`$ar-model.invariant-uuid`\" />\n\n\n",
372     "comments":"",
373     "x":1623.38627243042,
374     "y":609.5528798103333,
375     "z":"25bf3deb.2eabd2",
376     "wires":[
377
378     ]
379   },
380   {
381     "id":"d3ea34e9.368c88",
382     "type":"switchNode",
383     "name":"switch model-uuid is null",
384     "xml":"<switch test='$brg-topology-operation-input.allotted-resource-information.onap-model-information.model-uuid'>\n",
385     "comments":"",
386     "outputs":1,
387     "x":1166.2434158325195,
388     "y":642.9815106391907,
389     "z":"25bf3deb.2eabd2",
390     "wires":[
391       [
392         "e20ffb32.51cf08"
393       ]
394     ]
395   },
396   {
397     "id":"e20ffb32.51cf08",
398     "type":"outcome",
399     "name":"outcome null",
400     "xml":"<outcome value=''>\n",
401     "comments":"",
402     "outputs":1,
403     "x":1367.6719818115234,
404     "y":643.5529322624207,
405     "z":"25bf3deb.2eabd2",
406     "wires":[
407       [
408         "3277974f.69b6d8"
409       ]
410     ]
411   },
412   {
413     "id":"3277974f.69b6d8",
414     "type":"set",
415     "name":"set model-uuid",
416     "xml":"<set>\n<parameter name='brg-ar.allotted-resource-data.brg-topology.onap-model-information.model-uuid' \nvalue=\"`$ar-model.uuid`\" />\n\n\n",
417     "comments":"",
418     "x":1560.529140472412,
419     "y":643.5528540611267,
420     "z":"25bf3deb.2eabd2",
421     "wires":[
422
423     ]
424   },
425   {
426     "id":"40fda3ea.8add9c",
427     "type":"switchNode",
428     "name":"switch model-version is null",
429     "xml":"<switch test='$brg-topology-operation-input.allotted-resource-information.onap-model-information.model-version'>\n",
430     "comments":"",
431     "outputs":1,
432     "x":1174.8148193359375,
433     "y":675.8386378288269,
434     "z":"25bf3deb.2eabd2",
435     "wires":[
436       [
437         "f1c91438.54f678"
438       ]
439     ]
440   },
441   {
442     "id":"f1c91438.54f678",
443     "type":"outcome",
444     "name":"outcome null",
445     "xml":"<outcome value=''>\n",
446     "comments":"",
447     "outputs":1,
448     "x":1424.8148002624512,
449     "y":675.8386225700378,
450     "z":"25bf3deb.2eabd2",
451     "wires":[
452       [
453         "dd6dede8.36e8b"
454       ]
455     ]
456   },
457   {
458     "id":"dd6dede8.36e8b",
459     "type":"set",
460     "name":"set model-version",
461     "xml":"<set>\n<parameter name='tx-ar.allotted-resource-data.tunnelxconn-topology.onap-model-information.model-version' \nvalue=\"`$ar-model.version`\" />\n\n\n",
462     "comments":"",
463     "x":1617.6719589233398,
464     "y":675.8385443687439,
465     "z":"25bf3deb.2eabd2",
466     "wires":[
467
468     ]
469   },
470   {
471     "id":"c14238e7.7fc528",
472     "type":"switchNode",
473     "name":"switch ar-model.ecomp-generated-naming",
474     "xml":"<switch test='`$ar-model.ecomp-generated-naming`'>\n",
475     "comments":"",
476     "outputs":1,
477     "x":1238.38623046875,
478     "y":778.2672729492188,
479     "z":"25bf3deb.2eabd2",
480     "wires":[
481       [
482         "e1eb2b6.299a9d8",
483         "b14c2617.4ba278"
484       ]
485     ]
486   },
487   {
488     "id":"e1eb2b6.299a9d8",
489     "type":"other",
490     "name":"outcome Y",
491     "xml":"<outcome value='Y'>\n",
492     "comments":"",
493     "outputs":1,
494     "x":1524.3862915039062,
495     "y":777.6958618164062,
496     "z":"25bf3deb.2eabd2",
497     "wires":[
498       [
499         "cb449102.0bfe4"
500       ]
501     ]
502   },
503   {
504     "id":"cb449102.0bfe4",
505     "type":"block",
506     "name":"block : atomic",
507     "xml":"<block atomic=\"true\">\n",
508     "atomic":"true",
509     "comments":"",
510     "outputs":1,
511     "x":1678.1363525390625,
512     "y":780.19580078125,
513     "z":"25bf3deb.2eabd2",
514     "wires":[
515       [
516         "6222201e.ef0d1"
517       ]
518     ]
519   },
520   {
521     "id":"b14c2617.4ba278",
522     "type":"other",
523     "name":"other",
524     "xml":"<outcome value='Other'>\n",
525     "comments":"",
526     "outputs":1,
527     "x":1543.608642578125,
528     "y":866.6958618164062,
529     "z":"25bf3deb.2eabd2",
530     "wires":[
531       [
532         "ba1cec2.367321"
533       ]
534     ]
535   },
536   {
537     "id":"ba1cec2.367321",
538     "type":"returnFailure",
539     "name":"return failure",
540     "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 in allotted-resource-model data.  Ecomp-generated-naming should be true\" />\n\n",
541     "comments":"",
542     "x":1726.608642578125,
543     "y":871.6958618164062,
544     "z":"25bf3deb.2eabd2",
545     "wires":[
546
547     ]
548   },
549   {
550     "id":"6222201e.ef0d1",
551     "type":"switchNode",
552     "name":"switch ar-model.ecomp-generated-naming",
553     "xml":"<switch test='`$ar-model.naming-policy`'>\n",
554     "comments":"",
555     "outputs":1,
556     "x":1814.38623046875,
557     "y":829.267333984375,
558     "z":"25bf3deb.2eabd2",
559     "wires":[
560       [
561         "82b261b0.84ccc",
562         "d8af7c81.cbd5"
563       ]
564     ]
565   },
566   {
567     "id":"82b261b0.84ccc",
568     "type":"other",
569     "name":"outcome oam_network_policy",
570     "xml":"<outcome value='oam_network_policy'>\n",
571     "comments":"",
572     "outputs":1,
573     "x":2189.244140625,
574     "y":832.8453369140625,
575     "z":"25bf3deb.2eabd2",
576     "wires":[
577       [
578         "a16beaa7.a8be68"
579       ]
580     ]
581   },
582   {
583     "id":"d8af7c81.cbd5",
584     "type":"other",
585     "name":"other",
586     "xml":"<outcome value='Other'>\n",
587     "comments":"",
588     "outputs":1,
589     "x":2103.671875,
590     "y":909.6958618164062,
591     "z":"25bf3deb.2eabd2",
592     "wires":[
593       [
594         "a16beaa7.a8be68"
595       ]
596     ]
597   },
598   {
599     "id":"b92b0ebd.ec97e",
600     "type":"set",
601     "name":"set ar_name",
602     "xml":"<set>\n<parameter name='tmp.ar-name' value='$TenantOAMNetworkRole_$LandingNetworkRole_SZ' />\n",
603     "comments":"",
604     "x":2495.100830078125,
605     "y":868.2672729492188,
606     "z":"25bf3deb.2eabd2",
607     "wires":[
608
609     ]
610   },
611   {
612     "id":"ff0ac1c6.8d99",
613     "type":"execute",
614     "name":"execute SliStringUtils - replace TenantOAMNetworkRole",
615     "xml":"<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >\n    <parameter name=\"source\" value=\"`$tmp.ar-name`\"/>\n    <parameter name=\"outputPath\" value=\"tmp.ar-name\"/>\n    <parameter name=\"target\" value=\"$TenantOAMNetworkRole\"/>\n    <parameter name=\"replacement\" value=\"`$tunnelxconn-topology-operation-input.tunnelxconn-request-input.untrusted-network-role`\"/>\n\n",
616     "comments":"",
617     "outputs":1,
618     "x":2639.2437858581543,
619     "y":912.1244196891785,
620     "z":"25bf3deb.2eabd2",
621     "wires":[
622       [
623
624       ]
625     ]
626   },
627   {
628     "id":"11a52a68.e2bc36",
629     "type":"execute",
630     "name":"execute SliStringUtils - replace LandingNetworkRole",
631     "xml":"<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >\n    <parameter name=\"source\" value=\"`$tmp.ar-name`\"/>\n    <parameter name=\"outputPath\" value=\"tmp.ar-name\"/>\n    <parameter name=\"target\" value=\"$LandingNetworkRole\"/>\n    <parameter name=\"replacement\" value=\"`$tunnelxconn-topology-operation-input.tunnelxconn-request-input.trusted-network-role`\"/>\n\n",
632     "comments":"",
633     "outputs":1,
634     "x":2626.243896484375,
635     "y":952.2672729492188,
636     "z":"25bf3deb.2eabd2",
637     "wires":[
638       [
639
640       ]
641     ]
642   },
643   {
644     "id":"a16beaa7.a8be68",
645     "type":"block",
646     "name":"block: atomic",
647     "xml":"<block atomic='true'>\n",
648     "atomic":"false",
649     "comments":"",
650     "outputs":1,
651     "x":2303.5292015075684,
652     "y":907.8387522697449,
653     "z":"25bf3deb.2eabd2",
654     "wires":[
655       [
656         "b92b0ebd.ec97e",
657         "ff0ac1c6.8d99",
658         "11a52a68.e2bc36",
659         "24287aef.ab1756"
660       ]
661     ]
662   },
663   {
664     "id":"24287aef.ab1756",
665     "type":"set",
666     "name":"set identifiers.allotted-resource-name",
667     "xml":"<set>\n<parameter name='brg-ar-identifiers.allotted-resource-name' value='`$tmp.ar-name`' />\n",
668     "comments":"",
669     "x":2584.1005859375,
670     "y":1002.552978515625,
671     "z":"25bf3deb.2eabd2",
672     "wires":[
673
674     ]
675   },
676   {
677     "id":"16a390f2.71716f",
678     "type":"set",
679     "name":"set assignments in overall structure",
680     "xml":"<set>\n<parameter name='brg-ar.allotted-resource-data.brg-topology.brg-assignments.' \nvalue=\"`$brg-ar-assignments.`\" />\n\n\n",
681     "comments":"",
682     "x":1193.8624572753906,
683     "y":1039.1246919631958,
684     "z":"25bf3deb.2eabd2",
685     "wires":[
686
687     ]
688   },
689   {
690     "id":"57bd8950.360d48",
691     "type":"set",
692     "name":"Handle brg-ar-assignments",
693     "xml":"<set>\n<parameter name='brg-ar-assignments.vbrg-wan-ip' value='127.0.0.1'/>\n",
694     "comments":"",
695     "x":1173.529052734375,
696     "y":935.5530395507812,
697     "z":"25bf3deb.2eabd2",
698     "wires":[
699
700     ]
701   },
702   {
703     "id":"ad1d1f47.0fd92",
704     "type":"for",
705     "name":"for cidx..service-data.consumed-allotted-resources.consumed-allotted-resource[]",
706     "xml":"<for index='cidx' start='0' end='`$service-data.consumed-allotted-resources.consumed-allotted-resource_length`' >\n",
707     "comments":"",
708     "outputs":1,
709     "x":2211.8155822753906,
710     "y":1312.5411586761475,
711     "z":"25bf3deb.2eabd2",
712     "wires":[
713       [
714         "9eff53f5.fba2e"
715       ]
716     ]
717   },
718   {
719     "id":"4ca1ffaf.2765",
720     "type":"switchNode",
721     "name":"switch service-data.consumed-allotted-resources_length",
722     "xml":"<switch test='`$service-data.consumed-allotted-resources.consumed-allotted-resource_length`'>\n",
723     "comments":"",
724     "outputs":1,
725     "x":1242.8148193359375,
726     "y":1200.005126953125,
727     "z":"25bf3deb.2eabd2",
728     "wires":[
729       [
730         "44b6b7be.364a78",
731         "d6f3204f.2e124"
732       ]
733     ]
734   },
735   {
736     "id":"44b6b7be.364a78",
737     "type":"other",
738     "name":"outcome Null",
739     "xml":"<outcome value=''>\n",
740     "comments":"",
741     "outputs":1,
742     "x":1618.2077865600586,
743     "y":1204.6124458312988,
744     "z":"25bf3deb.2eabd2",
745     "wires":[
746       [
747         "da9136e5.9a43c8"
748       ]
749     ]
750   },
751   {
752     "id":"d6f3204f.2e124",
753     "type":"other",
754     "name":"other",
755     "xml":"<outcome value='Other'>\n",
756     "comments":"",
757     "outputs":1,
758     "x":1616.9577865600586,
759     "y":1294.6124477386475,
760     "z":"25bf3deb.2eabd2",
761     "wires":[
762       [
763         "e4b52287.ffa4f"
764       ]
765     ]
766   },
767   {
768     "id":"9eff53f5.fba2e",
769     "type":"switchNode",
770     "name":"switch allotted-resource-id",
771     "xml":"<switch test=\"`$service-data.consumed-allotted-resources.consumed-allotted-resource[$cidx].allotted-resource-id == $tmp.ar.allotted-resource-id`\">\n\n",
772     "comments":"",
773     "outputs":1,
774     "x":2646.4106826782227,
775     "y":1314.35085105896,
776     "z":"25bf3deb.2eabd2",
777     "wires":[
778       [
779         "4247aaf2.34bc24"
780       ]
781     ]
782   },
783   {
784     "id":"4247aaf2.34bc24",
785     "type":"outcomeTrue",
786     "name":"true",
787     "xml":"<outcome value='true'>\n",
788     "comments":"",
789     "outputs":1,
790     "x":2853.220375061035,
791     "y":1317.564962387085,
792     "z":"25bf3deb.2eabd2",
793     "wires":[
794       [
795         "4915e942.23f368"
796       ]
797     ]
798   },
799   {
800     "id":"e4b52287.ffa4f",
801     "type":"block",
802     "name":"block : atomic",
803     "xml":"<block atomic=\"true\">",
804     "atomic":"true",
805     "outputs":1,
806     "x":1774.834976196289,
807     "y":1300.9885501861572,
808     "z":"25bf3deb.2eabd2",
809     "wires":[
810       [
811         "ad1d1f47.0fd92",
812         "f259b5a9.563638"
813       ]
814     ]
815   },
816   {
817     "id":"4915e942.23f368",
818     "type":"block",
819     "name":"block : atomic",
820     "xml":"<block atomic=\"true\">",
821     "atomic":"true",
822     "outputs":1,
823     "x":3021.4817276000977,
824     "y":1322.4222631454468,
825     "z":"25bf3deb.2eabd2",
826     "wires":[
827       [
828         "fbb9a58b.3d9f98",
829         "f2f48ed3.1ccda"
830       ]
831     ]
832   },
833   {
834     "id":"da9136e5.9a43c8",
835     "type":"set",
836     "name":"set cidx",
837     "xml":"<set>\n<parameter name='tmp.cidx' value=\"`0`\" />\n<parameter name='service-data.consumed-allotted-resources.consumed-allotted-resource_length' value=\"1\" />\n\n\n",
838     "comments":"",
839     "x":1797.0647735595703,
840     "y":1206.8266830444336,
841     "z":"25bf3deb.2eabd2",
842     "wires":[
843
844     ]
845   },
846   {
847     "id":"fbb9a58b.3d9f98",
848     "type":"set",
849     "name":"set tmp.cidx and ctx.consumed-ar",
850     "xml":"<set>\n<parameter name='tmp.cidx' value='`$cidx`' />\n<parameter name='ctx.consumed-ar.' value='`$service-data.consumed-allotted-resources.consumed-allotted-resource[$cidx].`' />\n<parameter name='tmp.found-cidx' value='true' />",
851     "comments":"",
852     "x":3267.3391876220703,
853     "y":1316.9937419891357,
854     "z":"25bf3deb.2eabd2",
855     "wires":[
856
857     ]
858   },
859   {
860     "id":"44d4d3b9.bceb9c",
861     "type":"set",
862     "name":"set consumed allotted resources",
863     "xml":"<set>\n<parameter name='service-data.consumed-allotted-resources.consumed-allotted-resource[$tmp.cidx].allotted-resource-id' value=\"`$tmp.ar.allotted-resource-id` \" />\n<parameter name='service-data.consumed-allotted-resources.consumed-allotted-resource[$tmp.cidx].allotted-resource-type' value=\"`$brg-topology-operation-input.allotted-resource-information.allotted-resource-type` \" />\n<parameter name='service-data.consumed-allotted-resources.consumed-allotted-resource[$tmp.cidx].allotted-resource-pointer' value=\"`$tmp.ar.self-link` \" />\n<parameter name='service-data.consumed-allotted-resources.consumed-allotted-resource_length' value='`$tmp.cidx + 1`' />\n\n",
864     "comments":"",
865     "x":1153.6720123291016,
866     "y":1365.326681137085,
867     "z":"25bf3deb.2eabd2",
868     "wires":[
869
870     ]
871   },
872   {
873     "id":"24c4fc44.bfefd4",
874     "type":"block",
875     "name":"block",
876     "xml":"<block>\n",
877     "atomic":"false",
878     "comments":"",
879     "outputs":1,
880     "x":1553.910057067871,
881     "y":1725.9815347194672,
882     "z":"25bf3deb.2eabd2",
883     "wires":[
884       [
885         "ee4c753c.c76778"
886       ]
887     ]
888   },
889   {
890     "id":"d6830d95.f9764",
891     "type":"comment",
892     "name":"Add BRG AR to mdsal",
893     "info":"",
894     "comments":"",
895     "x":1078.148208618164,
896     "y":1700.6957080364227,
897     "z":"25bf3deb.2eabd2",
898     "wires":[
899
900     ]
901   },
902   {
903     "id":"85496e20.c7fce",
904     "type":"execute",
905     "name":"execute getTime",
906     "xml":"<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliPluginUtils' method='setTime' >\n    <parameter name=\"outputPath\" value=\"tmp.current-time\" />\n\n",
907     "comments":"",
908     "outputs":1,
909     "x":1094.4814224243164,
910     "y":1439.171986579895,
911     "z":"25bf3deb.2eabd2",
912     "wires":[
913       [
914
915       ]
916     ]
917   },
918   {
919     "id":"5ce074ae.26955c",
920     "type":"other",
921     "name":"other",
922     "xml":"<outcome value='Other'>\n",
923     "comments":"",
924     "outputs":1,
925     "x":814.57666015625,
926     "y":382.9814453125,
927     "z":"25bf3deb.2eabd2",
928     "wires":[
929       [
930         "eac1d1df.4a04c"
931       ]
932     ]
933   },
934   {
935     "id":"eac1d1df.4a04c",
936     "type":"block",
937     "name":"block: atomic",
938     "xml":"<block atomic=\"true\">\n",
939     "atomic":"false",
940     "comments":"",
941     "outputs":1,
942     "x":762.57666015625,
943     "y":878.7908325195312,
944     "z":"25bf3deb.2eabd2",
945     "wires":[
946       [
947         "2e500645.0f8a1a",
948         "adfbfac.9b9f208",
949         "33b72d9b.8a20c2",
950         "afbfed3a.08159",
951         "d3ea34e9.368c88",
952         "40fda3ea.8add9c",
953         "b9913138.178af",
954         "c14238e7.7fc528",
955         "ea01d74e.35b878",
956         "57bd8950.360d48",
957         "16a390f2.71716f",
958         "4ca1ffaf.2765",
959         "44d4d3b9.bceb9c",
960         "85496e20.c7fce",
961         "77739892.271138",
962         "c3886b00.abce88",
963         "98be663.e803998",
964         "b4a4d9bb.64b1c8",
965         "3cb0dbf.eb62a24"
966       ]
967     ]
968   },
969   {
970     "id":"2e500645.0f8a1a",
971     "type":"set",
972     "name":"set id",
973     "xml":"<set>\n<parameter name='brg-ar.allotted-resource-id' value=\"`$tmp.ar.allotted-resource-id` \" />\n<parameter name='brg-ar.allotted-resource-status.action' value=\"`$brg-topology-operation-input.request-information.request-action` \" />\n<parameter name='brg-ar.allotted-resource-status.rpc-name' value=\"brg-topology-operation\" />\n<parameter name='brg-ar.allotted-resource-status.rpc-action' value=\"`$brg-topology-operation-input.sdnc-request-header.svc-action` \" />\n<parameter name='brg-ar.allotted-resource-data.allotted-resource-operation-information.request-information.' value=\"`$brg-topology-operation-input.request-information.` \" />\n<parameter name='brg-ar.allotted-resource-data.allotted-resource-operation-information.sdnc-request-header.' value=\"`$brg-topology-operation-input.sdnc-request-header.` \" />\n<parameter name='brg-ar.allotted-resource-data.allotted-resource-operation-information.service-information.' value=\"`$brg-topology-operation-input.service-information.` \" />\n<parameter name='brg-ar.allotted-resource-data.allotted-resource-operation-information.allotted-resource-information.' value=\"`$brg-topology-operation-input.allotted-resource-information.` \" />\n<parameter name='brg-ar.allotted-resource-data.allotted-resource-operation-information.tunnelxconn-request-input.' value=\"`$brg-topology-operation-input.brg-request-input.` \" />",
974     "comments":"",
975     "x":1133.2434387207031,
976     "y":388.933837890625,
977     "z":"25bf3deb.2eabd2",
978     "wires":[
979
980     ]
981   },
982   {
983     "id":"c3886b00.abce88",
984     "type":"update",
985     "name":"update AAI allotted-resource",
986     "xml":"<update plugin=\"org.onap.ccsdk.sli.adaptors.aai.AAIService\" \n\t\tresource=\"allotted-resource\" \n\t\tkey=\"customer.global-customer-id = $brg-topology-operation-input.service-information.global-customer-id AND\n\t\t\tservice-subscription.service-type = $brg-topology-operation-input.service-information.subscription-service-type AND\n\t\t\tservice-instance.service-instance-id = $brg-topology-operation-input.service-information.service-instance-id AND\n\t\t\tallotted-resource.id = $tmp.ar.allotted-resource-id\"\n        pfx='pfx' local-only='false' force='false'>\n\t<parameter name=\"description\" value=\"`$tunnelxconn-topology-operation-input.allotted-resource-information.allotted-resource-type`\" />\n\t<parameter name=\"selflink\" value=\"`$tmp.ar.self-link`\" />\n\t<parameter name=\"model-invariant-id\" value=\"`$ar-model.invariant-uuid`\" />\n\t<parameter name=\"model-version-id\" value=\"`$ar-model.uuid`\" />\n\t<parameter name=\"operational-status\" value=\"null\" />\n",
987     "comments":"",
988     "outputs":1,
989     "x":1115.0529327392578,
990     "y":1607.0767517089844,
991     "z":"25bf3deb.2eabd2",
992     "wires":[
993       [
994         "7ca7c810.8af8c8",
995         "27b10af8.032016"
996       ]
997     ]
998   },
999   {
1000     "id":"7ca7c810.8af8c8",
1001     "type":"failure",
1002     "name":"failure",
1003     "xml":"<outcome value='failure'>\n",
1004     "comments":"",
1005     "outputs":1,
1006     "x":1370.814842224121,
1007     "y":1590.0292553901672,
1008     "z":"25bf3deb.2eabd2",
1009     "wires":[
1010       [
1011         "2112b130.25219e"
1012       ]
1013     ]
1014   },
1015   {
1016     "id":"2112b130.25219e",
1017     "type":"returnFailure",
1018     "name":"return failure",
1019     "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=\"AAI failed\" />\n",
1020     "comments":"",
1021     "x":1537.338722229004,
1022     "y":1601.6483263969421,
1023     "z":"25bf3deb.2eabd2",
1024     "wires":[
1025
1026     ]
1027   },
1028   {
1029     "id":"27b10af8.032016",
1030     "type":"failure",
1031     "name":"not-found",
1032     "xml":"<outcome value='not-found'>\n",
1033     "comments":"",
1034     "outputs":1,
1035     "x":1377.9101295471191,
1036     "y":1622.7912230491638,
1037     "z":"25bf3deb.2eabd2",
1038     "wires":[
1039       [
1040         "2112b130.25219e"
1041       ]
1042     ]
1043   },
1044   {
1045     "id":"f259b5a9.563638",
1046     "type":"switchNode",
1047     "name":"switch tmp.found-cidx",
1048     "xml":"<switch test='`$tmp.found-cidx`'>\n",
1049     "comments":"",
1050     "outputs":1,
1051     "x":2026.743423461914,
1052     "y":1558.7315921783447,
1053     "z":"25bf3deb.2eabd2",
1054     "wires":[
1055       [
1056         "74a25a57.2f53b4"
1057       ]
1058     ]
1059   },
1060   {
1061     "id":"74a25a57.2f53b4",
1062     "type":"outcomeTrue",
1063     "name":"false",
1064     "xml":"<outcome value='false'>\n",
1065     "comments":"",
1066     "outputs":1,
1067     "x":2216.743377685547,
1068     "y":1558.7315292358398,
1069     "z":"25bf3deb.2eabd2",
1070     "wires":[
1071       [
1072         "c642818d.c82e8"
1073       ]
1074     ]
1075   },
1076   {
1077     "id":"c642818d.c82e8",
1078     "type":"block",
1079     "name":"block : atomic",
1080     "xml":"<block atomic=\"true\">",
1081     "atomic":"true",
1082     "outputs":1,
1083     "x":2382.743377685547,
1084     "y":1558.7315292358398,
1085     "z":"25bf3deb.2eabd2",
1086     "wires":[
1087       [
1088         "94c7e089.4dbec"
1089       ]
1090     ]
1091   },
1092   {
1093     "id":"94c7e089.4dbec",
1094     "type":"set",
1095     "name":"set tmp.cidx ",
1096     "xml":"<set>\n<parameter name='tmp.cidx' value='`$service-data.consumed-allotted-resources.consumed-allotted-resource_length`' />\n",
1097     "comments":"",
1098     "x":2628.600706100464,
1099     "y":1559.3030033111572,
1100     "z":"25bf3deb.2eabd2",
1101     "wires":[
1102
1103     ]
1104   },
1105   {
1106     "id":"ee4c753c.c76778",
1107     "type":"execute",
1108     "name":"execute RestApiCallNode - Update parent provided service AR",
1109     "xml":"<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n    <parameter name='templateFileName' value=\"`$prop.restapi.templateDir + '/' + $prop.restapi.parentsvc.templatefile`\" />\n    <parameter name='restapiUrl' value='`$prop.controller.url + $tmp.parent-ar-url`' />\n    <parameter name='restapiUser' value='`$prop.controller.user`' />\n    <parameter name='restapiPassword' value='`$prop.controller.pwd`' />\n    <parameter name='format' value='json' />\n    <parameter name='httpMethod' value='DELETE' />\n    <parameter name=\"responsePrefix\" value=\"parent\" />\n\n",
1110     "comments":"",
1111     "outputs":1,
1112     "x":1904.9521980285645,
1113     "y":1725.6904199123383,
1114     "z":"25bf3deb.2eabd2",
1115     "wires":[
1116       [
1117         "772b0aab.94a794",
1118         "cb34fc4a.b6aaa",
1119         "18d615d.09d0cea"
1120       ]
1121     ]
1122   },
1123   {
1124     "id":"633a71f3.b98a8",
1125     "type":"comment",
1126     "name":"Rollback parent",
1127     "info":"",
1128     "comments":"",
1129     "x":1748.9521255493164,
1130     "y":1695.3570504188538,
1131     "z":"25bf3deb.2eabd2",
1132     "wires":[
1133
1134     ]
1135   },
1136   {
1137     "id":"772b0aab.94a794",
1138     "type":"not-found",
1139     "name":"not-found",
1140     "xml":"<outcome value='not-found'>\n",
1141     "comments":"",
1142     "outputs":1,
1143     "x":2276.2602462768555,
1144     "y":1786.3553862571716,
1145     "z":"25bf3deb.2eabd2",
1146     "wires":[
1147       [
1148         "17d2c2c8.78357d"
1149       ]
1150     ]
1151   },
1152   {
1153     "id":"cb34fc4a.b6aaa",
1154     "type":"failure",
1155     "name":"failure",
1156     "xml":"<outcome value='failure'>\n",
1157     "comments":"",
1158     "outputs":1,
1159     "x":2267.26029586792,
1160     "y":1754.8554120063782,
1161     "z":"25bf3deb.2eabd2",
1162     "wires":[
1163       [
1164         "17d2c2c8.78357d"
1165       ]
1166     ]
1167   },
1168   {
1169     "id":"18d615d.09d0cea",
1170     "type":"success",
1171     "name":"success",
1172     "xml":"<outcome value='success'>\n",
1173     "comments":"",
1174     "outputs":1,
1175     "x":2271.0103340148926,
1176     "y":1725.2125168815255,
1177     "z":"25bf3deb.2eabd2",
1178     "wires":[
1179       [
1180         "17d2c2c8.78357d"
1181       ]
1182     ]
1183   },
1184   {
1185     "id":"17d2c2c8.78357d",
1186     "type":"block",
1187     "name":"block",
1188     "xml":"<block>\n",
1189     "atomic":"false",
1190     "comments":"",
1191     "outputs":1,
1192     "x":2412.666301727295,
1193     "y":1721.4046860709786,
1194     "z":"25bf3deb.2eabd2",
1195     "wires":[
1196       [
1197
1198       ]
1199     ]
1200   },
1201   {
1202     "id":"9883554f.db10a8",
1203     "type":"comment",
1204     "name":"Generate naming",
1205     "info":"",
1206     "comments":"",
1207     "x":1169.3862762451172,
1208     "y":736.2672252655029,
1209     "z":"25bf3deb.2eabd2",
1210     "wires":[
1211
1212     ]
1213   },
1214   {
1215     "id":"3d25a078.5fbfa",
1216     "type":"get-resource",
1217     "name":"get-resource tunnelxconn-allotted-resource",
1218     "xml":"<get-resource plugin='org.onap.ccsdk.sli.adaptors.resource.mdsal.ConfigResource' resource='GENERIC-RESOURCE-API' key='brg-allotted-resources/brg-allotted-resource/$brg-topology-operation-input.allotted-resource-information.allotted-resource-id/' pfx='mdsal-ar' >\n",
1219     "comments":"",
1220     "outputs":1,
1221     "x":514,
1222     "y":336.5,
1223     "z":"25bf3deb.2eabd2",
1224     "wires":[
1225       [
1226         "2eb376c7.9249fa",
1227         "5ce074ae.26955c"
1228       ]
1229     ]
1230   },
1231   {
1232     "id":"4f907ab1.9b90b4",
1233     "type":"execute",
1234     "name":"execute Properties",
1235     "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",
1236     "comments":"",
1237     "outputs":1,
1238     "x":590,
1239     "y":225.5,
1240     "z":"25bf3deb.2eabd2",
1241     "wires":[
1242       [
1243
1244       ]
1245     ]
1246   },
1247   {
1248     "id":"8f923afe.9146b8",
1249     "type":"execute",
1250     "name":"generate allotted-resource url",
1251     "xml":"<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replace' >\n    <parameter name=\"source\" value=\"`$prop.restapi.brg-allottedresource`\"/>\n    <parameter name=\"outputPath\" value=\"tmp.ar-url\"/>\n    <parameter name=\"target\" value=\"{allotted-resource-id}\"/>\n    <parameter name=\"replacement\" value=\"`$tmp.ar.allotted-resource-id`\"/>\n",
1252     "comments":"",
1253     "outputs":1,
1254     "x":597,
1255     "y":265.5,
1256     "z":"25bf3deb.2eabd2",
1257     "wires":[
1258       [
1259
1260       ]
1261     ]
1262   },
1263   {
1264     "id":"f2f48ed3.1ccda",
1265     "type":"break",
1266     "name":"break",
1267     "xml":"<break>\n",
1268     "comments":"",
1269     "x":3180.243507385254,
1270     "y":1362.2316856384277,
1271     "z":"25bf3deb.2eabd2",
1272     "wires":[
1273
1274     ]
1275   }
1276 ]