1
|
[{"id":"ba26137c.a02c4","type":"dgstart","name":"DGSTART","outputs":1,"x":147.14285278320312,"y":122.41365623474121,"z":"58644c55.2e09f4","wires":[["3615d32b.36469c"]]},{"id":"3615d32b.36469c","type":"service-logic","name":"GENERIC-RESOURCE-API ${project.version}","module":"GENERIC-RESOURCE-API","version":"${project.version}","comments":"","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}'>","outputs":1,"x":259.5714111328125,"y":162.65176677703857,"z":"58644c55.2e09f4","wires":[["cf125c5e.ac223"]]},{"id":"cf125c5e.ac223","type":"method","name":"method vnf-topology-operation-changeassign","xml":"<method rpc='vnf-topology-operation-changeassign' mode='sync'>\n","comments":"","outputs":1,"x":255.28575897216797,"y":202.41365432739258,"z":"58644c55.2e09f4","wires":[["d40bf3fc.b9b18"]]},{"id":"e5e0f4b8.266488","type":"comment","name":"vnf-topology-operation-changeassign","info":"","comments":"","x":541.4877090454102,"y":70,"z":"58644c55.2e09f4","wires":[]},{"id":"bb0be56d.51ce78","type":"switchNode","name":"switch request-action","xml":"<switch test='`$vnf-topology-operation-input.request-information.request-action`'>\n","comments":"","outputs":1,"x":546.3809661865234,"y":304.127947807312,"z":"58644c55.2e09f4","wires":[["cdb51213.4739d","7bf97be1.f8e5f4"]]},{"id":"cdb51213.4739d","type":"outcome","name":"CreateVnfInstance","xml":"<outcome value='CreateVnfInstance'>\n","comments":"","outputs":1,"x":770.5237808227539,"y":278.4136562347412,"z":"58644c55.2e09f4","wires":[["51c994ad.ff2c8c"]]},{"id":"7bf97be1.f8e5f4","type":"other","name":"other","xml":"<outcome value='Other'>\n","comments":"","outputs":1,"x":733.5238037109375,"y":322.46129512786865,"z":"58644c55.2e09f4","wires":[["f6f8cec3.eec86"]]},{"id":"51c994ad.ff2c8c","type":"block","name":"block","xml":"<block>\n","atomic":"false","comments":"","outputs":1,"x":962.0952377319336,"y":278.4136915206909,"z":"58644c55.2e09f4","wires":[[]]},{"id":"f6f8cec3.eec86","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 'changeassign' then request-action must be 'CreateVnfInstance'\" />\n","comments":"","x":940.9047508239746,"y":322.46130657196045,"z":"58644c55.2e09f4","wires":[]},{"id":"ae7fa21e.89e54","type":"switchNode","name":"switch order-status","xml":"<switch test='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-level-oper-status.order-status`'>\n","comments":"","outputs":1,"x":611.5238265991211,"y":855.2708969116211,"z":"58644c55.2e09f4","wires":[["d3ea0e40.484f7","61685b89.7bb954"]]},{"id":"d3ea0e40.484f7","type":"other","name":"PendingDelete","xml":"<outcome value='PendingDelete'>\n","comments":"","outputs":1,"x":813.5238838195801,"y":832.9850645065308,"z":"58644c55.2e09f4","wires":[["1188c5a4.66d15a"]]},{"id":"26b15807.544338","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 VNF is not pending deletion\" />\n","comments":"","x":979.666748046875,"y":876.3184423446655,"z":"58644c55.2e09f4","wires":[]},{"id":"cfffe6ff.f2f028","type":"block","name":"block : atomic","xml":"<block atomic=\"true\">","atomic":"true","outputs":1,"x":329.5238723754883,"y":851.0327186584473,"z":"58644c55.2e09f4","wires":[["26af04fb.a965bc","875f0999.0630e8","70c0738f.a4f70c","73c9510e.27512","672d6b2.4871c94"]]},{"id":"26af04fb.a965bc","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":623.5714721679688,"y":1110.699481010437,"z":"58644c55.2e09f4","wires":[]},{"id":"875f0999.0630e8","type":"returnSuccess","name":"return success","xml":"<return status='success'>\n","comments":"","x":597.8571739196777,"y":1153.556619644165,"z":"58644c55.2e09f4","wires":[]},{"id":"84550db4.425","type":"switchNode","name":"switch vnf_length","xml":"<switch test='`$service-data.vnfs.vnf_length`'>\n","comments":"","outputs":1,"x":532.3809051513672,"y":379.27079486846924,"z":"58644c55.2e09f4","wires":[["a86ad29c.85d2d"]]},{"id":"a86ad29c.85d2d","type":"other","name":"NULL","xml":"<outcome value=''>\n","comments":"","outputs":1,"x":719.0475845336914,"y":378.6040925979614,"z":"58644c55.2e09f4","wires":[["ece0e08b.59e26"]]},{"id":"ece0e08b.59e26","type":"returnFailure","name":"return failure","xml":"<return status='failure'>\n\t<parameter name='ack-final' value='Y'/>\n\t<parameter name=\"error-code\" value=\"404\" />\n <parameter name=\"error-message\" value=\"There are no VNFs in MD-SAL\" />\n","comments":"","x":900.7142105102539,"y":378.6040925979614,"z":"58644c55.2e09f4","wires":[]},{"id":"6a054c32.899054","type":"for","name":"for each vnf","xml":"<for index='idx' start='0' end='`$service-data.vnfs.vnf_length`' >\n","comments":"","outputs":1,"x":515.4761428833008,"y":425.7469711303711,"z":"58644c55.2e09f4","wires":[["8f020422.3c8738"]]},{"id":"8f020422.3c8738","type":"switchNode","name":"switch this vnf-id == input vnf-id","xml":"<switch test='`$service-data.vnfs.vnf[$idx].vnf-id == $vnf-topology-operation-input.vnf-information.vnf-id`'>\n","comments":"","outputs":1,"x":770.4762306213379,"y":425.4136390686035,"z":"58644c55.2e09f4","wires":[["d583eaa.7b69218"]]},{"id":"d583eaa.7b69218","type":"outcomeTrue","name":"true","xml":"<outcome value='true'>\n","comments":"","outputs":1,"x":1001.8095169067383,"y":425.41361713409424,"z":"58644c55.2e09f4","wires":[["bd161155.4b2b3"]]},{"id":"bd161155.4b2b3","type":"set","name":"set vnf-index","xml":"<set>\n<parameter name='vnf-index' value='`$idx`' />\n","comments":"","x":1177.1427116394043,"y":425.4136390686035,"z":"58644c55.2e09f4","wires":[]},{"id":"a4f0e9f2.ff7fd8","type":"switchNode","name":"switch vnf-index","xml":"<switch test='`$vnf-index`'>\n","comments":"","outputs":1,"x":527.1428070068359,"y":471.41364097595215,"z":"58644c55.2e09f4","wires":[["46d410bf.b0715"]]},{"id":"46d410bf.b0715","type":"other","name":"NULL","xml":"<outcome value=''>\n","comments":"","outputs":1,"x":708.8094253540039,"y":470.7469711303711,"z":"58644c55.2e09f4","wires":[["7743f028.1494a"]]},{"id":"7743f028.1494a","type":"returnFailure","name":"return failure","xml":"<return status='failure'>\n\t<parameter name='ack-final' value='Y'/>\n\t<parameter name=\"error-code\" value=\"404\" />\n <parameter name=\"error-message\" value=\"'Could not find VNF ' + $vnf-topology-operation-input.vnf-information.vnf-id + ' in MD-SAL'\" />\n","comments":"","x":875.4761123657227,"y":470.4135971069336,"z":"58644c55.2e09f4","wires":[]},{"id":"70c0738f.a4f70c","type":"set","name":"copy ONAP model information","xml":"<set>\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-topology.onap-model-information.'\n value='`$vnf-topology-operation-input.vnf-information.onap-model-information.`' />\n","comments":"","x":646.9284210205078,"y":1013.2857179641724,"z":"58644c55.2e09f4","wires":[]},{"id":"73c9510e.27512","type":"set","name":"set vnf-level-oper-status to Created","xml":"<set>\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-level-oper-status.order-status' value='Created' />\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-level-oper-status.last-rpc-action' value='`$vnf-topology-operation-input.sdnc-request-header.svc-action`' />\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-level-oper-status.last-action' value='`$vnf-topology-operation-input.request-information.request-action`' />\n","comments":"","x":659.5238952636719,"y":1063.080382347107,"z":"58644c55.2e09f4","wires":[]},{"id":"1188c5a4.66d15a","type":"block","name":"block","xml":"<block>\n","atomic":"false","comments":"","outputs":1,"x":962.8572463989258,"y":832.3333358764648,"z":"58644c55.2e09f4","wires":[[]]},{"id":"61685b89.7bb954","type":"other","name":"other","xml":"<outcome value='Other'>\n","comments":"","outputs":1,"x":787.8572807312012,"y":877.3333263397217,"z":"58644c55.2e09f4","wires":[["26b15807.544338"]]},{"id":"672d6b2.4871c94","type":"get-resource","name":"get-resource VF_MODEL","xml":"<get-resource plugin='org.onap.ccsdk.sli.adaptors.resource.sql.SqlResource' resource='SQL'\n key='SELECT * from VF_MODEL WHERE customization_uuid = $vnf-topology-operation-input.vnf-information.onap-model-information.model-customization-uuid'\n pfx='db.vf-model'>\n\n","comments":"","outputs":1,"x":636.1905670166016,"y":940.6666288375854,"z":"58644c55.2e09f4","wires":[["baa14df2.dca8","11eb13fa.f290dc"]]},{"id":"a9b0ba1a.e7cf28","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 VNF customization UUID ' + $vnf-topology-operation-input.vnf-information.onap-model-information.model-customization-uuid`\" />\n","comments":"","x":989.2857551574707,"y":965.7618017196655,"z":"58644c55.2e09f4","wires":[]},{"id":"baa14df2.dca8","type":"failure","name":"failure","xml":"<outcome value='failure'>\n","comments":"","outputs":1,"x":823.6429557800293,"y":921.0474662780762,"z":"58644c55.2e09f4","wires":[["92f92b7d.20be58"]]},{"id":"11eb13fa.f290dc","type":"not-found","name":"not-found","xml":"<outcome value='not-found'>\n","comments":"","outputs":1,"x":832.2143859863281,"y":965.333179473877,"z":"58644c55.2e09f4","wires":[["a9b0ba1a.e7cf28"]]},{"id":"92f92b7d.20be58","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 VF_MODEL table\" />\n","comments":"","x":988.6429557800293,"y":920.8570604324341,"z":"58644c55.2e09f4","wires":[]},{"id":"e882c6d5.a48038","type":"comment","name":"check removed with US622450","info":"","comments":"","x":1177.1430206298828,"y":843.2857015132904,"z":"58644c55.2e09f4","wires":[]},{"id":"1fd874ae.f932db","type":"switchNode","name":"switch: sdnc-generated-cloud-resources","xml":"<switch test='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vnf-topology.sdnc-generated-cloud-resources`'>\n","comments":"","outputs":1,"x":601.4284973144531,"y":577.1428737640381,"z":"58644c55.2e09f4","wires":[["a5a1ece5.21ae4","a0347796.6bfff8"]]},{"id":"a5a1ece5.21ae4","type":"outcomeTrue","name":"true","xml":"<outcome value='true'>\n","comments":"","outputs":1,"x":852.1785430908203,"y":577.1428756713867,"z":"58644c55.2e09f4","wires":[["b26b3417.62ed98"]]},{"id":"b26b3417.62ed98","type":"call","name":"call self-serve-vnf-changeassign","xml":"<call module='GENERIC-RESOURCE-API' rpc='self-serve-vnf-changeassign' mode='sync' >\n","comments":"","outputs":1,"x":1069.6427001953125,"y":577.3214721679688,"z":"58644c55.2e09f4","wires":[["1b2e4be7.c157d4","23fe395e.1497d6"]]},{"id":"1b2e4be7.c157d4","type":"failure","name":"failure","xml":"<outcome value='failure'>\n","comments":"","outputs":1,"x":1295.3926849365234,"y":577.571460723877,"z":"58644c55.2e09f4","wires":[["9e12abdd.a2c528"]]},{"id":"9e12abdd.a2c528","type":"returnFailure","name":"return failure","xml":"<return status='failure'>\n<parameter name='error-code' value='500' />\n<parameter name='error-message' value=\"`'Encountered error while unassigning self-serve resources with error: '+ $error-message`\" />\n","comments":"","x":1454.964111328125,"y":577.21435546875,"z":"58644c55.2e09f4","wires":[]},{"id":"a0347796.6bfff8","type":"other","name":"other","xml":"<outcome value='Other'>\n","comments":"","outputs":1,"x":854.28564453125,"y":621.4285163879395,"z":"58644c55.2e09f4","wires":[["cfffe6ff.f2f028"]]},{"id":"d40bf3fc.b9b18","type":"block","name":"block : atomic","xml":"<block atomic=\"true\">","atomic":"true","outputs":1,"x":274.2857131958008,"y":425.7142848968506,"z":"58644c55.2e09f4","wires":[["bb0be56d.51ce78","84550db4.425","6a054c32.899054","a4f0e9f2.ff7fd8","1fd874ae.f932db"]]},{"id":"38f665e5.63630a","type":"comment","name":"self-serve FORKING LOGIC","info":"","comments":"","x":334.28570556640625,"y":532.8571243286133,"z":"58644c55.2e09f4","wires":[]},{"id":"23fe395e.1497d6","type":"success","name":"success","xml":"<outcome value='success'>\n","comments":"","outputs":1,"x":1301.857177734375,"y":622.857177734375,"z":"58644c55.2e09f4","wires":[["1eaf4622.591d5a"]]},{"id":"1eaf4622.591d5a","type":"returnSuccess","name":"return success","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","comments":"","x":1470.4285926818848,"y":622.4286193847656,"z":"58644c55.2e09f4","wires":[]}]
|