...
Expand | ||
---|---|---|
| ||
[{"id":"9c9c3e21b4fc2dd5.d56a66b6bf","type":"commentblock","name":"Validation of required datablock : atomic","infoxml":"<block atomic=\"true\">","commentsatomic":"true","outputs":1,"x":1056.88330078125214,"y":613475.723225048610250000422341486,"z":"815459fdebb27e2e.396512e9568","wires":[["a6bc9deb.538c4","bdfe69fe.c6c47","e88114d7.4c9498","f20c42b1.167ee8"]]},{"id":"1a2b74f1a6bc9deb.a32c9b538c4","type":"dgstartswitchNode","name":"DGSTARTswitch svc-request-id","xml":"<switch test='`$service-topology-operation-input.sdnc-request-header.svc-request-id`'>\n","comments":"","outputs":1,"x":101501.9190543038503204764011928,"y":183381.41365623474124374895095825,"z":"815459fdebb27e2e.396512e9568","wires":[["ad9cae4198ae5dd0.b540d8c3c708"]]},{"id":"ad9cae4198ae5dd0.b540d8c3c708","type":"service-logicoutcome","name":"GENERIC-RESOURCE-API 0.0.1NULL","module":"GENERIC-RESOURCE-API","version":"0.0.1","comments":"","xml":"<service-logic xmlns='http://www.openecomp.org/sdnc/svclogic' xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xsi:schemaLocation='http://www.openecomp.org/sdnc/svclogic ./svclogic.xsd' module='GENERIC-RESOURCE-API' version='0.0.1'>","outputs":1,"x":217.20476531982422,"y":224.6517734527588,"z":"815459fd.39651","wires":[["1aae3c3b.93e23c"]]},{"id":"1aae3c3b.93e23c","type":"method","name":"method generate-unique-name","xml":"<method rpc='generate-unique-name' mode='sync'>\n","comments":"","outputs":1,"x":173.2643585205078,"y":266.3303112302508,"z":"815459fd.39651","wires":[["be84dd11.a69268"]]},{"id":"4c99ddb7.73e334","type":"comment","name":"generate-unique-name","info":"Input arguments:\ngenerate-unique-name-input.index-table-name - name of INDEX table\ngenerate-unique-name-input.index-table-prefix-column - name of prefix column in above table\ngenerate-unique-name-input.name-table-name - name of table holding all generated names\ngenerate-unique-name-input.index-length - non-null digit if index should be fixed length\n\nOutput arguments:\ngenerate-unique-name-output.generated-name - generated name (null if error)\ngenerate-unique-name-output.error-message - error message (non-null if error)\n","comments":"","x":496.26391056605735,"y":131,"z":"815459fd.39651","wires":[]},{"id":"2bb7603f.2a5648","type":"block","name":"block : atomic","xml":"<block atomic=\"true\">","atomic":"true","outputs":1,"x":551.8000030517578,"y":1560.5834183011737,"z":"815459fd.39651","wires":[["d90c8046.641c58","f3b600f1.053738","5b526908.c19e1","31f4c41e.abe88c","31eb5844.7865e8","58d2ce6b.3b9048","41884cf2.29260c","ee4ab844.a42118","ef57f8e2.7c7d7","daa5fca3.255d2","abf49007.ade958"]]},{"id":"d90c8046.641c58","type":"switchNode","name":"switch generate-unique-name-input.index-table-name","xml":"<switch test='`$generate-unique-name-input.index-table-name`'>\n","comments":"","outputs":1,"x":993.4666900634766,"y":659.3333629880633,"z":"815459fd.39651","wires":[["8caf9197.8bb528"]]},{"id":"8caf9197.8bb528","type":"outcome","name":"NULL","xml":"<outcome value=''>","comments":"","outputs":1,"x":1323.466609954834,"y":659.3333524976458,"z":"815459fd.39651","wires":[["ade07c82.bdf0e8"]]},{"id":"ade07c82.bdf0e8","type":"returnFailure","name":"return failure","xml":"<return status='failure'>\n<parameter name='generate-unique-name-output.error-message' value='generate-unique-name-input.index-table-name not supplied' />\n","comments":"","x":1496.7999305725098,"y":659.333343914577,"z":"815459fd.39651","wires":[]},{"id":"f3b600f1.053738","type":"switchNode","name":"switch generate-unique-name-input.index-table-prefix-column","xml":"<switch test='`$generate-unique-name-input.index-table-prefix-column`'>\n","comments":"","outputs":1,"x":1018.4666595458984,"y":702.6666988645281,"z":"815459fd.39651","wires":[["3efc891.3f48576"]]},{"id":"3efc891.3f48576","type":"outcome","name":"NULL","xml":"<outcome value=''>","comments":"","outputs":1,"x":1321.7999229431152,"y":702.6666778836932,"z":"815459fd.39651","wires":[["9684f7fe.7a9ba"]]},{"id":"9684f7fe.7a9ba","type":"returnFailure","name":"return failure","xml":"<return status='failure'>\n<parameter name='generate-unique-name-output.error-message' value='generate-unique-name-input.index-table-prefix-column not supplied' />\n","comments":"","x":1495.1332397460938,"y":703.0000213895526,"z":"815459fd.39651","wires":[]},{"id":"5b526908.c19e1","type":"switchNode","name":"switch generate-unique-name-input.name-table-type","xml":"<switch test='`$generate-unique-name-input.name-table-type`'>\n","comments":"","outputs":1,"x":989.466667175293,"y":747.6666912351336,"z":"815459fd.39651","wires":[["d262123e.4ea1f8"]]},{"id":"d262123e.4ea1f8","type":"outcome","name":"NULL","xml":"<outcome value=''>","comments":"","outputs":1,"x":1321.7998638153076,"y":747.6667007718768,"z":"815459fd.39651","wires":[["f30d92b5.aedcd"]]},{"id":"f30d92b5.aedcd","type":"returnFailure","name":"return failure","xml":"<return status='failure'>\n<parameter name='generate-unique-name-output.error-message' value='generate-unique-name-input.name-table-type not supplied' />\n","comments":"","x":1493.466640472412,"y":748.0000042234149,"z":"815459fd.39651","wires":[]},{"id":"41884cf2.29260c","type":"get-resource","name":"get-resource current name index","xml":"<get-resource plugin='org.openecomp.sdnc.sli.resource.sql.SqlResource' resource='SQL'\n key=\"`$tmp.gun.sql`\" pfx='tmp.gun.prefixdb'>\n\n","comments":"","outputs":1,"x":921.1332702636719,"y":1188.428392818996,"z":"815459fd.39651","wires":[["79c4efc5.45a2e8","302b87aa.f8d91","14f2d9a0.55df8e"]]},{"id":"79c4efc5.45a2e8","type":"failure","name":"failure","xml":"<outcome value='failure'>\n","comments":"","outputs":1,"x":1146.3237380981445,"y":1266.9522995267596,"z":"815459fd.39651","wires":[["b0d87954.ac2c18"]]},{"id":"b0d87954.ac2c18","type":"returnFailure","name":"return failure","xml":"<return status='failure'>\n <parameter name=\"generate-unique-name-output.error-message\" value=\"`'Error reading the ' + $generate-unique-name-input.index-table-name + ' table'`\" />\n","comments":"","x":1308.9428596496582,"y":1268.3810276303973,"z":"815459fd.39651","wires":[]},{"id":"3439b70a.51c228","type":"for","name":"for idx from current index to list-end","xml":"<for index='tmp.gun.idx' start='`$tmp.gun.index-number`' end='`$tmp.gun.list-end`' >\n","comments":"","outputs":1,"x":1073.4666748046875,"y":1591.0000085830688,"z":"815459fd.39651","wires":[["13f86661.e45112"]]},{"id":"31f4c41e.abe88c","type":"block","name":"block","xml":"<block>\n","atomic":"false","comments":"","outputs":1,"x":836.0856704711914,"y":1590.9999737058367,"z":"815459fd.39651","wires":[["3439b70a.51c228","749952fe.f825bc"]]},{"id":"749952fe.f825bc","type":"returnSuccess","name":"CATCH BREAK","xml":"<return status='success'>\n\n","comments":"","x":1024.4190826416016,"y":2166.0001043592183,"z":"815459fd.39651","wires":[]},{"id":"31eb5844.7865e8","type":"switchNode","name":"switch generate-unique-name-input.prefix","xml":"<switch test='`$generate-unique-name-input.prefix`'>\n","comments":"","outputs":1,"x":955.1333084106445,"y":792.6666702542987,"z":"815459fd.39651","wires":[["3ccdcc9d.5093ec"]]},{"id":"3ccdcc9d.5093ec","type":"outcome","name":"NULL","xml":"<outcome value=''>","comments":"","outputs":1,"x":1322.4664974212646,"y":792.6666950498309,"z":"815459fd.39651","wires":[["e5203ace.1332"]]},{"id":"e5203ace.1332","type":"returnFailure","name":"return failure","xml":"<return status='failure'>\n<parameter name='generate-unique-name-output.error-message' value='generate-unique-name-input.prefix not supplied' />\n","comments":"","x":1495.1332740783691,"y":792.999998501369,"z":"815459fd.39651","wires":[]},{"id":"58d2ce6b.3b9048","type":"switchNode","name":"switch generate-unique-name-input.index-length","xml":"<switch test='`$generate-unique-name-input.index-length`'>\n","comments":"","outputs":1,"x":978.4666748046875,"y":927.6666120801654,"z":"815459fd.39651","wires":[["d829997c.7eec1","1f4a169e.20ea29","23c759c7.75726e","b452d05b.906ab8","28d2099f.32a4c6"]]},{"id":"d829997c.7eec1","type":"outcome","name":"NULL","xml":"<outcome value=''>","comments":"","outputs":1,"x":1321.7999877929688,"y":835.999998501369,"z":"815459fd.39651","wires":[["c26b3e39.74464"]]},{"id":"28d2099f.32a4c6","type":"other","name":"other","xml":"<outcome value='Other'>\n","comments":"","outputs":1,"x":1319.1333770751953,"y":1012.6666588102069,"z":"815459fd.39651","wires":[["cd46a64b.182b58"]]},{"id":"1f4a169e.20ea29","type":"outcome","name":"1","xml":"<outcome value='1'>\n","comments":"","outputs":1,"x":1320.1333351135254,"y":881.0000385556903,"z":"815459fd.39651","wires":[["b6096d92.9495b"]]},{"id":"23c759c7.75726e","type":"outcome","name":"2","xml":"<outcome value='2'>\n","comments":"","outputs":1,"x":1320.1333198547363,"y":926.0000290189471,"z":"815459fd.39651","wires":[["31ef97e2.d79f58"]]},{"id":"b452d05b.906ab8","type":"outcome","name":"3","xml":"<outcome value='3'>\n","comments":"","outputs":1,"x":1318.4666557312012,"y":969.3333648954119,"z":"815459fd.39651","wires":[["10d523e0.83151c"]]},{"id":"b6096d92.9495b","type":"set","name":"set list-end = 10","xml":"<set>\n<parameter name='tmp.gun.list-end' value='10' />\n","comments":"","x":1502.8000717163086,"y":881.0000271115985,"z":"815459fd.39651","wires":[]},{"id":"31ef97e2.d79f58","type":"set","name":"set list-end = 100","xml":"<set>\n<parameter name='tmp.gun.list-end' value='100' />\n","comments":"","x":1506.13330078125,"y":926.0000290189471,"z":"815459fd.39651","wires":[]},{"id":"10d523e0.83151c","type":"set","name":"set list-end = 1000","xml":"<set>\n<parameter name='tmp.gun.list-end' value='1000' />\n","comments":"","x":1508.13330078125,"y":969.3333420072283,"z":"815459fd.39651","wires":[]},{"id":"cd46a64b.182b58","type":"returnFailure","name":"return failure","xml":"<return status='failure'>\n<parameter name='generate-unique-name-output.error-message' value='generate-unique-name-input.prefix not supplied' />\n","comments":"","x":1490.13330078125,"y":1012.0000290189471,"z":"815459fd.39651","wires":[]},{"id":"adc50be3.80b89","type":"set","name":"set new index number to 1","xml":"<set>\n<parameter name='tmp.gun.index-number' value='1' />\n","comments":"","x":1481.5620803833008,"y":1211.5716842923846,"z":"815459fd.39651","wires":[]},{"id":"c26b3e39.74464","type":"set","name":"set list-end = 10000 (infinity basically)","xml":"<set>\n<parameter name='tmp.gun.list-end' value='10000' />\n","comments":"","x":1570.7999267578125,"y":836.3333420072283,"z":"815459fd.39651","wires":[]},{"id":"a52ed35f.a619d","type":"switchNode","name":"switch generate-unique-name-input.index-length","xml":"<switch test='`$generate-unique-name-input.index-length`'>\n","comments":"","outputs":1,"x":1635.1332550048828,"y":1517.666647366115,"z":"815459fd.39651","wires":[["82fa14d.9b847e8","b2207f7b.dc1388","df3ec92d.7f2b1","eeade36e.4e62"]]},{"id":"82fa14d.9b847e8","type":"outcome","name":"NULL","xml":"<outcome value=''>","comments":"","outputs":1,"x":1915.1332550048828,"y":1447.6667084012713,"z":"815459fd.39651","wires":[["97c34052.dfceb"]]},{"id":"b2207f7b.dc1388","type":"outcome","name":"1","xml":"<outcome value='1'>\n","comments":"","outputs":1,"x":1913.4666023254395,"y":1492.6667484555926,"z":"815459fd.39651","wires":[["97c34052.dfceb"]]},{"id":"df3ec92d.7f2b1","type":"outcome","name":"2","xml":"<outcome value='2'>\n","comments":"","outputs":1,"x":1913.4666900634766,"y":1546.0000957761492,"z":"815459fd.39651","wires":[["40b75c28.7bace4"]]},{"id":"eeade36e.4e62","type":"outcome","name":"3","xml":"<outcome value='3'>\n","comments":"","outputs":1,"x":1913.466567993164,"y":1642.6668285642352,"z":"815459fd.39651","wires":[["2e943d4c.f74eb2"]]},{"id":"97c34052.dfceb","type":"set","name":"set index-string to idx","xml":"<set>\n<parameter name='tmp.gun.index-string' value='`$tmp.gun.idx`' />\n","comments":"","x":2100.133403778076,"y":1466.0000519071307,"z":"815459fd.39651","wires":[]},{"id":"40b75c28.7bace4","type":"switchNode","name":"switch idx < 10","xml":"<switch test='`$tmp.gun.idx < 10`'>\n","comments":"","outputs":1,"x":2080.1333198547363,"y":1545.9999937329974,"z":"815459fd.39651","wires":[["8304e65a.4b4b4","2ce6a205.cb4ece"]]},{"id":"8304e65a.4b4b4","type":"outcomeTrue","name":"true","xml":"<outcome value='true'>\n","comments":"","outputs":1,"x":2241.7999534606934,"y":1519.3333668027606,"z":"815459fd.39651","wires":[["d99e4d51.ae11d"]]},{"id":"2ce6a205.cb4ece","type":"outcomeFalse","name":"false","xml":"<outcome value='false'>\n","comments":"","outputs":1,"x":2241.7999114990234,"y":1567.6667026792254,"z":"815459fd.39651","wires":[["b2113d97.bcb05"]]},{"id":"d99e4d51.ae11d","type":"set","name":"set index-string to '0' + idx","xml":"<set>\n<parameter name='tmp.gun.index-string' value=\"`'' + '0' + $tmp.gun.idx`\" />\n","comments":"","x":2433.46671295166,"y":1518.6665939603533,"z":"815459fd.39651","wires":[]},{"id":"b2113d97.bcb05","type":"set","name":"set index-string to idx","xml":"<set>\n<parameter name='tmp.gun.index-string' value='`$tmp.gun.idx`' />\n","comments":"","x":2416.799964904785,"y":1567.3333095823016,"z":"815459fd.39651","wires":[]},{"id":"2e943d4c.f74eb2","type":"switchNode","name":"switch idx < 10","xml":"<switch test='`$tmp.gun.idx < 10`'>\n","comments":"","outputs":1,"x":2081.799903869629,"y":1640.999956539699,"z":"815459fd.39651","wires":[["ec7f858.347ae78","9979b662.4c54d"]]},{"id":"ec7f858.347ae78","type":"outcomeTrue","name":"true","xml":"<outcome value='true'>\n","comments":"","outputs":1,"x":2241.7998809814453,"y":1614.3333343778338,"z":"815459fd.39651","wires":[["aea9e66b.e585e8"]]},{"id":"9979b662.4c54d","type":"outcomeFalse","name":"false","xml":"<outcome value='false'>\n","comments":"","outputs":1,"x":2243.466537475586,"y":1689.3332924161639,"z":"815459fd.39651","wires":[["4612898e.25b698"]]},{"id":"aea9e66b.e585e8","type":"set","name":"set index-string to '00' + idx","xml":"<set>\n<parameter name='tmp.gun.index-string' value=\"`'' + '00' + $tmp.gun.idx`\" />\n","comments":"","x":2436.7999725341797,"y":1614.3332252502441,"z":"815459fd.39651","wires":[]},{"id":"4612898e.25b698","type":"switchNode","name":"switch idx < 100","xml":"<switch test='`$tmp.gun.idx < 100`'>\n","comments":"","outputs":1,"x":2399.799919128418,"y":1687.666653088161,"z":"815459fd.39651","wires":[["cb47dfbc.885b68","3880cbe0.99a1b4"]]},{"id":"cb47dfbc.885b68","type":"outcomeTrue","name":"true","xml":"<outcome value='true'>\n","comments":"","outputs":1,"x":2556.7998962402344,"y":1661.0000309262957,"z":"815459fd.39651","wires":[["88ab4486.8cf4c"]]},{"id":"3880cbe0.99a1b4","type":"outcomeFalse","name":"false","xml":"<outcome value='false'>\n","comments":"","outputs":1,"x":2556.7998542785645,"y":1709.3333668027606,"z":"815459fd.39651","wires":[["3cd1d056.0e4eb"]]},{"id":"88ab4486.8cf4c","type":"set","name":"set index-string to '0' + idx","xml":"<set>\n<parameter name='tmp.gun.index-string' value=\"`'' + '0' + $tmp.gun.idx`\" />\n","comments":"","x":2749.466682434082,"y":1660.6666855130877,"z":"815459fd.39651","wires":[]},{"id":"3cd1d056.0e4eb","type":"set","name":"set index-string to idx","xml":"<set>\n<parameter name='tmp.gun.index-string' value='`$tmp.gun.idx`' />\n","comments":"","x":2733.466667175293,"y":1708.9999889646258,"z":"815459fd.39651","wires":[]},{"id":"ede00228.67c58","type":"set","name":"set generated-name to prefix + index-string","xml":"<set>\n<parameter name='tmp.gun.generated-name' value='`$generate-unique-name-input.prefix + $tmp.gun.index-string`' />\n","comments":"","x":1619.1333465576172,"y":1794.3332962308612,"z":"815459fd.39651","wires":[]},{"id":"a20f8849.e271d8","type":"set","name":"increment index number","xml":"<set>\n<parameter name='tmp.gun.index-number' value='`$tmp.gun.prefixdb.index-number + 1`' />\n","comments":"","x":1473.4666748046875,"y":1121.6190225396838,"z":"815459fd.39651","wires":[]},{"id":"a7b80904.72e65","type":"comment","name":"First check from the current index to the max index","info":"","comments":"","x":1036.8000183105469,"y":1529.333377293178,"z":"815459fd.39651","wires":[]},{"id":"1f33f7de.a26d8","type":"comment","name":"check if we've used this name before","info":"","comments":"","x":1615.8478698730469,"y":1878.619441986084,"z":"815459fd.39651","wires":[]},{"id":"f1cdba00.3ba7b","type":"failure","name":"failure","xml":"<outcome value='failure'>\n","comments":"","outputs":1,"x":1723.4666709899902,"y":1956.000224522182,"z":"815459fd.39651","wires":[["c8e5bd88.33f2c"]]},{"id":"e2012ba9.7a3398","type":"set","name":"set generate-unique-name-output.error-message","xml":"<set>\n<parameter name='generate-unique-name-output.error-message' value=\"`'Error reading the GENERIC_RESOURCE_NAME table'`\" />\n","comments":"","x":2169.4189224243164,"y":1929.5715574537005,"z":"815459fd.39651","wires":[]},{"id":"ef751cba.ba39c","type":"returnFailure","name":"BREAK","xml":"<return status='failure'>\n","comments":"","x":2034.657169342041,"y":1974.5716451917376,"z":"815459fd.39651","wires":[]},{"id":"1aaa10fa.b84327","type":"returnFailure","name":"BREAK","xml":"<return status='failure'>\n","comments":"","x":2037.5141906738281,"y":2069.4763359342305,"z":"815459fd.39651","wires":[]},{"id":"7cd6c217.f307b4","type":"comment","name":"found one we can use","info":"","comments":"","x":1855.3716468811035,"y":2000.5242580686297,"z":"815459fd.39651","wires":[]},{"id":"ee4ab844.a42118","type":"switchNode","name":"switch generate-unique-name-output.error-message","xml":"<switch test='`$generate-unique-name-output.error-message`'>\n","comments":"","outputs":1,"x":987.6333618164062,"y":2283.857244900295,"z":"815459fd.39651","wires":[["867fce46.b695c","d0e39f9f.c2b31"]]},{"id":"867fce46.b695c","type":"outcome","name":"NULL","xml":"<outcome value=''>","comments":"","outputs":1,"x":1260.9667701721191,"y":2257.19049685342,"z":"815459fd.39651","wires":[["7571ec9c.5b8d1c"]]},{"id":"7571ec9c.5b8d1c","type":"block","name":"block","xml":"<block>\n","atomic":"false","comments":"","outputs":1,"x":1395.9667701721191,"y":2257.19049685342,"z":"815459fd.39651","wires":[[]]},{"id":"d0e39f9f.c2b31","type":"other","name":"other","xml":"<outcome value='Other'>\n","comments":"","outputs":1,"x":1260.9667358398438,"y":2307.190517834255,"z":"815459fd.39651","wires":[["ae2f9429.00a2d"]]},{"id":"ae2f9429.00a2d","type":"returnFailure","name":"return failure","xml":"<return status='failure'>\n","comments":"","x":1410.9667358398438,"y":2307.190517834255,"z":"815459fd.39651","wires":[]},{"id":"ef57f8e2.7c7d7","type":"switchNode","name":"switch found-flag","xml":"<switch test='`$tmp.gun.found-flag`'>\n","comments":"","outputs":1,"x":859.3476715087891,"y":2566.7143644605367,"z":"815459fd.39651","wires":[["c14ca26.de4e86","a2c0f526.551af8"]]},{"id":"c14ca26.de4e86","type":"outcome","name":"true","xml":"<outcome value='true'>","comments":"","outputs":1,"x":1033.6810111999512,"y":2566.714365414211,"z":"815459fd.39651","wires":[["61435f31.cb022"]]},{"id":"8be111ce.28a5e8","type":"set","name":"set generate-unique-name-output.generated-name","xml":"<set>\n<parameter name='generate-unique-name-output.generated-name' value='`$tmp.gun.generated-name`' />\n","comments":"","x":1504.3476257324219,"y":2411.714651516506,"z":"815459fd.39651","wires":[]},{"id":"94df5fb4.706fb","type":"returnSuccess","name":"return success","xml":"<return status='success'>\n","comments":"","x":1386.3951950073242,"y":2749.0954460416524,"z":"815459fd.39651","wires":[]},{"id":"61435f31.cb022","type":"block","name":"block : atomic","xml":"<block atomic=\"true\">","atomic":"true","outputs":1,"x":1185.347640991211,"y":2566.04777949197,"z":"815459fd.39651","wires":[["8be111ce.28a5e8","78663c74.7673a4","3451e34f.617e34","94df5fb4.706fb","b7b12523.204aa8"]]},{"id":"af0bf984.64fc58","type":"set","name":"set index-exists flag to false","xml":"<set>\n<parameter name='tmp.gun.index-exists' value='false' />\n","comments":"","x":1485.6094665527344,"y":1165.2857441220965,"z":"815459fd.39651","wires":[]},{"id":"f7e17554.31eec","type":"set","name":"set index-exists flag to true","xml":"<set>\n<parameter name='tmp.gun.index-exists' value='true' />\n","comments":"","x":1481.7524795532227,"y":1076.7142965112414,"z":"815459fd.39651","wires":[]},{"id":"b1142e6.2fc40d","type":"block","name":"block","xml":"<block>\n","atomic":"false","comments":"","outputs":1,"x":1288.4667510986328,"y":1098.1429025445666,"z":"815459fd.39651","wires":[["f7e17554.31eec","a20f8849.e271d8"]]},{"id":"78663c74.7673a4","type":"switchNode","name":"switch index-exists","xml":"<switch test='`$tmp.gun.index-exists`'>\n","comments":"","outputs":1,"x":1400.109634399414,"y":2543.8576530729024,"z":"815459fd.39651","wires":[["1fcd6a56.015186","7267f95c.67caf8"]]},{"id":"1fcd6a56.015186","type":"outcomeTrue","name":"true","xml":"<outcome value='true'>\n","comments":"","outputs":1,"x":1578.6809997558594,"y":2519.5719208036153,"z":"815459fd.39651","wires":[["5b9b847.579547c"]]},{"id":"7267f95c.67caf8","type":"outcomeFalse","name":"false","xml":"<outcome value='false'>\n","comments":"","outputs":1,"x":1578.6810150146484,"y":2566.7148460660665,"z":"815459fd.39651","wires":[["7027ae6b.f4b178"]]},{"id":"89c7c8c8.b5d17","type":"save","name":"save (update) name index","xml":"<save plugin='org.openecomp.sdnc.sli.resource.sql.SqlResource' resource='SQL'\n key=\"`$tmp.gun.sql`\" pfx='pfx'>\n","comments":"","outputs":1,"x":1974.3953247070312,"y":2521.0003370557515,"z":"815459fd.39651","wires":[["c4bb1f67.2b8208"]]},{"id":"6b1a2c58.f6463c","type":"save","name":"save (insert) name index","xml":"<save plugin='org.openecomp.sdnc.sli.resource.sql.SqlResource' resource='SQL'\n key=\"`$tmp.gun.sql`\" pfx='pfx'>\n","comments":"","outputs":1,"x":1967.2523040771484,"y":2615.285805157253,"z":"815459fd.39651","wires":[["2efbba48.fa9f46"]]},{"id":"c4bb1f67.2b8208","type":"failure","name":"failure","xml":"<outcome value='failure'>\n","comments":"","outputs":1,"x":2167.25252532959,"y":2521.000356129238,"z":"815459fd.39651","wires":[["de5804d8.43d0a"]]},{"id":"2efbba48.fa9f46","type":"failure","name":"failure","xml":"<outcome value='failure'>\n","comments":"","outputs":1,"x":2164.3950958251953,"y":2613.8573211942403,"z":"815459fd.39651","wires":[["1461e83f.8fcd2"]]},{"id":"3451e34f.617e34","type":"save","name":"save (insert) generated name","xml":"<save plugin='org.openecomp.sdnc.sli.resource.sql.SqlResource' resource='SQL'\n key=\"`$tmp.gun.sql`\" pfx='pfx'>\n","comments":"","outputs":1,"x":1434.538230895996,"y":2702.428627422878,"z":"815459fd.39651","wires":[["38c79c2c.b4756c"]]},{"id":"38c79c2c.b4756c","type":"failure","name":"failure","xml":"<outcome value='failure'>\n","comments":"","outputs":1,"x":1644.5381622314453,"y":2702.428678921291,"z":"815459fd.39651","wires":[["ab33c5a7.dcc0b8"]]},{"id":"ab33c5a7.dcc0b8","type":"returnFailure","name":"return failure","xml":"<return status='failure'>\n <parameter name=\"generate-unique-name-output.error-message\" value=\"Failed insert into GENERIC_RESOURCE_NAME table\" />\n","comments":"","x":1798.8239784240723,"y":2702.4286979947774,"z":"815459fd.39651","wires":[]},{"id":"daa5fca3.255d2","type":"set","name":"set sql statement","xml":"<set>\n<parameter name='tmp.gun.sql' value=\"`'SELECT * from ' + $generate-unique-name-input.index-table-name\n+ ' WHERE ' + $generate-unique-name-input.index-table-prefix-column + ' = '\n+ '$generate-unique-name-input.prefix'`\" />\n","comments":"","x":877.0381546020508,"y":1056.7143959317889,"z":"815459fd.39651","wires":[]},{"id":"13f86661.e45112","type":"block","name":"block : atomic","xml":"<block atomic=\"true\">","atomic":"true","outputs":1,"x":1315.6095352172852,"y":1589.5714878354754,"z":"815459fd.39651","wires":[["a52ed35f.a619d","ede00228.67c58","2f2db390.dd18b4","5e3d7ef1.ce61d"]]},{"id":"c8e5bd88.33f2c","type":"block","name":"block : atomic","xml":"<block atomic=\"true\">","atomic":"true","outputs":1,"x":1875.8476676940918,"y":1955.5241436277117,"z":"815459fd.39651","wires":[["e2012ba9.7a3398","ef751cba.ba39c"]]},{"id":"5b9b847.579547c","type":"block","name":"block : atomic","xml":"<block atomic=\"true\">","atomic":"true","outputs":1,"x":1755.966812133789,"y":2496.714449337551,"z":"815459fd.39651","wires":[["27cff0af.71a1a8","89c7c8c8.b5d17"]]},{"id":"7027ae6b.f4b178","type":"block","name":"block : atomic","xml":"<block atomic=\"true\">","atomic":"true","outputs":1,"x":1753.1096649169922,"y":2592.4287676130025,"z":"815459fd.39651","wires":[["6b1a2c58.f6463c","efa8896f.d07148"]]},{"id":"27cff0af.71a1a8","type":"set","name":"set sql statement","xml":"<set>\n<parameter name='tmp.gun.sql' value=\"`'update ' + $generate-unique-name-input.index-table-name\n+ ' set index_number = ' + $tmp.gun.index-string + ' where '\n+ $generate-unique-name-input.index-table-prefix-column\n+ ' = $generate-unique-name-input.prefix'`\" />\n","comments":"","x":1944.5380935668945,"y":2472.4284209523885,"z":"815459fd.39651","wires":[]},{"id":"efa8896f.d07148","type":"set","name":"set sql statement","xml":"<set>\n<parameter name='tmp.gun.sql' value=\"`'insert into ' + $generate-unique-name-input.index-table-name\n+ '(' + $generate-unique-name-input.index-table-prefix-column + ', index_number) values ('\n+ ' $generate-unique-name-input.prefix , ' + $tmp.gun.index-string + ')'`\" />\n\n","comments":"","x":1943.1096420288086,"y":2566.7142376218526,"z":"815459fd.39651","wires":[]},{"id":"6dccc1ef.da102","type":"not-found","name":"not-found","xml":"<outcome value='not-found'>\n","comments":"","outputs":1,"x":1730.1334075927734,"y":2046.95261996133,"z":"815459fd.39651","wires":[["e3aca01e.dacec"]]},{"id":"c78eb88f.146498","type":"for","name":"for idx from 1 to current index","xml":"<for index='tmp.gun.idx' start='1' end='`$tmp.gun.index-number`' >\n","comments":"","outputs":1,"x":1579.9191818237305,"y":3158.666769436428,"z":"815459fd.39651","wires":[["2219e93c.e8ff8e"]]},{"id":"51214751.d1fbc8","type":"block","name":"block","xml":"<block>\n","atomic":"false","comments":"","outputs":1,"x":1348.2524642944336,"y":3158.666770390102,"z":"815459fd.39651","wires":[["c78eb88f.146498","9ec3e778.91151"]]},{"id":"9ec3e778.91151","type":"returnSuccess","name":"CATCH BREAK","xml":"<return status='success'>\n\n","comments":"","x":1530.8715744018555,"y":3733.666900089809,"z":"815459fd.39651","wires":[]},{"id":"28764d7d.c7ac2a","type":"switchNode","name":"switch generate-unique-name-input.index-length","xml":"<switch test='`$generate-unique-name-input.index-length`'>\n","comments":"","outputs":1,"x":2141.5857467651367,"y":3085.333443096706,"z":"815459fd.39651","wires":[["4cc90e35.6869f8","e1c92d6d.bc2058","c2b50e5a.f02478","a85fdf7a.d2add8"]]},{"id":"4cc90e35.6869f8","type":"outcome","name":"NULL","xml":"<outcome value=''>","comments":"","outputs":1,"x":2421.5857467651367,"y":3015.3335041318624,"z":"815459fd.39651","wires":[["37efe12d.5853c6"]]},{"id":"e1c92d6d.bc2058","type":"outcome","name":"1","xml":"<outcome value='1'>\n","comments":"","outputs":1,"x":2419.9190940856934,"y":3060.3335441861836,"z":"815459fd.39651","wires":[["37efe12d.5853c6"]]},{"id":"c2b50e5a.f02478","type":"outcome","name":"2","xml":"<outcome value='2'>\n","comments":"","outputs":1,"x":2419.9191818237305,"y":3113.6668915067403,"z":"815459fd.39651","wires":[["53bbce6e.e9ae08"]]},{"id":"a85fdf7a.d2add8","type":"outcome","name":"3","xml":"<outcome value='3'>\n","comments":"","outputs":1,"x":2419.919059753418,"y":3210.333624294826,"z":"815459fd.39651","wires":[["708c9f01.058a58"]]},{"id":"37efe12d.5853c6","type":"set","name":"set index-string to idx","xml":"<set>\n<parameter name='tmp.gun.index-string' value='`$tmp.gun.idx`' />\n","comments":"","x":2606.58589553833,"y":3033.6668476377217,"z":"815459fd.39651","wires":[]},{"id":"53bbce6e.e9ae08","type":"switchNode","name":"switch idx < 10","xml":"<switch test='`$tmp.gun.idx < 10`'>\n","comments":"","outputs":1,"x":2586.5858116149902,"y":3113.6667894635884,"z":"815459fd.39651","wires":[["8575fd95.1a2cb8","faa37e9e.cbd588"]]},{"id":"8575fd95.1a2cb8","type":"outcomeTrue","name":"true","xml":"<outcome value='true'>\n","comments":"","outputs":1,"x":2748.2524452209473,"y":3087.0001625333516,"z":"815459fd.39651","wires":[["c9f6db90.ed3bf"]]},{"id":"faa37e9e.cbd588","type":"outcomeFalse","name":"false","xml":"<outcome value='false'>\n","comments":"","outputs":1,"x":2748.2524032592773,"y":3135.3334984098165,"z":"815459fd.39651","wires":[["ffe607ad.1291a"]]},{"id":"c9f6db90.ed3bf","type":"set","name":"set index-string to '0' + idx","xml":"<set>\n<parameter name='tmp.gun.index-string' value=\"`'' + '0' + $tmp.gun.idx`\" />\n","comments":"","x":2939.919204711914,"y":3086.3333896909444,"z":"815459fd.39651","wires":[]},{"id":"ffe607ad.1291a","type":"set","name":"set index-string to idx","xml":"<set>\n<parameter name='tmp.gun.index-string' value='`$tmp.gun.idx`' />\n","comments":"","x":2923.252456665039,"y":3135.0001053128926,"z":"815459fd.39651","wires":[]},{"id":"708c9f01.058a58","type":"switchNode","name":"switch idx < 10","xml":"<switch test='`$tmp.gun.idx < 10`'>\n","comments":"","outputs":1,"x":2588.252395629883,"y":3208.66675227029,"z":"815459fd.39651","wires":[["97d62512.465b4","a56b7f05.7ee6d8"]]},{"id":"97d62512.465b4","type":"outcomeTrue","name":"true","xml":"<outcome value='true'>\n","comments":"","outputs":1,"x":2748.252372741699,"y":3182.000130108425,"z":"815459fd.39651","wires":[["9544c9f9.8b8d88"]]},{"id":"a56b7f05.7ee6d8","type":"outcomeFalse","name":"false","xml":"<outcome value='false'>\n","comments":"","outputs":1,"x":2749.91902923584,"y":3257.000088146755,"z":"815459fd.39651","wires":[["6af6f8d2.5bdff8"]]},{"id":"9544c9f9.8b8d88","type":"set","name":"set index-string to '00' + idx","xml":"<set>\n<parameter name='tmp.gun.index-string' value=\"`'' + '00' + $tmp.gun.idx`\" />\n","comments":"","x":2943.252456665039,"y":3182.0001053128926,"z":"815459fd.39651","wires":[]},{"id":"6af6f8d2.5bdff8","type":"switchNode","name":"switch idx < 100","xml":"<switch test='`$tmp.gun.idx < 100`'>\n","comments":"","outputs":1,"x":2906.252410888672,"y":3255.333448818752,"z":"815459fd.39651","wires":[["d2f6dac3.3067","f1aef370.1dca"]]},{"id":"d2f6dac3.3067","type":"outcomeTrue","name":"true","xml":"<outcome value='true'>\n","comments":"","outputs":1,"x":3063.2523880004883,"y":3228.6668266568868,"z":"815459fd.39651","wires":[["a3f93c09.b94c68"]]},{"id":"f1aef370.1dca","type":"outcomeFalse","name":"false","xml":"<outcome value='false'>\n","comments":"","outputs":1,"x":3063.2523460388184,"y":3277.0001625333516,"z":"815459fd.39651","wires":[["66b5ce47.00de2"]]},{"id":"a3f93c09.b94c68","type":"set","name":"set index-string to '0' + idx","xml":"<set>\n<parameter name='tmp.gun.index-string' value=\"`'' + '0' + $tmp.gun.idx`\" />\n","comments":"","x":3255.919174194336,"y":3228.3334812436788,"z":"815459fd.39651","wires":[]},{"id":"66b5ce47.00de2","type":"set","name":"set index-string to idx","xml":"<set>\n<parameter name='tmp.gun.index-string' value='`$tmp.gun.idx`' />\n","comments":"","x":3239.919158935547,"y":3276.666784695217,"z":"815459fd.39651","wires":[]},{"id":"bdd6fd62.a7a3e8","type":"set","name":"set generated-name to prefix + index-string","xml":"<set>\n<parameter name='tmp.gun.generated-name' value='`$generate-unique-name-input.prefix + $tmp.gun.index-string`' />\n","comments":"","x":2125.585838317871,"y":3362.000091961452,"z":"815459fd.39651","wires":[]},{"id":"34bd9b51.b0f2c4","type":"comment","name":"Wrapping around - now check from 1 to the original index","info":"","comments":"","x":1553.2524948120117,"y":3044.143176487514,"z":"815459fd.39651","wires":[]},{"id":"e4c738b5.09d83","type":"comment","name":"check if we've used this name before","info":"","comments":"","x":2112.3002853393555,"y":3477.000365665981,"z":"815459fd.39651","wires":[]},{"id":"583c6a04.040e64","type":"get-resource","name":"get-resource name","xml":"<get-resource plugin='org.openecomp.sdnc.sli.resource.sql.SqlResource' resource='SQL'\n key=\"`$tmp.gun.sql`\" pfx='tmp.gun.namedb'>\n\n","comments":"","outputs":1,"x":2049.919101715088,"y":3617.7144355773926,"z":"815459fd.39651","wires":[["89bf2160.dfb7b","baf26552.043b48"]]},{"id":"89bf2160.dfb7b","type":"failure","name":"failure","xml":"<outcome value='failure'>\n","comments":"","outputs":1,"x":2228.2524948120117,"y":3572.000272205898,"z":"815459fd.39651","wires":[["fb8fc079.1e77d8"]]},{"id":"2da0ea47.c121be","type":"set","name":"set generate-unique-name-output.error-message","xml":"<set>\n<parameter name='generate-unique-name-output.error-message' value=\"Error reading the GENERIC_RESOURCE_NAME table\" />\n","comments":"","x":2674.204746246338,"y":3545.5716051374166,"z":"815459fd.39651","wires":[]},{"id":"958fa098.04d968","type":"returnFailure","name":"BREAK","xml":"<return status='failure'>\n","comments":"","x":2539.4429931640625,"y":3590.5716928754537,"z":"815459fd.39651","wires":[]},{"id":"a607bdc.33f884","type":"switchNode","name":"switch generate-unique-name-output.error-message","xml":"<switch test='`$generate-unique-name-output.error-message`'>\n","comments":"","outputs":1,"x":1512.3000717163086,"y":3841.5239757810323,"z":"815459fd.39651","wires":[["fb21ca76.e6a0a8","cbee8463.5abd"]]},{"id":"fb21ca76.e6a0a8","type":"outcome","name":"NULL","xml":"<outcome value=''>","comments":"","outputs":1,"x":1785.6334800720215,"y":3814.8572277341573,"z":"815459fd.39651","wires":[["ae2192.db98be7"]]},{"id":"ae2192.db98be7","type":"block","name":"block","xml":"<block>\n","atomic":"false","comments":"","outputs":1,"x":1920.6334800720215,"y":3814.8572277341573,"z":"815459fd.39651","wires":[[]]},{"id":"cbee8463.5abd","type":"other","name":"other","xml":"<outcome value='Other'>\n","comments":"","outputs":1,"x":1785.633445739746,"y":3864.8572487149922,"z":"815459fd.39651","wires":[["7488c39d.2fc9e4"]]},{"id":"7488c39d.2fc9e4","type":"returnFailure","name":"return failure","xml":"<return status='failure'>\n","comments":"","x":1935.633445739746,"y":3864.8572487149922,"z":"815459fd.39651","wires":[]},{"id":"968630d4.e3ba48","type":"switchNode","name":"switch found-flag","xml":"<switch test='`$tmp.gun.found-flag`'>\n","comments":"","outputs":1,"x":1394.0143508911133,"y":4021.0478843961446,"z":"815459fd.39651","wires":[["87fd4f0e.54aa38"]]},{"id":"d7f720b6.d1e378","type":"comment","name":"if db name is null we found an index we can use","info":"","comments":"","x":1560.7286911010742,"y":3970.5716594968526,"z":"815459fd.39651","wires":[]},{"id":"87fd4f0e.54aa38","type":"outcome","name":"true","xml":"<outcome value='true'>","comments":"","outputs":1,"x":1553.347671508789,"y":4021.0478414808003,"z":"815459fd.39651","wires":[["5b0ac020.1d8c"]]},{"id":"3b64abd.46fced4","type":"set","name":"set generate-unique-name-output.generated-name","xml":"<set>\n<parameter name='generate-unique-name-output.generated-name' value='`$tmp.gun.generated-name`' />\n","comments":"","x":2029.0143356323242,"y":3969.381382397243,"z":"815459fd.39651","wires":[]},{"id":"5157d8a.7aec1a8","type":"returnSuccess","name":"return success","xml":"<return status='success'>\n<parameter name='' value='' />\n","comments":"","x":1912.4903869628906,"y":4308.190853527614,"z":"815459fd.39651","wires":[]},{"id":"5b0ac020.1d8c","type":"block","name":"block : atomic","xml":"<block atomic=\"true\">","atomic":"true","outputs":1,"x":1720.0143661499023,"y":4019.3810600553243,"z":"815459fd.39651","wires":[["3b64abd.46fced4","8ca17448.865688","18c7df12.c8f449","5157d8a.7aec1a8","30fee1b0.328f4e"]]},{"id":"8ca17448.865688","type":"switchNode","name":"switch index-exists","xml":"<switch test='`$tmp.gun.index-exists`'>\n","comments":"","outputs":1,"x":1924.7763442993164,"y":4101.52438395364,"z":"815459fd.39651","wires":[["faef6e.b983209","4fa5fc45.9536a4"]]},{"id":"faef6e.b983209","type":"outcomeTrue","name":"true","xml":"<outcome value='true'>\n","comments":"","outputs":1,"x":2103.3477096557617,"y":4077.2386516843526,"z":"815459fd.39651","wires":[["746a09f3.f97ea"]]},{"id":"4fa5fc45.9536a4","type":"outcomeFalse","name":"false","xml":"<outcome value='false'>\n","comments":"","outputs":1,"x":2103.347724914551,"y":4124.381576946804,"z":"815459fd.39651","wires":[["c45a5e4b.d362e"]]},{"id":"f7b6e1cf.1a20f8","type":"save","name":"save (update) name index","xml":"<save plugin='org.openecomp.sdnc.sli.resource.sql.SqlResource' resource='SQL'\n key=\"`$tmp.gun.sql`\" pfx='pfx'>\n","comments":"","outputs":1,"x":2499.0620346069336,"y":4078.667067936489,"z":"815459fd.39651","wires":[["b4fa42a7.4de6f"]]},{"id":"9290ec28.871b68","type":"save","name":"save (insert) name index","xml":"<save plugin='org.openecomp.sdnc.sli.resource.sql.SqlResource' resource='SQL'\n key=\"`$tmp.gun.sql`\" pfx='pfx'>\n","comments":"","outputs":1,"x":2491.919013977051,"y":4172.95253603799,"z":"815459fd.39651","wires":[["d67c7a4a.4b9318"]]},{"id":"b4fa42a7.4de6f","type":"failure","name":"failure","xml":"<outcome value='failure'>\n","comments":"","outputs":1,"x":2691.919235229492,"y":4078.667087009975,"z":"815459fd.39651","wires":[["36b7cb6f.1526e4"]]},{"id":"36b7cb6f.1526e4","type":"returnFailure","name":"return failure","xml":"<return status='failure'>\n <parameter name=\"generate-unique-name-output.error-message\" value=\"`'Failed to update ' + $generate-unique-name-input.index-table-name + ' table'`\" />\n","comments":"","x":2846.205051422119,"y":4078.6671060834615,"z":"815459fd.39651","wires":[]},{"id":"d67c7a4a.4b9318","type":"failure","name":"failure","xml":"<outcome value='failure'>\n","comments":"","outputs":1,"x":2689.0618057250977,"y":4171.524052074978,"z":"815459fd.39651","wires":[["781ae51.5db729c"]]},{"id":"781ae51.5db729c","type":"returnFailure","name":"return failure","xml":"<return status='failure'>\n <parameter name=\"generate-unique-name-output.error-message\" value=\"`'Failed to insert record into ' + $generate-unique-name-input.index-table-name + ' table'`\" />\n","comments":"","x":2843.3476219177246,"y":4171.524071148464,"z":"815459fd.39651","wires":[]},{"id":"18c7df12.c8f449","type":"save","name":"save (insert) generated name","xml":"<save plugin='org.openecomp.sdnc.sli.resource.sql.SqlResource' resource='SQL'\n key=\"`$tmp.gun.sql`\" pfx='pfx'>\n","comments":"","outputs":1,"x":1959.2049407958984,"y":4260.095358303615,"z":"815459fd.39651","wires":[["28aac08f.ba9f6"]]},{"id":"28aac08f.ba9f6","type":"failure","name":"failure","xml":"<outcome value='failure'>\n","comments":"","outputs":1,"x":2169.2048721313477,"y":4260.095409802028,"z":"815459fd.39651","wires":[["84a0c5c3.0e38f"]]},{"id":"84a0c5c3.0e38f","type":"returnFailure","name":"return failure","xml":"<return status='failure'>\n <parameter name=\"generate-unique-name-output.error-message\" value=\"Failed insert into GENERIC_RESOURCE_NAME table\" />\n","comments":"","x":2323.4906883239746,"y":4260.095428875515,"z":"815459fd.39651","wires":[]},{"id":"2219e93c.e8ff8e","type":"block","name":"block : atomic","xml":"<block atomic=\"true\">","atomic":"true","outputs":1,"x":1822.062026977539,"y":3157.2382835660665,"z":"815459fd.39651","wires":[["28764d7d.c7ac2a","bdd6fd62.a7a3e8","583c6a04.040e64","6a15e97a.43887","552d7ff7.e47298"]]},{"id":"fb8fc079.1e77d8","type":"block","name":"block : atomic","xml":"<block atomic=\"true\">","atomic":"true","outputs":1,"x":2380.6334915161133,"y":3571.524191311428,"z":"815459fd.39651","wires":[["2da0ea47.c121be","958fa098.04d968"]]},{"id":"746a09f3.f97ea","type":"block","name":"block : atomic","xml":"<block atomic=\"true\">","atomic":"true","outputs":1,"x":2280.6335220336914,"y":4054.381180218288,"z":"815459fd.39651","wires":[["5a80e34c.340e54","f7b6e1cf.1a20f8"]]},{"id":"c45a5e4b.d362e","type":"block","name":"block : atomic","xml":"<block atomic=\"true\">","atomic":"true","outputs":1,"x":2277.7763748168945,"y":4150.09549849374,"z":"815459fd.39651","wires":[["9290ec28.871b68","bf62ad1c.b880a8"]]},{"id":"5a80e34c.340e54","type":"set","name":"set sql statement","xml":"<set>\n<parameter name='tmp.gun.sql' value=\"`'update ' + $generate-unique-name-input.index-table-name\n+ ' set index_number = ' + $tmp.gun.index-string + ' where '\n+ $generate-unique-name-input.index-table-prefix-column\n+ ' = $generate-unique-name-input.prefix'`\" />\n","comments":"","x":2469.204803466797,"y":4030.095151833126,"z":"815459fd.39651","wires":[]},{"id":"bf62ad1c.b880a8","type":"set","name":"set sql statement","xml":"<set>\n<parameter name='tmp.gun.sql' value=\"`'insert into ' + $generate-unique-name-input.index-table-name\n+ '(' + $generate-unique-name-input.index-table-prefix-column + ', index_number) values ('\n+ ' $generate-unique-name-input.prefix , ' + $tmp.gun.index-string + ')'`\" />\n\n","comments":"","x":2467.776351928711,"y":4124.38096850259,"z":"815459fd.39651","wires":[]},{"id":"baf26552.043b48","type":"not-found","name":"not-found","xml":"<outcome value='not-found'>\n","comments":"","outputs":1,"x":2234.919231414795,"y":3662.952667645046,"z":"815459fd.39651","wires":[["82b7f7fa.6672f8"]]},{"id":"6a15e97a.43887","type":"set","name":"clear namedb.name","xml":"<set>\n<parameter name='tmp.gun.namedb.name' value='' />\n","comments":"","x":2050.633415222168,"y":3412.952600887844,"z":"815459fd.39651","wires":[]},{"id":"7d855b7.633afa4","type":"switchNode","name":"switch generate-unique-name-input.index-length","xml":"<switch test='`$generate-unique-name-input.index-length`'>\n","comments":"","outputs":1,"x":1496.9191436767578,"y":2905.3334411893575,"z":"815459fd.39651","wires":[["ce923cd3.8e2308"]]},{"id":"ce923cd3.8e2308","type":"outcome","name":"NULL","xml":"<outcome value=''>","comments":"","outputs":1,"x":1752.6334762573242,"y":2906.2383503232686,"z":"815459fd.39651","wires":[["8b01f87b.613138"]]},{"id":"8b01f87b.613138","type":"returnFailure","name":"return failure","xml":"<return status='failure'>\n <parameter name=\"generate-unique-name-output.error-message\" value=\"We have exhausted the naming index count\" />\n","comments":"","x":1909.7763595581055,"y":2906.2383503232686,"z":"815459fd.39651","wires":[]},{"id":"9932c6f0.d7be","type":"comment","name":"if we get here when there is no index length, then we have used up all 1000","info":"","comments":"","x":1628.3477401733398,"y":2861.952664784023,"z":"815459fd.39651","wires":[]},{"id":"cbd6ef5a.2c87a","type":"returnFailure","name":"return failure","xml":"<return status='failure'>\n <parameter name=\"generate-unique-name-output.error-message\" value=\"We have exhausted the naming index count\" />\n","comments":"","x":1388.3477592468262,"y":4421.2383350644795,"z":"815459fd.39651","wires":[]},{"id":"abf49007.ade958","type":"set","name":"set found-flag=false","xml":"<set>\n<parameter name='tmp.gun.found-flag' value='false' />\n","comments":"","x":882.7524185180664,"y":1332.4285988126483,"z":"815459fd.39651","wires":[]},{"id":"8c5f82c3.b5999","type":"set","name":"set found-flag=true","xml":"<set>\n<parameter name='tmp.gun.found-flag' value='true' />\n","comments":"","x":2074.4191093444824,"y":2021.2381881986346,"z":"815459fd.39651","wires":[]},{"id":"e3aca01e.dacec","type":"block","name":"block : atomic","xml":"<block atomic=\"true\">","atomic":"true","outputs":1,"x":1881.5619316101074,"y":2047.381132534572,"z":"815459fd.39651","wires":[["8c5f82c3.b5999","1aaa10fa.b84327"]]},{"id":"b800310c.fe9408","type":"returnFailure","name":"BREAK","xml":"<return status='failure'>\n","comments":"","x":2539.776210784912,"y":3684.0953830991475,"z":"815459fd.39651","wires":[]},{"id":"e67dd35f.a1d688","type":"comment","name":"found one we can use","info":"","comments":"","x":2357.6336669921875,"y":3615.143305233547,"z":"815459fd.39651","wires":[]},{"id":"ba42760b.fa2f38","type":"set","name":"set found-flag=true","xml":"<set>\n<parameter name='tmp.gun.found-flag' value='true' />\nxml":"<outcome value=''>","comments":"","outputs":1,"x":2576726.68112945556647619345528738,"y":3635381.8572353635524374933242798,"z":"815459fdebb27e2e.396512e9568","wires":[["bdd5f431.d19f48"]]},{"id":"82b7f7fabdd5f431.6672f8d19f48","type":"blockreturnFailure","name":"block : atomicreturn failure","xml":"<block atomic<return status='failure'>\n\t<parameter name='ack-final' value='Y'/>\n\t<parameter name=\"error-code\" value=\"true500\" />","atomic":"true","outputs":1\n <parameter name=\"error-message\" value=\"sdnc-request-header.svc-request-id is a required input\" />\n","comments":"","x":2383878.82395172119141905005318777,"y":3662381.000179699489343749141693115,"z":"815459fdebb27e2e.396512e9568","wires":[["ba42760b.fa2f38","b800310c.fe9408"]]},{"id":"be84dd11bdfe69fe.a69268c6c47","type":"switchNode","name":"switch generate-unique-name-input.supplied-namesvc-action","xml":"<switch test='`$generate`$service-uniquetopology-nameoperation-input.supplied-name`sdnc-request-header.svc-action`'>\n","comments":"","outputs":1,"x":434489.5380249023437561900329589844,"y":438340.857178143092600892107827326,"z":"815459fdebb27e2e.396512e9568","wires":[["39b07652eaa51b42.28c332","f539c66d.3d3eb8"63f578"]]},{"id":"39b07652eaa51b42.28c33263f578","type":"outcome","name":"NULL","xml":"<outcome value=''>","comments":"","outputs":1,"x":693725.10952377319343333549499512,"y":465338.9999737058367458031885964533,"z":"815459fdebb27e2e.396512e9568","wires":[["2bb7603f2dd86cfd.2a5648f7c07c"]]},{"id":"f539c66d2dd86cfd.3d3eb8f7c07c","type":"otherreturnFailure","name":"otherreturn failure","xml":"<outcome <return status='failure'>\n\t<parameter name='ack-final' value='Other'Y'/>\n\t<parameter name=\"error-code\" value=\"500\" />\n ","comments":" <parameter name=\"error-message\" value=\"sdnc-request-header.svc-action is a required input\" />\n","outputscomments":1"","x":693875.10950088500983333282470703,"y":408338.85714381081725803283963885,"z":"815459fdebb27e2e.396512e9568","wires":[["d59bbe20.5b5f7"]]},{"id":"9f23cd16e88114d7.bec0f4c9498","type":"switchNode","name":"switch generate-unique-name-input.name-table-typerequest-action","xml":"<switch test='`$generate`$service-uniquetopology-nameoperation-input.namerequest-tableinformation.request-type`action`'>\n","comments":"","outputs":1,"x":1162499.395172119140661905670166016,"y":344424.57142489297052946361814227,"z":"815459fdebb27e2e.396512e9568","wires":[["b1fcadbe3da7f637.cf554ad5072"]]},{"id":"b1fcadbe3da7f637.cf554ad5072","type":"outcome","name":"NULL","xml":"<outcome value=''>","comments":"","outputs":1,"x":1495726.728368759155376193019322,"y":344424.571434429713729464708055775,"z":"815459fdebb27e2e.396512e9568","wires":[["a63795d470411b09.9a5d389fd59c"]]},{"id":"a63795d470411b09.9a5d389fd59c","type":"returnFailure","name":"return failure","xml":"<return status='failure'>\n\n<parameter t<parameter name='generate-unique-name-output.error-message' value='generate-unique-name-input.name-table-type not supplied' ack-final' value='Y'/>\n\t<parameter name=\"error-code\" value=\"500\" />\n <parameter name=\"error-message\" value=\"request-information.request-action is a required input\" />\n","comments":"","x":1667878.39514541625981904961722239,"y":344424.90473788125182946451732091,"z":"815459fdebb27e2e.396512e9568","wires":[]},{"id":"d59bbe2037b4a24b.5b5f7f5ad46","type":"blockswitchNode","name":"block : atomicswitch subscription-service-type","xml":"<block atomic=\"true\">","atomic<switch test='`$service-topology-operation-input.service-information.subscription-service-type`'>\n","comments":"true","outputs":1,"x":8471051.3952255249023940594264439,"y":407546.428574017116034375510896955,"z":"815459fdebb27e2e.396512e9568","wires":[["9f23cd16464dac2c.bec0f","49cbe0ea.56f328","476b8014.965948"66c35c"]]},{"id":"476b8014464dac2c.96594866c35c","type":"get-resourceoutcome","name":"get-resource nameNULL","xml":"<get-resource plugin='org.openecomp.sdnc.sli.resource.sql.SqlResource' resource='SQL'\n key=\"`$tmp.gun.sql`\" pfx='tmp.gun.namedb'>\n\n<outcome value=''>","comments":"","outputs":1,"x":10551247.96663665771486548886980327,"y":437546.42858927590514375482286725,"z":"815459fdebb27e2e.396512e9568","wires":[["838c4e0d.2a9e48","ce7abeff.e6bf48","ac45ba28.706708f0b78eed.c3e4a8"]]},{"id":"838c4e0df0b78eed.2a9e48c3e4a8","type":"failurereturnFailure","name":"return failure","xml":"<outcome <return status='failure'>\n\t<parameter name='ack-final' value='failureY'/>\n","comments":"","outputs":1\t<parameter name=\"error-code\" value=\"500\" />\n <parameter name=\"error-message\" value=\"service-information.subscription-service-type is a required input\" />\n","comments":"","x":12381399.58568572998050834394182475,"y":424546.571484974452464375377382551,"z":"815459fdebb27e2e.396512e9568","wires":[["fa29ea47.5c37a8"]]},{"id":"49cbe0eab84f8eb8.56f328a730e8","type":"set","name":"set sql statementswitchNode","xml":"<set>\n<parameter name='tmp.gun.sql' value=\"`'SELECT * from GENERIC_RESOURCE_NAME WHERE type = $generate-unique-name-input.name-table-type'\n+ ' AND name = $generate-unique-name-input.supplied-name'`\" /name":"switch global-customer-id","xml":"<switch test='`$service-topology-operation-input.service-information.global-customer-id`'>\n","comments":"","outputs":1,"x":10491031.53818893432629406476702006,"y":389587.80960696084168661514009748,"z":"815459fdebb27e2e.396512e9568","wires":[["34f0a34a.417b5c"]]},{"id":"ce7abeff34f0a34a.e6bf48417b5c","type":"not-foundoutcome","name":"not-foundNULL","xml":"<outcome value='not-found'>\n","comments":"","outputs":1,"x":12461247.68104171752936548963274272,"y":469587.80959551674988661533083234,"z":"815459fdebb27e2e.396512e9568","wires":[["ca6a32d3d7d58094.655a26c4408"]]},{"id":"fa29ea47d7d58094.5c37a86c4408","type":"returnFailure","name":"return failure","xml":"<return status='failure'>\n\n<parameter t<parameter name='generate-unique-name-output.error-message' value=\"`'Error reading the ' + $generate-unique-name-input.name-table-index + ' table'`ack-final' value='Y'/>\n\t<parameter name=\"error-code\" value=\"500\" />\n <parameter name=\"error-message\" value=\"service-information.global-customer-id is a required input\" />\n\n","comments":"","x":13941399.5381088256836083462306431,"y":424587.142890385219068661514009748,"z":"815459fdebb27e2e.396512e9568","wires":[]},{"id":"ac45ba28aa67a0b.706708540e8e","type":"otherswitchNode","name":"otherswitch model-invariant-uuid","xml":"<outcome value='Other<switch test='`$service-topology-operation-input.service-information.ecomp-model-information.model-invariant-uuid`'>\n","comments":"","outputs":1,"x":12381037.8238105773926654865809849,"y":511629.714289120265452947231020246,"z":"815459fdebb27e2e.396512e9568","wires":[["98eb6ae5dc95a39f.5954a821d758"]]},{"id":"98eb6ae5dc95a39f.5954a821d758","type":"returnFailureoutcome","name":"return failureNULL","xml":"<return status='failure'>\n<parameter name='generate-unique-name-output.error-message' value=\"`'The name ' + $generate-unique-name-input.supplied-name + ' has already been used'`\" />\n\n<outcome value=''>","comments":"","outputs":1,"x":13941247.53804779052736548734392436,"y":511629.14285319192072947498049055,"z":"815459fdebb27e2e.396512e9568","wires":[["edf15c8.258802"]]},{"id":"f7a51204edf15c8.bb90b8258802","type":"commentreturnFailure","name":"Caller supplied name - make sure it's not already used","info":"return failure","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=\"service-information.ecomp-model-information.model-invariant-uuid is a required input\" />\n","comments":"","x":11921399.25238037109380834394182475,"y":297629.999996594020332947478975568,"z":"815459fdebb27e2e.396512e9568","wires":[]},{"id":"ca6a32d34546dafe.655a2824704","type":"blockswitchNode","name":"block : atomicswitch model-uuid","xml":"<block atomic=\"true\">","atomic":"true"xml":"<switch test='`$service-topology-operation-input.service-information.ecomp-model-information.model-uuid`'>\n","comments":"","outputs":1,"x":13951007.9667358398438654964991978,"y":470670.28570216042667233367647443,"z":"815459fdebb27e2e.396512e9568","wires":[["34ca7b1dd4dc57e8.d047b4","d6f052af.381de"0a1be8"]]},{"id":"d6f052afd4dc57e8.381de0a1be8","type":"saveoutcome","name":"save (insert) generated nameNULL","xml":"<save plugin<outcome value='org.openecomp.sdnc.sli.resource.sql.SqlResource' resource='SQL'\n key=\"`$tmp.gun.sql`\" pfx='pfx'>\n","comments":"","outputs":1,"x":16351247.9667358398438654964991978,"y":494670.571438244410967233195986066,"z":"815459fdebb27e2e.396512e9568","wires":[["6e823b791b274014.5cc254f978a8"]]},{"id":"6e823b79.5cc254","type":"failure","name":"failure","xml":"<outcome value='failure'1b274014.f978a8","type":"returnFailure","name":"return failure","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=\"service-information.ecomp-model-information.model-uuid is a required input\" />\n","comments":"","outputs":1,"x":18451399.9666671752930835309709819,"y":494670.57148974282404723317691258,"z":"815459fdebb27e2e.396512e9568","wires":[["de733429.fcb0b"]]},{"id":"de7334293b0664b7.fcb0be26dc4","type":"returnFailureswitchNode","name":"return failureswitch model-name","xml":"<return status='failure'>\n<parameter name=\"generate-unique-name-output.error-message\" value=\"Failed insert into GENERIC_RESOURCE_NAME table\" /<switch test='`$service-topology-operation-input.service-information.ecomp-model-information.model-name`'>\n","comments":"","outputs":1,"x":20001010.252483367925120435442241,"y":494712.571508816310371518474306379,"z":"815459fdebb27e2e.396512e9568","wires":[["2b9746c8.9323b2"]]},{"id":"34ca7b1d2b9746c8.d047b49323b2","type":"setoutcome","name":"set sql statementNULL","xml":"<set>\n<parameter name='tmp.gun.sql' <outcome value=\"`'insert into GENERIC_RESOURCE_NAME values ( '\n+ ' $generate-unique-name-input.name-table-type , $generate-unique-name-input.supplied-name )'`\" />\n\n","comments":"","outputs":1,"x":15951246.9666671752932263608660014,"y":444712.57161562783381518817629133,"z":"815459fdebb27e2e.396512e9568","wires":[["ab7f9811.9eb678"]]},{"id":"b7b12523ab7f9811.204aa89eb678","type":"setreturnFailure","name":"set sql statementreturn failure","xml":"<set>\n<parameter name='tmp.gun.sql' value=\"`'insert into GENERIC_RESOURCE_NAME values ( '\n+ ' $generate-unique-name-input.name-table-type , $tmp.gun.generated-name )'`\" />\n<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=\"service-information.ecomp-model-information.model-name is a required input\" />\n","comments":"","x":13951397.96669006347666549268450053,"y":2655712.99998801095171518798555646,"z":"815459fdebb27e2e.396512e9568","wires":[]},{"id":"552d7ff765141aaf.e47298742774","type":"setcomment","name":"set sql statementValidation of required fields","xml":"<set>\n<parameter name='tmp.gun.sql' value=\"`'SELECT * from GENERIC_RESOURCE_NAME WHERE type = $generate-unique-name-input.name-table-type'\n+ ' AND name = $tmp.gun.generated-name'`\" />\ninfo":"","comments":"","x":2044649.06198883056646190131051198,"y":3528295.38115733010457232036590576,"z":"815459fdebb27e2e.396512e9568","wires":[]},{"id":"30fee1b0f20c42b1.328f4e167ee8","type":"setswitchNode","name":"set sql statementswitch svc-action","xml":"<set>\n<parameter name='tmp.gun.sql' value=\"`'insert into GENERIC_RESOURCE_NAME values ( '\n+ ' $generate-unique-name-input.name-table-type , $tmp.gun.generated-name )'`\" />\n\n<switch test='`$service-topology-operation-input.sdnc-request-header.svc-action`'>\n","comments":"","outputs":1,"x":1919484.776184082031285707310267844,"y":4212628.6666855130886994934082031,"z":"815459fdebb27e2e.396512e9568","wires":[["f4c1d91b.1279c"]]},{"id":"de5804d8f4c1d91b.43d0a1279c","type":"returnFailure","name":"return failure","xml":"<return status='failure'>\n <parameter name=\"generate-unique-name-output.error-message\" value=\"`'Failed to update ' + $generate-unique-name-input.index-table-name + ' table'`\" /outcome","name":"assign","xml":"<outcome value='assign'>\n","comments":"","outputs":1,"x":2318647.8238754272463570731026784,"y":2520628.28570502144986994934082031,"z":"815459fdebb27e2e.396512e9568","wires":[["5e4680a3.739a8"]]},{"id":"1461e83f5e4680a3.8fcd2739a8","type":"returnFailureblock","name":"return failureblock : atomic","xml":"<return status='failure'>\n <parameter name=\"generate-unique-name-output.error-message\" value=\"`'Failed to insert record into ' + $generate-unique-name-input.index-table-name + ' table'`\" />\n","comments":"","x":2315.9664878845215,"y":2613.571485928127,"z":"815459fd.39651","wires":[<block atomic=\"true\">","atomic":"true","outputs":1,"x":802.3570731026784,"y":628.6994934082031,"z":"ebb27e2e.2e9568","wires":[["37b4a24b.f5ad46","b84f8eb8.a730e8","aa67a0b.540e8e","4546dafe.824704","3b0664b7.e26dc4","a3644471.cb6f2"]]},{"id":"a2c0f52619d551f4.551af8a5b54e","type":"outcomeFalsedgstart","name":"falseDGSTART","xml":"<outcome value='false'>\n","comments":"","outputs":1,"x":1031157.918987274177500098092214,"y":2851145.00002711159874136562347412,"z":"815459fdebb27e2e.396512e9568","wires":[["2da320e7ae1dd75d.a153cec6f6"]]},{"id":"2da320e7ae1dd75d.a153cec6f6","type":"blockservice-logic","name":"block : atomic","xml":"<block atomic=\"true\">","atomic":"true""GENERIC-RESOURCE-API 0.0.1","module":"GENERIC-RESOURCE-API","version":"0.0.1","comments":"","xml":"<service-logic xmlns='http://www.openecomp.org/sdnc/svclogic' xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xsi:schemaLocation='http://www.openecomp.org/sdnc/svclogic ./svclogic.xsd' module='GENERIC-RESOURCE-API' version='0.0.1'>","outputs":1,"x":1182233.752395629882803571537562766,"y":3462185.66655104500936517677307129,"z":"815459fdebb27e2e.396512e9568","wires":[["7d855b797704d54.633afa4","51214751.d1fbc8","a607bdc.33f884","968630d4.e3ba48","cbd6ef5a.2c87a"309ea"]]},{"id":"14f2d9a097704d54.55df8e309ea","type":"successmethod","name":"successmethod validate-service-input","xml":"<outcome value<method rpc='validate-service-input' mode='successsync'>\n","comments":"","outputs":1,"x":1149222.39530563354542863682338157,"y":1097226.428568295070166365242004395,"z":"815459fdebb27e2e.396512e9568","wires":[["b1142e6b4fc2dd5.2fc40d6b6bf"]]},{"id":"302b87aa58515ef1.f8d91d0a0d","type":"not-foundcomment","name":"not-found","xml":"<outcome value='not-found'>\nvalidate-service-input","commentsinfo":"","outputscomments":1"","x":1155552.96677017211910948660714284,"y":1186.571442059108293,"z":"815459fdebb27e2e.396512e9568","wires":[["ca8d8f3c.52dd98"]]},{"id":"ca8d8f3ca3644471.52dd98cb6f2","type":"blockswitchNode","name":"blockswitch service-id","xml":"<block><switch test='`$service-topology-operation-input.service-information.service-id`'>\n","atomic":"false","comments":"","outputs":1,"x":12871003.3953208923346428473336355,"y":1186505.0000480924334928599357605,"z":"815459fdebb27e2e.396512e9568","wires":[["af0bf984e428bc22.64fc58","adc50be3.80b89"cdee3"]]},{"id":"5e3d7ef1e428bc22.ce61dcdee3","type":"setoutcome","name":"set sql statementNULL","xml":"<set>\n<parameter name='tmp.gun.sql' value=\"`'SELECT * from GENERIC_RESOURCE_NAME WHERE type = $generate-unique-name-input.name-table-type'\n+ ' AND name = $tmp.gun.generated-name'`\" />\n<outcome value=''>","comments":"","outputs":1,"x":15391244.74050521850590714285714284,"y":1919505.57145118713389285955429077,"z":"815459fdebb27e2e.396512e9568","wires":[["981c2b36.9827b"]]},{"id":"2f2db390981c2b36.dd18b49827b","type":"get-resourcereturnFailure","name":"get-resource namereturn failure","xml":"<get-resource plugin='org.openecomp.sdnc.sli.resource.sql.SqlResource' resource='SQL'\n key=\"`$tmp.gun.sql`\" pfx='tmp.gun.namedb'>\n\<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=\"service-information.service-id is a required input\" />\n","comments":"","outputs":1,"x":15411395.16911315917974999945504323,"y":2006505.71437454223639285936355591,"z":"815459fdebb27e2e.396512e9568","wires":[["f1cdba00.3ba7b","6dccc1ef.da102"]]}] |
Expand | ||
---|---|---|
| ||
[{"id":"78d12d0e.b112f4","type":"dgstart","name":"DGSTART","outputs":1,"x":174,"y":138.4136562347412,"z":"573bd44.832f22c","wires":[["d3f20878.e78588"]]},{"id":"d3f20878.e78588","type":"service-logic","name":"GENERIC-RESOURCE-API 0.0.1","module":"GENERIC-RESOURCE-API","version":"0.0.1","comments":"","xml":"<service-logic xmlns='http://www.openecomp.org/sdnc/svclogic' xmlns:xsi='http://www.w3.org/2001/XMLSchema-instance' xsi:schemaLocation='http://www.openecomp.org/sdnc/svclogic ./svclogic.xsd' module='GENERIC-RESOURCE-API' version='0.0.1'>","outputs":1,"x":249.28570556640625,"y":178.6517677307129,"z":"573bd44.832f22c","wires":[["dd896e2b.6b1c88"]]},{"id":"dd896e2b.6b1c88","type":"method","name":"method service-topology-operation-assign","xml":"<method rpc='service-topology-operation-assign' mode='sync'>\n","comments":"","outputs":1,"x":278.42862701416016,"y":218.4136562347412,"z":"573bd44.832f22c","wires":[["b53bfbb0.f9d8a8"]]},{"id":"8c7dd591.f5413","type":"comment","name":"service-topology-operation-assign","info":"","comments":"","x":568.344856262207,"y":86,"z":"573bd44.832f22c","wires":[]},{"id":"b53bfbb0.f9d8a8","type":"block","name":"block : atomic","xml":"<block atomic=\"true\">","atomic":"true","outputs":1,"x":290.8571243286133,"y":809.1756019592285,"z":"573bd44.832f22c","wires":[["eed4a4bb.4ff4c8","b5a07cf7.622aa8","7ddf70bc.04d968","19cb8a62.21245e","ff8f09db.fa31a8","d9bc037.5a8a28","808a05d8.77b83","1a5d5129.f380cf","8e1f0de6.26b1e"]]},{"id":"eed4a4bb.4ff4c8","type":"switchNode","name":"switch request-action","xml":"<switch test='`$service-topology-operation-input.request-information.request-action`'>\n","comments":"","outputs":1,"x":573.2381134033203,"y":320.127947807312,"z":"573bd44.832f22c","wires":[["160c429.fdbff3d","b16ff0b4.57f5"]]},{"id":"160c429.fdbff3d","type":"outcome","name":"CreateServiceInstance","xml":"<outcome value='CreateServiceInstance'>\n","comments":"","outputs":1,"x":810.3809280395508,"y":294.4136562347412,"z":"573bd44.832f22c","wires":[["bc5512a3.62569"]]},{"id":"b16ff0b4.57f5","type":"other","name":"other","xml":"<outcome value='Other'>\n","comments":"","outputs":1,"x":760.3809509277344,"y":338.46129512786865,"z":"573bd44.832f22c","wires":[["351b9443.f5869c"]]},{"id":"bc5512a3.62569","type":"block","name":"block","xml":"<block>\n","atomic":"false","comments":"","outputs":1,"x":988.9523849487305,"y":294.4136915206909,"z":"573bd44.832f22c","wires":[[]]},{"id":"351b9443.f5869c","type":"returnFailure","name":"return failure","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=\"If svc-action is 'assign' then request-action must be 'CreateServiceInstance'\" />\n","comments":"","x":967.7618980407715,"y":338.46130657196045,"z":"573bd44.832f22c","wires":[]},{"id":"a9478035.5f0fb","type":"get-resource","name":"get-resource SERVICE_MODEL","xml":"<get-resource plugin='org.openecomp.sdnc.sli.resource.sql.SqlResource' resource='SQL'\n key='SELECT * from SERVICE_MODEL WHERE service_uuid = $service-topology-operation-input.service-information.ecomp-model-information.model-uuid'\n pfx='db.service-model'>\n\n","comments":"","outputs":1,"x":609.7856292724609,"y":543.2232360839844,"z":"573bd44.832f22c","wires":[["ebfe18e9.9d4ed","a218a76b.7acc68"]]},{"id":"558753d6.22bd54","type":"returnFailure","name":"return failure","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=\"`'No model found for service UUID ' + $service-topology-operation-input.service-information.ecomp-model-information.model-uuid`\" />\n","comments":"","x":1024.0712966918945,"y":568.080286026001,"z":"573bd44.832f22c","wires":[]},{"id":"b5a07cf7.622aa8","type":"switchNode","name":"switch input service-instance-name","xml":"<switch test='`$service-topology-operation-input.service-request-input.service-instance-name`'>\n","comments":"","outputs":1,"x":617.1903610229492,"y":839.5326652526855,"z":"573bd44.832f22c","wires":[["fa26bb1c.fab59","6a2acb8b.f308d4"]]},{"id":"fa26bb1c.fab59","type":"outcome","name":"NULL","xml":"<outcome value=''>","comments":"","outputs":1,"x":838.3569221496582,"y":764.8898096084595,"z":"573bd44.832f22c","wires":[["a1460fd3.88252"]]},{"id":"ca1b790f.25d6f8","type":"switchNode","name":"switch ecomp-naming","xml":"<switch test='`$db.service-model.ecomp-naming`'>\n","comments":"","outputs":1,"x":1217.6429824829102,"y":657.2708940505981,"z":"573bd44.832f22c","wires":[["6683f762.e027b","50f6496a.ffe23","40fd15fa.84da4c"]]},{"id":"a1460fd3.88252","type":"block","name":"block : atomic","xml":"<block atomic=\"true\">","atomic":"true","outputs":1,"x":984.0714225769043,"y":764.8899269104004,"z":"573bd44.832f22c","wires":[["9c81a56.0cea0d8","23c933b.2cfc14c","ca1b790f.25d6f8"]]},{"id":"50f6496a.ffe23","type":"outcome","name":"N","xml":"<outcome value='N'>","comments":"","outputs":1,"x":1466.9286422729492,"y":659.1756029129028,"z":"573bd44.832f22c","wires":[["89106143.b1a078"]]},{"id":"89106143.b1a078","type":"returnFailure","name":"return failure","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=\"No service-instance-name was received but ecomp-naming is not Y\" />\n","comments":"","x":1621.214427947998,"y":677.7470474243164,"z":"573bd44.832f22c","wires":[]},{"id":"6683f762.e027b","type":"outcome","name":"Y","xml":"<outcome value='Y'>","comments":"","outputs":1,"x":1466.9286079406738,"y":614.8899240493774,"z":"573bd44.832f22c","wires":[["a82712a1.8243d8"]]},{"id":"40fd15fa.84da4c","type":"other","name":"other","xml":"<outcome value='Other'>\n","comments":"","outputs":1,"x":1466.9285697937012,"y":704.8899221420288,"z":"573bd44.832f22c","wires":[["89106143.b1a078"]]},{"id":"a82712a1.8243d8","type":"block","name":"block","xml":"<block>\n","atomic":"false","comments":"","outputs":1,"x":1604.0715522766113,"y":614.8899240493774,"z":"573bd44.832f22c","wires":[[]]},{"id":"6a2acb8b.f308d4","type":"other","name":"other","xml":"<outcome value='Other'>\n","comments":"","outputs":1,"x":840.9286041259766,"y":911.1755485534668,"z":"573bd44.832f22c","wires":[["3bcfb2c8.11039e"]]},{"id":"3b698a92.087b7e","type":"set","name":"set tmp.service-instance-name","xml":"<set>\n<parameter name='tmp.service-instance-name' value=\"`$service-topology-operation-input.service-request-input.service-instance-name`\" />\n","comments":"","x":1882.6428756713867,"y":958.6041946411133,"z":"573bd44.832f22c","wires":[]},{"id":"19cb8a62.21245e","type":"update","name":"update AAI service instance","xml":"<update plugin=\"org.openecomp.sdnc.sli.aai.AAIService\" \n\t\tresource=\"service-instance\" \n\t\tkey=\"customer.global-customer-id = $service-topology-operation-input.service-information.global-customer-id AND\n\t\t\tservice-subscription.service-type = $service-topology-operation-input.service-information.subscription-service-type AND\n\t\t\tservice-instance.service-instance-id = $service-topology-operation-input.service-information.service-instance-id\"\n pfx='pfx' local-only='false' force='false'>\n\t<parameter name=\"service-instance-name\" value=\"`$tmp.service-instance-name`\" />\n\t<parameter name=\"selflink\" value=\"`$service-object-path`\" />\n","comments":"","outputs":1,"x":591.4524154663086,"y":1065.9374208450317,"z":"573bd44.832f22c","wires":[["a7941b57.780c48","212a10f.c55d27"]]},{"id":"a7941b57.780c48","type":"failure","name":"failure","xml":"<outcome value='failure'>\n","comments":"","outputs":1,"x":803.214282989502,"y":1041.1755752563477,"z":"573bd44.832f22c","wires":[["db0cc330.28062"]]},{"id":"db0cc330.28062","type":"returnFailure","name":"return failure","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","comments":"","x":953.2142486572266,"y":1041.1756534576416,"z":"573bd44.832f22c","wires":[]},{"id":"8e1f0de6.26b1e","type":"set","name":"set service-level-oper-status to Created","xml":"<set>\n<parameter name='service-data.service-level-oper-status.order-status' value='Created' />\n<parameter name='service-data.service-level-oper-status.last-rpc-action' value='assign' />\n<parameter name='service-data.service-level-oper-status.last-action' value='CreateServiceInstance' />\n","comments":"","x":626.7380981445312,"y":1314.6277723312378,"z":"573bd44.832f22c","wires":[]},{"id":"1a5d5129.f380cf","type":"set","name":"set service-object-path","xml":"<set>\n<parameter name='service-object-path'\n value=\"`'restconf/config/GENERIC-RESOURCE-API:services/service/'\n + $service-topology-operation-input.service-information.service-instance-id\n + '/service-data/service-topology/'`\"/>\n","comments":"","x":575.9760437011719,"y":1001.8897714614868,"z":"573bd44.832f22c","wires":[]},{"id":"7ddf70bc.04d968","type":"switchNode","name":"switch order-status","xml":"<switch test='`$service-data.service-level-oper-status.order-status`'>\n","comments":"","outputs":1,"x":566.3809089660645,"y":431.0804195404053,"z":"573bd44.832f22c","wires":[["ce4b4db7.fee0c","660a8480.99e1c4","6b5f29ae.188e98"]]},{"id":"ce4b4db7.fee0c","type":"outcome","name":"Created","xml":"<outcome value='Created'>\n","comments":"","outputs":1,"x":762.3333587646484,"y":430.74701595306396,"z":"573bd44.832f22c","wires":[["b51ba79c.316bf"]]},{"id":"b51ba79c.316bf","type":"returnFailure","name":"return failure","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=\"The requested service already exists\" />\n","comments":"","x":964.476188659668,"y":430.3185501098633,"z":"573bd44.832f22c","wires":[]},{"id":"ff8f09db.fa31a8","type":"set","name":"set service-topology identifiers","xml":"<set>\n<parameter name='service-data.service-topology.service-topology-identifier.service-instance-id'\n value='`$service-topology-operation-input.service-information.service-instance-id`' />\n<parameter name='service-data.service-topology.service-topology-identifier.service-type'\n value='`$service-topology-operation-input.service-information.subscription-service-type`' />\n<parameter name='service-data.service-topology.service-topology-identifier.service-instance-name'\n value='`$tmp.service-instance-name`' />\n<parameter name='service-data.service-topology.service-topology-identifier.global-customer-id'\n value='`$service-topology-operation-input.service-information.global-customer-id`' />\n","comments":"","x":602.7143249511719,"y":1134.2707147598267,"z":"573bd44.832f22c","wires":[]},{"id":"791f39fa.05ac68","type":"for","name":"for each service-input-parameters","xml":"<for index='idx' start='0' end='`$service-topology-operation-input.service-request-input.service-input-parameters.param_length`' >\n","comments":"","outputs":1,"x":1032.523754119873,"y":1272.366153717041,"z":"573bd44.832f22c","wires":[["8b8629f3.cdd878"]]},{"id":"8b8629f3.cdd878","type":"set","name":"set parameter name/value","xml":"<set>\n<parameter name='service-data.service-topology.service-parameters[$idx].service-parameter-name'\n value='`$service-topology-operation-input.service-request-input.service-input-parameters.param[$idx].name`' />\n<parameter name='service-data.service-topology.service-parameters[$idx].service-parameter-value'\n value='`$service-topology-operation-input.service-request-input.service-input-parameters.param[$idx].value`' />\n","comments":"","x":1313.9522171020508,"y":1272.3661003112793,"z":"573bd44.832f22c","wires":[]},{"id":"d9bc037.5a8a28","type":"switchNode","name":"switch input parameter length","xml":"<switch test='`$service-topology-operation-input.service-request-input.service-input-parameters.param_length`'>\n","comments":"","outputs":1,"x":595.3333282470703,"y":1244.7468738555908,"z":"573bd44.832f22c","wires":[["6a4426e0.aa51d","35f72c92.6d34cc"]]},{"id":"6a4426e0.aa51d","type":"outcome","name":"NULL","xml":"<outcome value=''>","comments":"","outputs":1,"x":810.237907409668,"y":1220.9375076293945,"z":"573bd44.832f22c","wires":[["308e9af1.186aee"]]},{"id":"308e9af1.186aee","type":"block","name":"block","xml":"<block>\n","atomic":"false","comments":"","outputs":1,"x":948.8092994689941,"y":1220.9374904632568,"z":"573bd44.832f22c","wires":[[]]},{"id":"35f72c92.6d34cc","type":"other","name":"other","xml":"<outcome value='Other'>\n","comments":"","outputs":1,"x":808.8093185424805,"y":1272.366096496582,"z":"573bd44.832f22c","wires":[["791f39fa.05ac68"]]},{"id":"808a05d8.77b83","type":"set","name":"set service-topology ecomp-model-information","xml":"<set>\n<parameter name='service-data.service-topology.ecomp-model-information.'\n value='`$service-topology-operation-input.service-information.ecomp-model-information.`' />\n","comments":"","x":652.7143096923828,"y":1178.5562887191772,"z":"573bd44.832f22c","wires":[]},{"id":"212a10f.c55d27","type":"failure","name":"not-found","xml":"<outcome value='not-found'>\n","comments":"","outputs":1,"x":809.5237121582031,"y":1089.7469930648804,"z":"573bd44.832f22c","wires":[["92e69062.b6227"]]},{"id":"92e69062.b6227","type":"returnFailure","name":"return failure","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=\"The service instance does not exist in AAI\" />\n","comments":"","x":952.8570098876953,"y":1088.0803670883179,"z":"573bd44.832f22c","wires":[]},{"id":"9c81a56.0cea0d8","type":"call","name":"call GENERIC-RESOURCE-API:generate-unique-name","xml":"<call module='GENERIC-RESOURCE-API' rpc='generate-unique-name' mode='sync' >\n","comments":"","outputs":1,"x":1323.1904754638672,"y":814.8898191452026,"z":"573bd44.832f22c","wires":[["26b42ec9.82f8ba","4e7d6be0.902e04"]]},{"id":"26b42ec9.82f8ba","type":"failure","name":"failure","xml":"<outcome value='failure'>\n","comments":"","outputs":1,"x":1663.1904487609863,"y":789.8898782730103,"z":"573bd44.832f22c","wires":[["21b353c8.d1d184"]]},{"id":"4e7d6be0.902e04","type":"success","name":"success","xml":"<outcome value='success'>\n","comments":"","outputs":1,"x":1666.5237986246743,"y":839.5565214157104,"z":"573bd44.832f22c","wires":[["c3c9c1c1.1901e8"]]},{"id":"23c933b.2cfc14c","type":"set","name":"set variables for generating unique name","xml":"<set>\n<parameter name='generate-unique-name-input.index-table-name' value='SERVICE_INSTANCE_NAME_INDEX' />\n<parameter name='generate-unique-name-input.index-table-prefix-column' value='service_instance_name_prefix' />\n<parameter name='generate-unique-name-input.name-table-type' value='SERVICE_INSTANCE' />\n<parameter name='generate-unique-name-input.prefix' value=\"`$db.service-model.service-instance-name-prefix + '_'`\" />\n","comments":"","x":1278.190559387207,"y":754.5566291809082,"z":"573bd44.832f22c","wires":[]},{"id":"c3c9c1c1.1901e8","type":"set","name":"set tmp.service-instance-name to generated name","xml":"<set>\n<parameter name='tmp.service-instance-name' value='`$generate-unique-name-output.generated-name`' />\n","comments":"","x":1950.5713500976562,"y":838.6041021347046,"z":"573bd44.832f22c","wires":[]},{"id":"21b353c8.d1d184","type":"returnFailure","name":"return failure","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=\"`$generate-unique-name-output.error-message`\" />\n","comments":"","x":1831.0475616455078,"y":789.3183898925781,"z":"573bd44.832f22c","wires":[]},{"id":"3bcfb2c8.11039e","type":"block","name":"block : atomic","xml":"<block atomic=\"true\">","atomic":"true","outputs":1,"x":988.8571319580078,"y":909.8422355651855,"z":"573bd44.832f22c","wires":[["78963995.6cc0a","be4997df.1f332"]]},{"id":"be4997df.1f332","type":"call","name":"call GENERIC-RESOURCE-API:generate-unique-name","xml":"<call module='GENERIC-RESOURCE-API' rpc='generate-unique-name' mode='sync' >\n","comments":"","outputs":1,"x":1319.857177734375,"y":957.5089111328125,"z":"573bd44.832f22c","wires":[["9f464d6b.aff938","ae91a50b.b8231"]]},{"id":"9f464d6b.aff938","type":"failure","name":"failure","xml":"<outcome value='failure'>\n","comments":"","outputs":1,"x":1658.857105255127,"y":907.8422946929932,"z":"573bd44.832f22c","wires":[["52e3a7ce.0d766"]]},{"id":"ae91a50b.b8231","type":"success","name":"success","xml":"<outcome value='success'>\n","comments":"","outputs":1,"x":1662.190455118815,"y":959.5089378356934,"z":"573bd44.832f22c","wires":[["3b698a92.087b7e"]]},{"id":"78963995.6cc0a","type":"set","name":"set variables for generating unique name","xml":"<set>\n<parameter name='generate-unique-name-input.name-table-type' value='SERVICE_INSTANCE' />\n<parameter name='generate-unique-name-input.supplied-name' value='`$service-topology-operation-input.service-request-input.service-instance-name`' />\n","comments":"","x":1277.1905212402344,"y":886.1755924224854,"z":"573bd44.832f22c","wires":[]},{"id":"52e3a7ce.0d766","type":"returnFailure","name":"return failure","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=\"`$generate-unique-name-output.error-message`\" />\n","comments":"","x":1826.7142181396484,"y":907.270806312561,"z":"573bd44.832f22c","wires":[]},{"id":"ebfe18e9.9d4ed","type":"failure","name":"failure","xml":"<outcome value='failure'>\n","comments":"","outputs":1,"x":850.5713310241699,"y":524.6041011810303,"z":"573bd44.832f22c","wires":[["4098d552.aeef4c"]]},{"id":"a218a76b.7acc68","type":"not-found","name":"not-found","xml":"<outcome value='not-found'>\n","comments":"","outputs":1,"x":859.1427612304688,"y":567.889814376831,"z":"573bd44.832f22c","wires":[["558753d6.22bd54"]]},{"id":"4098d552.aeef4c","type":"returnFailure","name":"return failure","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 reading SERVICE_MODEL table\" />\n","comments":"","x":1023.4284973144531,"y":523.1755447387695,"z":"573bd44.832f22c","wires":[]},{"id":"660a8480.99e1c4","type":"outcome","name":"NULL","xml":"<outcome value=''>","comments":"","outputs":1,"x":760.3332824707031,"y":386.08033752441406,"z":"573bd44.832f22c","wires":[["334d5f6e.9e0ac"]]},{"id":"6b5f29ae.188e98","type":"other","name":"PendingDelete","xml":"<outcome value='PendingDelete'>\n","comments":"","outputs":1,"x":783.0000114440918,"y":474.7469959259033,"z":"573bd44.832f22c","wires":[["c4f908c4.ddc838"]]},{"id":"c4f908c4.ddc838","type":"returnFailure","name":"return failure","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=\"The requested service is pending deletion\" />\n","comments":"","x":965.333309173584,"y":474.7470064163208,"z":"573bd44.832f22c","wires":[]},{"id":"334d5f6e.9e0ac","type":"block","name":"block","xml":"<block>\n","atomic":"false","comments":"","outputs":1,"x":946.9999923706055,"y":385.0803565979004,"z":"573bd44.832f22c","wires":[[]]},{"id":"7d9ead4a.c2484c","type":"comment","name":"SERVICE_MODEL not in sdnc yet","info":"","comments":"","x":608,"y":608,"z":"573bd44.832f22c","wires":[]}] |
...