diff options
author | prakash.e <prakash.e@huawei.com> | 2019-03-28 20:08:32 +0530 |
---|---|---|
committer | prakash.e <prakash.e@huawei.com> | 2019-03-28 20:09:25 +0530 |
commit | fa9287395328d6038cec46f3873c39eed2edd0aa (patch) | |
tree | 9e5039f634e56d898362b407045bc0d0489bdf1b /platform-logic/generic-resource-api | |
parent | 6bae57f12b29d9227decc4101ee0d971f29090d8 (diff) |
CCVPN extension lan-port DGs
lan-port vf-module-topology-operation DGs
Change-Id: If1eed2e899229eb311c2cc6324dfa7858404ce18
Issue-ID: SDNC-659
Signed-off-by: Prakash.E <prakash.e@huawei.com>
Former-commit-id: b5d769f019aba5bdd25eaae21d7c190d7b428f64
Diffstat (limited to 'platform-logic/generic-resource-api')
10 files changed, 6618 insertions, 0 deletions
diff --git a/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-get-vf-module-lanport-param.json b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-get-vf-module-lanport-param.json new file mode 100644 index 00000000..4bb31386 --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-get-vf-module-lanport-param.json @@ -0,0 +1,507 @@ +[
+ {
+ "id": "3208e6b7.8cb61a",
+ "type": "for",
+ "name": "for each sdwan-get-request-input-param",
+ "xml": "<for index=\"idx\" start=\"0\" end=\"`$vf-module-topology-operation-input.vf-module-request-input.vf-module-input-parameters.param_length`\">\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 327,
+ "y": 415.6666383743286,
+ "z": "f5fe05ac.3dbcd8",
+ "wires": [
+ [
+ "5e79a667.e36978"
+ ]
+ ]
+ },
+ {
+ "id": "bb96599.94117a8",
+ "type": "dgstart",
+ "name": "DGSTART",
+ "outputs": 1,
+ "x": 159.3332290649414,
+ "y": 78,
+ "z": "f5fe05ac.3dbcd8",
+ "wires": [
+ [
+ "619534b0.e7c14c"
+ ]
+ ]
+ },
+ {
+ "id": "619534b0.e7c14c",
+ "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": 304.3332328796387,
+ "y": 159.0000171661377,
+ "z": "f5fe05ac.3dbcd8",
+ "wires": [
+ [
+ "fa9cc521.66a538"
+ ]
+ ]
+ },
+ {
+ "id": "fa9cc521.66a538",
+ "type": "method",
+ "name": "sdwan-get-vf-module-lanport-param",
+ "xml": "<method rpc='sdwan-get-vf-module-lanport-param' mode='sync'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 292.3333511352539,
+ "y": 247,
+ "z": "f5fe05ac.3dbcd8",
+ "wires": [
+ [
+ "9745a419.00eab8"
+ ]
+ ]
+ },
+ {
+ "id": "9745a419.00eab8",
+ "type": "block",
+ "name": "block : atomic",
+ "xml": "<block atomic=\"true\">\n",
+ "atomic": "false",
+ "comments": "",
+ "outputs": 1,
+ "x": 299.33324432373047,
+ "y": 333.0000581741333,
+ "z": "f5fe05ac.3dbcd8",
+ "wires": [
+ [
+ "3208e6b7.8cb61a"
+ ]
+ ]
+ },
+ {
+ "id": "5e79a667.e36978",
+ "type": "block",
+ "name": "block",
+ "xml": "<block>\n",
+ "atomic": "false",
+ "comments": "",
+ "outputs": 1,
+ "x": 583.2326469421387,
+ "y": 418.0103905200958,
+ "z": "f5fe05ac.3dbcd8",
+ "wires": [
+ [
+ "c8ef8603.ded258",
+ "de743e37.2d6ef",
+ "74590dc6.2a74a4",
+ "24b13d58.52ec12",
+ "c43795e3.062a98",
+ "575ca25e.3b0f5c",
+ "e5fd35dc.3490a8",
+ "6a33fd1e.0f98c4",
+ "f22f3b86.1d2998",
+ "c6929deb.bb79b"
+ ]
+ ]
+ },
+ {
+ "id": "c8ef8603.ded258",
+ "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": 777.7332534790039,
+ "y": 708.0107636451721,
+ "z": "f5fe05ac.3dbcd8",
+ "wires": []
+ },
+ {
+ "id": "74590dc6.2a74a4",
+ "type": "switchNode",
+ "name": "switch deviceName",
+ "xml": "<switch test=\"`$vf-module-request-input.vf-module-input-parameters.param[$idx].name == 'deviceName'`\">\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 805.7326431274414,
+ "y": 345.01042914390564,
+ "z": "f5fe05ac.3dbcd8",
+ "wires": [
+ [
+ "beaed204.71603"
+ ]
+ ]
+ },
+ {
+ "id": "beaed204.71603",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 980.7330360412598,
+ "y": 343.01051592826843,
+ "z": "f5fe05ac.3dbcd8",
+ "wires": [
+ [
+ "b55ea4ff.9cde28"
+ ]
+ ]
+ },
+ {
+ "id": "b55ea4ff.9cde28",
+ "type": "set",
+ "name": "set deviceName",
+ "xml": "<set>\n<parameter name='prop.lan.deviceName' value='`$vf-module-request-input.vf-module-input-parameters.param[$idx].value`' />\n",
+ "comments": "",
+ "x": 1155.7331199645996,
+ "y": 344.61056327819824,
+ "z": "f5fe05ac.3dbcd8",
+ "wires": []
+ },
+ {
+ "id": "e5fd35dc.3490a8",
+ "type": "switchNode",
+ "name": "switch vlanId",
+ "xml": "<switch test=\"`$vf-module-request-input.vf-module-input-parameters.param[$idx].name == 'vlanId'`\">\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 783.5727691650391,
+ "y": 552.0104854106903,
+ "z": "f5fe05ac.3dbcd8",
+ "wires": [
+ [
+ "99b2d592.8926d8"
+ ]
+ ]
+ },
+ {
+ "id": "99b2d592.8926d8",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 976.5727577209473,
+ "y": 554.0105578899384,
+ "z": "f5fe05ac.3dbcd8",
+ "wires": [
+ [
+ "e0277d38.f11f6"
+ ]
+ ]
+ },
+ {
+ "id": "e0277d38.f11f6",
+ "type": "set",
+ "name": "set vlanId",
+ "xml": "<set>\n<parameter name='prop.lan.vlanId' value='`$vf-module-request-input.vf-module-input-parameters.param[$idx].value`' />\n",
+ "comments": "",
+ "x": 1122.9065856933594,
+ "y": 555.4718005657196,
+ "z": "f5fe05ac.3dbcd8",
+ "wires": []
+ },
+ {
+ "id": "575ca25e.3b0f5c",
+ "type": "switchNode",
+ "name": "switch ipAddress",
+ "xml": "<switch test=\"`$vf-module-request-input.vf-module-input-parameters.param[$idx].name == 'ipAddress'`\">\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 792.6279563903809,
+ "y": 510.3871638774872,
+ "z": "f5fe05ac.3dbcd8",
+ "wires": [
+ [
+ "e7a176a1.ce4358"
+ ]
+ ]
+ },
+ {
+ "id": "e7a176a1.ce4358",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 977.6280975341797,
+ "y": 510.38712096214294,
+ "z": "f5fe05ac.3dbcd8",
+ "wires": [
+ [
+ "d2f3c8c4.499528"
+ ]
+ ]
+ },
+ {
+ "id": "d2f3c8c4.499528",
+ "type": "set",
+ "name": "set ipAddress",
+ "xml": "<set>\n<parameter name='prop.lan.ipAddress' value='`$vf-module-request-input.vf-module-input-parameters.param[$idx].value`' />\n",
+ "comments": "",
+ "x": 1141.9619789123535,
+ "y": 511.8483989238739,
+ "z": "f5fe05ac.3dbcd8",
+ "wires": []
+ },
+ {
+ "id": "c43795e3.062a98",
+ "type": "switchNode",
+ "name": "switch portNumber",
+ "xml": "<switch test=\"`$vf-module-request-input.vf-module-input-parameters.param[$idx].name == 'portNumber'`\">\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 798.9610862731934,
+ "y": 469.00466132164,
+ "z": "f5fe05ac.3dbcd8",
+ "wires": [
+ [
+ "7eda0cd0.bddb34"
+ ]
+ ]
+ },
+ {
+ "id": "7eda0cd0.bddb34",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 980.9611854553223,
+ "y": 471.00467467308044,
+ "z": "f5fe05ac.3dbcd8",
+ "wires": [
+ [
+ "f1d0b896.8928d8"
+ ]
+ ]
+ },
+ {
+ "id": "f1d0b896.8928d8",
+ "type": "set",
+ "name": "set portNumber",
+ "xml": "<set>\n<parameter name='prop.lan.portNumber' value='`$vf-module-request-input.vf-module-input-parameters.param[$idx].value`' />\n",
+ "comments": "",
+ "x": 1150.961597442627,
+ "y": 469.60469126701355,
+ "z": "f5fe05ac.3dbcd8",
+ "wires": []
+ },
+ {
+ "id": "24b13d58.52ec12",
+ "type": "switchNode",
+ "name": "switch portType",
+ "xml": "<switch test=\"`$vf-module-request-input.vf-module-input-parameters.param[$idx].name == 'portType'`\">\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 788.8561058044434,
+ "y": 426.9779860973358,
+ "z": "f5fe05ac.3dbcd8",
+ "wires": [
+ [
+ "945d6482.e4ba88"
+ ]
+ ]
+ },
+ {
+ "id": "945d6482.e4ba88",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 983.8561782836914,
+ "y": 427.9780204296112,
+ "z": "f5fe05ac.3dbcd8",
+ "wires": [
+ [
+ "51acc9c3.2fe3b8"
+ ]
+ ]
+ },
+ {
+ "id": "51acc9c3.2fe3b8",
+ "type": "set",
+ "name": "set portType",
+ "xml": "<set>\n<parameter name='prop.lan.portType' value='`$vf-module-request-input.vf-module-input-parameters.param[$idx].value`' />\n",
+ "comments": "",
+ "x": 1141.8565788269043,
+ "y": 425.57802534103394,
+ "z": "f5fe05ac.3dbcd8",
+ "wires": []
+ },
+ {
+ "id": "de743e37.2d6ef",
+ "type": "switchNode",
+ "name": "switch id",
+ "xml": "<switch test=\"`$vf-module-request-input.vf-module-input-parameters.param[$idx].name == 'id'`\">\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 789.7319984436035,
+ "y": 296.3970763683319,
+ "z": "f5fe05ac.3dbcd8",
+ "wires": [
+ [
+ "5d9145a5.3659cc"
+ ]
+ ]
+ },
+ {
+ "id": "5d9145a5.3659cc",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 981.7319221496582,
+ "y": 296.3970830440521,
+ "z": "f5fe05ac.3dbcd8",
+ "wires": [
+ [
+ "e87eb6bc.61a328"
+ ]
+ ]
+ },
+ {
+ "id": "e87eb6bc.61a328",
+ "type": "set",
+ "name": "set id",
+ "xml": "<set>\n<parameter name='prop.lan.id' value='`$vf-module-request-input.vf-module-input-parameters.param[$idx].value`' />\n",
+ "comments": "",
+ "x": 1125.7321891784668,
+ "y": 295.99721121788025,
+ "z": "f5fe05ac.3dbcd8",
+ "wires": []
+ },
+ {
+ "id": "6a33fd1e.0f98c4",
+ "type": "switchNode",
+ "name": "switch portSwitch",
+ "xml": "<switch test=\"`$vf-module-request-input.vf-module-input-parameters.param[$idx].name == 'portSwitch'`\">\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 795.7324638366699,
+ "y": 388.0207631587982,
+ "z": "f5fe05ac.3dbcd8",
+ "wires": [
+ [
+ "f0a564e5.e03788"
+ ]
+ ]
+ },
+ {
+ "id": "f0a564e5.e03788",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 980.7323989868164,
+ "y": 386.02081274986267,
+ "z": "f5fe05ac.3dbcd8",
+ "wires": [
+ [
+ "607e93f6.70105c"
+ ]
+ ]
+ },
+ {
+ "id": "607e93f6.70105c",
+ "type": "set",
+ "name": "set portSwitch",
+ "xml": "<set>\n<parameter name='prop.lan.portSwitch' value='`$vf-module-request-input.vf-module-input-parameters.param[$idx].value`' />\n",
+ "comments": "",
+ "x": 1152.7327842712402,
+ "y": 386.6208064556122,
+ "z": "f5fe05ac.3dbcd8",
+ "wires": []
+ },
+ {
+ "id": "f22f3b86.1d2998",
+ "type": "switchNode",
+ "name": "switch devicePortId",
+ "xml": "<switch test=\"`$vf-module-request-input.vf-module-input-parameters.param[$idx].name == 'devicePortId'`\">\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 799.0000152587891,
+ "y": 596.0000171661377,
+ "z": "f5fe05ac.3dbcd8",
+ "wires": [
+ [
+ "e1bc8bda.eb9038"
+ ]
+ ]
+ },
+ {
+ "id": "e1bc8bda.eb9038",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 968.0000286102295,
+ "y": 596.0000991821289,
+ "z": "f5fe05ac.3dbcd8",
+ "wires": [
+ [
+ "d2ef0983.267148"
+ ]
+ ]
+ },
+ {
+ "id": "d2ef0983.267148",
+ "type": "set",
+ "name": "set devicePortId",
+ "xml": "<set>\n<parameter name='prop.lan.devicePortId' value='`$vf-module-request-input.vf-module-input-parameters.param[$idx].value`' />\n",
+ "comments": "",
+ "x": 1126.3338165283203,
+ "y": 599.4613151550293,
+ "z": "f5fe05ac.3dbcd8",
+ "wires": []
+ },
+ {
+ "id": "c6929deb.bb79b",
+ "type": "switchNode",
+ "name": "switch lanPortId",
+ "xml": "<switch test=\"`$vf-module-request-input.vf-module-input-parameters.param[$idx].name == 'lanPortId'`\">\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 781,
+ "y": 652,
+ "z": "f5fe05ac.3dbcd8",
+ "wires": [
+ [
+ "3b76a25e.db01ce"
+ ]
+ ]
+ },
+ {
+ "id": "3b76a25e.db01ce",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 973.9999885559082,
+ "y": 654.000072479248,
+ "z": "f5fe05ac.3dbcd8",
+ "wires": [
+ [
+ "5afdfd4e.d87a04"
+ ]
+ ]
+ },
+ {
+ "id": "5afdfd4e.d87a04",
+ "type": "set",
+ "name": "set lanPortId",
+ "xml": "<set>\n<parameter name='prop.lan.lanPortId' value='`$vf-module-request-input.vf-module-input-parameters.param[$idx].value`' />\n",
+ "comments": "",
+ "x": 1120.3338165283203,
+ "y": 655.4613151550293,
+ "z": "f5fe05ac.3dbcd8",
+ "wires": []
+ }
+]
\ No newline at end of file diff --git a/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-vf-operation-lanport-activate.json b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-vf-operation-lanport-activate.json new file mode 100644 index 00000000..138d31fb --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-vf-operation-lanport-activate.json @@ -0,0 +1,1853 @@ +[
+ {
+ "id": "cea6a9f1.279478",
+ "type": "switchNode",
+ "name": "switch vf-modules.vf-module_length",
+ "xml": "<switch test='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module_length`'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 570.7143020629883,
+ "y": 337.99999046325684,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "4a89ecf7.049034",
+ "2a09fa32.63fc36",
+ "c2f1098d.e8bd38"
+ ]
+ ]
+ },
+ {
+ "id": "1833f3f4.1b830c",
+ "type": "dgstart",
+ "name": "DGSTART",
+ "outputs": 1,
+ "x": 107.71429824829102,
+ "y": 29,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "181dc2fc.e539bd"
+ ]
+ ]
+ },
+ {
+ "id": "181dc2fc.e539bd",
+ "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": 177,
+ "y": 92.23810958862305,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "25791551.06845a"
+ ]
+ ]
+ },
+ {
+ "id": "25791551.06845a",
+ "type": "method",
+ "name": "method sdwan-vf-operation-lanport-activate",
+ "xml": "<method rpc='sdwan-vf-operation-lanport-activate' mode='sync'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 188.71429443359375,
+ "y": 186.58634185791016,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "419d7afa.b1ca54"
+ ]
+ ]
+ },
+ {
+ "id": "419d7afa.b1ca54",
+ "type": "block",
+ "name": "block : atomic",
+ "xml": "<block atomic=\"true\">",
+ "atomic": "true",
+ "outputs": 1,
+ "x": 189.38096618652344,
+ "y": 442.666708946228,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "f5110085.4f487",
+ "f62e0d25.9e73c",
+ "cea6a9f1.279478",
+ "76df47d2.f28eb8",
+ "3a550152.acb95e",
+ "bad651b2.12a17",
+ "a66a0a0e.fef0c8",
+ "f2a2fd31.6afea",
+ "11a6133a.d1ed1d",
+ "6bb3e148.a2b06",
+ "233d7734.c6ad18",
+ "ec89c38e.b0db3",
+ "cfe4c928.772628",
+ "307480f2.c3f12",
+ "83adcbda.9cab18",
+ "41a8aff.133475",
+ "bf4ca0a0.f719b",
+ "14cdbea6.6ff3c1",
+ "96f47da7.f3275",
+ "7299f238.fa9f1c",
+ "e4f03070.b443a",
+ "1e3434c6.db511b",
+ "56401cb0.1f0164"
+ ]
+ ]
+ },
+ {
+ "id": "f62e0d25.9e73c",
+ "type": "for",
+ "name": "for each vnf",
+ "xml": "<for index='idx' start='0' end='`$service-data.vnfs.vnf_length`' >\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 520.7456588745117,
+ "y": 266.2691411972046,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "b7bf67d0.4c13b8"
+ ]
+ ]
+ },
+ {
+ "id": "f5110085.4f487",
+ "type": "switchNode",
+ "name": "switch vnf_length",
+ "xml": "<switch test='`$service-data.vnfs.vnf_length`'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 525.7143135070801,
+ "y": 205.00001049041748,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "61a8d0c5.ce10b"
+ ]
+ ]
+ },
+ {
+ "id": "61a8d0c5.ce10b",
+ "type": "outcome",
+ "name": "NULL",
+ "xml": "<outcome value=''>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 705.7142944335938,
+ "y": 204,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "3e167156.21c02e"
+ ]
+ ]
+ },
+ {
+ "id": "3e167156.21c02e",
+ "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=\"vnf-topology-operation-input.vnf-request-input.vnf-id not found in service-data\" />\n",
+ "comments": "",
+ "x": 855.1430206298828,
+ "y": 205.14291763305664,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "b7bf67d0.4c13b8",
+ "type": "switchNode",
+ "name": "switch this vnf-id == input vnf-id",
+ "xml": "<switch test=\"`$service-data.vnfs.vnf[$idx].vnf-id == $vf-module-topology-operation-input.vnf-information.vnf-id`\"> \n",
+ "comments": "",
+ "outputs": 1,
+ "x": 743.7143096923828,
+ "y": 267.00000619888306,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "29696342.56f90c"
+ ]
+ ]
+ },
+ {
+ "id": "29696342.56f90c",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 958.7142944335938,
+ "y": 265,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "1ba7830b.c7ea6d"
+ ]
+ ]
+ },
+ {
+ "id": "1ba7830b.c7ea6d",
+ "type": "set",
+ "name": "set vnf-index",
+ "xml": "<set>\n<parameter name='vnf-index' value='`$idx`' />\n",
+ "comments": "",
+ "x": 1122.7142944335938,
+ "y": 260,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "2a09fa32.63fc36",
+ "type": "outcome",
+ "name": "NULL",
+ "xml": "<outcome value=''>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 792.7142944335938,
+ "y": 372,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "4ead305d.0b806"
+ ]
+ ]
+ },
+ {
+ "id": "4a89ecf7.049034",
+ "type": "outcome",
+ "name": "0",
+ "xml": "<outcome value='0'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 797.7142906188965,
+ "y": 318.9999990463257,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "4ead305d.0b806"
+ ]
+ ]
+ },
+ {
+ "id": "4ead305d.0b806",
+ "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=\"vnf-topology-operation-input.vnf-request-input.vnf-id not found in service-data\" />\n",
+ "comments": "",
+ "x": 955.7142944335938,
+ "y": 332,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "c2f1098d.e8bd38",
+ "type": "other",
+ "name": "other",
+ "xml": "<outcome value='Other'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 792.7142944335938,
+ "y": 433,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "2458c219.d10e1e"
+ ]
+ ]
+ },
+ {
+ "id": "ead36ccd.33529",
+ "type": "set",
+ "name": "set vf-module_length",
+ "xml": "<set>\n<parameter name='vf-module-length' value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module_length`' />\n\n",
+ "comments": "",
+ "x": 1146.7143096923828,
+ "y": 431.0000139474869,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "2458c219.d10e1e",
+ "type": "block",
+ "name": "block : atomic",
+ "xml": "<block atomic=\"true\">",
+ "atomic": "true",
+ "outputs": 1,
+ "x": 953.7143402099609,
+ "y": 429.99999141693115,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "ead36ccd.33529",
+ "386f97ee.904d48"
+ ]
+ ]
+ },
+ {
+ "id": "386f97ee.904d48",
+ "type": "for",
+ "name": "for each existing vf-index",
+ "xml": "<for index='idx' start='0' end='`$vf-module-length`' >\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1165.7142791748047,
+ "y": 483.99999046325684,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "593c39.dc7673c8"
+ ]
+ ]
+ },
+ {
+ "id": "593c39.dc7673c8",
+ "type": "switchNode",
+ "name": "switch vf-module-id found",
+ "xml": "<switch test=\"`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$idx].vf-module-id == $vf-module-topology-operation-input.vf-module-information.vf-module-id`\">\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1408.7142944335938,
+ "y": 479,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "1efda74.b0eb959"
+ ]
+ ]
+ },
+ {
+ "id": "1efda74.b0eb959",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1606.7143230438232,
+ "y": 466.0000066757202,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "d0b5f3a2.35747"
+ ]
+ ]
+ },
+ {
+ "id": "d0b5f3a2.35747",
+ "type": "block",
+ "name": "block : atomic",
+ "xml": "<block atomic=\"true\">",
+ "atomic": "true",
+ "outputs": 1,
+ "x": 1758.7142944335938,
+ "y": 468,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "1fc6559e.18634a",
+ "802dea9f.3c2848",
+ "9329a8cc.23d418"
+ ]
+ ]
+ },
+ {
+ "id": "1fc6559e.18634a",
+ "type": "set",
+ "name": "set tmp.vidx and ctx.vnf-data",
+ "xml": "<set>\n<parameter name='tmp.vidx' value='`$idx`' />\n<parameter name='ctx.vf-module-data.' value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$idx].vf-module-data.`' />\n",
+ "comments": "",
+ "x": 1986.7144088745117,
+ "y": 410.00000381469727,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "802dea9f.3c2848",
+ "type": "set",
+ "name": "set vf-module-request-input.",
+ "xml": "<set>\n<parameter name='vf-module-request-input.' value='`$ctx.vf-module-data.vf-module-request-input.`' />\n\n",
+ "comments": "",
+ "x": 1990.7144088745117,
+ "y": 464.00000381469727,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "76df47d2.f28eb8",
+ "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": 504.714412689209,
+ "y": 2079.501151561737,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "9329a8cc.23d418",
+ "type": "call",
+ "name": "call sdwan-get-vf-module-lanport-param",
+ "xml": "<call module='GENERIC-RESOURCE-API' rpc='sdwan-get-vf-module-lanport-param' mode='sync' >\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 2021.16943359375,
+ "y": 515.0104961395264,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ []
+ ]
+ },
+ {
+ "id": "b2d390ae.97474",
+ "type": "for",
+ "name": "for vf-modules.vf-module_length",
+ "xml": "<for index='vfidx' start='0' end='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module_length`' >\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 827.9683685302734,
+ "y": 520.0040225982666,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "7dff73e1.0243cc"
+ ]
+ ]
+ },
+ {
+ "id": "3f6c843d.edec8c",
+ "type": "switchNode",
+ "name": "switch this deviceName == vf-input",
+ "xml": "<switch test=\"`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].value == '$prop.lan.deviceName'`\">\n \n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1100.9686126708984,
+ "y": 606.0041282176971,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "cb455713.e1bdd8"
+ ]
+ ]
+ },
+ {
+ "id": "7dff73e1.0243cc",
+ "type": "for",
+ "name": "for vf-module-input-param length",
+ "xml": "<for index='pidx' start='0' end='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param_length`' >\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1125.9682846069336,
+ "y": 523.0040645599365,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "3f6c843d.edec8c"
+ ]
+ ]
+ },
+ {
+ "id": "cb455713.e1bdd8",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1314.9684257507324,
+ "y": 603.0041129589081,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "8c1ad275.b541"
+ ]
+ ]
+ },
+ {
+ "id": "8c1ad275.b541",
+ "type": "for",
+ "name": "for vf-modules.vf-module_length",
+ "xml": "<for index='pidx' start='0' end='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param_length`' >\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1528.9684677124023,
+ "y": 599.0040664672852,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "6aaf6a5c.76e9f4"
+ ]
+ ]
+ },
+ {
+ "id": "6aaf6a5c.76e9f4",
+ "type": "switchNode",
+ "name": "switch deviceId == input vf-id",
+ "xml": "<switch test=\"`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].name == 'deviceId'`\">\n \n\n\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1843.9685440063477,
+ "y": 598.0040471553802,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "85841cc6.de2b3"
+ ]
+ ]
+ },
+ {
+ "id": "85841cc6.de2b3",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 2045.9686737060547,
+ "y": 596.0040481090546,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "1722d3f0.fc82dc"
+ ]
+ ]
+ },
+ {
+ "id": "1722d3f0.fc82dc",
+ "type": "set",
+ "name": "set prop.lan.deviceId",
+ "xml": "<set>\n<parameter name='prop.lan.deviceId' value='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].value`' />\n",
+ "comments": "",
+ "x": 2220.9685668945312,
+ "y": 596.004228591919,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "3a550152.acb95e",
+ "type": "for",
+ "name": "for service-data.vnfs.vnf_length",
+ "xml": "<for index='vnfidx' start='0' end='`$service-data.vnfs.vnf_length`' >\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 573.9682159423828,
+ "y": 455.00401973724365,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "b2d390ae.97474"
+ ]
+ ]
+ },
+ {
+ "id": "566234f6.d57f8c",
+ "type": "switchNode",
+ "name": "switch ActivateSDWANSiteInstance",
+ "xml": "<switch test=\"`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.request-information.request-action == 'ActivateSDWANSiteInstance'`\">\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1168.7185821533203,
+ "y": 727.0039882659912,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "d08758a.8a9d4a8"
+ ]
+ ]
+ },
+ {
+ "id": "4a6e0872.754c78",
+ "type": "for",
+ "name": "for vf-modules.vf-module_length",
+ "xml": "<for index='vfidx' start='0' end='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module_length`' >\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 814.7184219360352,
+ "y": 694.0040283203125,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "2141a4d0.4ed0ac"
+ ]
+ ]
+ },
+ {
+ "id": "83adcbda.9cab18",
+ "type": "for",
+ "name": "for service-data.vnfs.vnf_length",
+ "xml": "<for index='vnfidx' start='0' end='`$service-data.vnfs.vnf_length`' >\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 565.7182769775391,
+ "y": 625.0039081573486,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "4a6e0872.754c78"
+ ]
+ ]
+ },
+ {
+ "id": "d08758a.8a9d4a8",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1390.7184982299805,
+ "y": 727.0040698051453,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "5c9349a5.10cdf8"
+ ]
+ ]
+ },
+ {
+ "id": "5c9349a5.10cdf8",
+ "type": "for",
+ "name": "for vf-modules.vf-module_length",
+ "xml": "<for index='pidx' start='0' end='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param_length`' >\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1471.968505859375,
+ "y": 801.5040712356567,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "78c531f9.c452d"
+ ]
+ ]
+ },
+ {
+ "id": "78502254.1e1d1c",
+ "type": "switchNode",
+ "name": "switch siteId",
+ "xml": "<switch test=\"`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].name == 'siteId'`\">\n \n\n\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1854.968864440918,
+ "y": 808.5041785240173,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "cef8d9d4.a847d8"
+ ]
+ ]
+ },
+ {
+ "id": "cef8d9d4.a847d8",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 2031.9688835144043,
+ "y": 811.5040187835693,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "57774070.165c4"
+ ]
+ ]
+ },
+ {
+ "id": "26765522.97752a",
+ "type": "set",
+ "name": "set prop.attach.siteId",
+ "xml": "<set>\n<parameter name='prop.attach.siteId' value='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].value`' />\n",
+ "comments": "",
+ "x": 2415.9693908691406,
+ "y": 785.5040702819824,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "57774070.165c4",
+ "type": "block",
+ "name": "block : atomic",
+ "xml": "<block atomic=\"true\">",
+ "atomic": "true",
+ "outputs": 1,
+ "x": 2191.2190742492676,
+ "y": 807.0040588378906,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "26765522.97752a",
+ "18aa70c2.f51f1f",
+ "95fdece9.83f56",
+ "13d1a87e.cc7dd8"
+ ]
+ ]
+ },
+ {
+ "id": "41a8aff.133475",
+ "type": "get-resource",
+ "name": "get-resource esr-thirdparty-sdnc",
+ "xml": "<get-resource plugin=\"org.onap.ccsdk.sli.adaptors.aai.AAIService\" \n\t\tresource=\"esr-thirdparty-sdnc\" \n\t\tkey=\"esr-thirdparty-sdnc.thirdparty-sdnc-id = SDWANController AND \n\t\t depth = '1'\"\n pfx='tmp.aai.esr-thirdparty-sdnc' local-only='false' >\n\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 526.7182235717773,
+ "y": 944.5039968490601,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "9e1e759b.490ef8",
+ "587c1d85.98e364",
+ "1fecffb3.fdfc1"
+ ]
+ ]
+ },
+ {
+ "id": "9e1e759b.490ef8",
+ "type": "success",
+ "name": "success",
+ "xml": "<outcome value='success'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 770.7182846069336,
+ "y": 908.5039968490601,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "1eeec00d.ea37e"
+ ]
+ ]
+ },
+ {
+ "id": "587c1d85.98e364",
+ "type": "not-found",
+ "name": "not-found",
+ "xml": "<outcome value='not-found'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 773.2091674804688,
+ "y": 944.0780334472656,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "f1f9240f.1bbe98"
+ ]
+ ]
+ },
+ {
+ "id": "1fecffb3.fdfc1",
+ "type": "other",
+ "name": "other",
+ "xml": "<outcome value='Other'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 768.5421752929688,
+ "y": 980.4113922119141,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "e9937b5c.1de1c8"
+ ]
+ ]
+ },
+ {
+ "id": "e9937b5c.1de1c8",
+ "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=\"`'Unexpected error occurred while querying esr-thirdparty-sdnc from AnAI with thirdparty-sdnc-id = ' + $tmp.thirdparty-sdnc-id`\" />\n\n",
+ "comments": "",
+ "x": 922.3146667480469,
+ "y": 977.8504791259766,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "f1f9240f.1bbe98",
+ "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=\"`'An error occurred while querying esr-thirdparty-sdnc from AnAI with thirdparty-sdnc-id = ' + $tmp.thirdparty-sdnc-id`\" />\n\n",
+ "comments": "",
+ "x": 918.7805633544922,
+ "y": 942.3637208938599,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "1eeec00d.ea37e",
+ "type": "set",
+ "name": "set controller data",
+ "xml": "<set>\n<parameter name='prop.sdncRestApi.thirdpartySdnc.url' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].service-url`\" />\n<parameter name='prop.sdncRestApi.thirdpartySdnc.user' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].user-name`\" />\n<parameter name='prop.sdncRestApi.thirdpartySdnc.password' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].password`\" />\n",
+ "comments": "",
+ "x": 931.2183952331543,
+ "y": 906.5039367675781,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "bf4ca0a0.f719b",
+ "type": "execute",
+ "name": "execute RestApiCallNode Get token",
+ "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/actokentemplate.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/v2/tokens'`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"token-result\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>",
+ "comments": "",
+ "outputs": 1,
+ "x": 540.6564559936523,
+ "y": 1047.62509059906,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "d05110e4.15f05",
+ "623a881a.ebe538"
+ ]
+ ]
+ },
+ {
+ "id": "d05110e4.15f05",
+ "type": "success",
+ "name": "success",
+ "xml": "<outcome value='success'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 775.6565818786621,
+ "y": 1033.6250791549683,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "adf2584e.694ce8"
+ ]
+ ]
+ },
+ {
+ "id": "623a881a.ebe538",
+ "type": "failure",
+ "name": "failure",
+ "xml": "<outcome value='failure'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 774.9065818786621,
+ "y": 1069.2679862976074,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "e8c30ab5.68d3b8"
+ ]
+ ]
+ },
+ {
+ "id": "e8c30ab5.68d3b8",
+ "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 executing get token rest api\" />\n",
+ "comments": "",
+ "x": 923.6565895080566,
+ "y": 1070.0180683135986,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "adf2584e.694ce8",
+ "type": "set",
+ "name": "set token-id",
+ "xml": "<set>\n<parameter name='prop.sdncRestApi.token_id' value='`$token-result.data.token_id`' />\n",
+ "comments": "",
+ "x": 917.6565895080566,
+ "y": 1032.6250801086426,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "96f47da7.f3275",
+ "type": "execute",
+ "name": "execute RestApiCallNode device port create",
+ "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/sdlan-port.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/net/ports'`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"portResp\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />",
+ "comments": "",
+ "outputs": 1,
+ "x": 566.7455520629883,
+ "y": 1199.0782289505005,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "50af67d.1491698",
+ "bef4965a.55b458"
+ ]
+ ]
+ },
+ {
+ "id": "50af67d.1491698",
+ "type": "success",
+ "name": "success",
+ "xml": "<outcome value='success'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 815.7456111907959,
+ "y": 1213.0784349441528,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "b4a513b9.d44d6"
+ ]
+ ]
+ },
+ {
+ "id": "bef4965a.55b458",
+ "type": "failure",
+ "name": "failure",
+ "xml": "<outcome value='failure'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 815.7456111907959,
+ "y": 1175.0782704353333,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "d695c8db.015488"
+ ]
+ ]
+ },
+ {
+ "id": "d695c8db.015488",
+ "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 executing Create device port rest api\" />\n",
+ "comments": "",
+ "x": 959.7459449768066,
+ "y": 1174.078269958496,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "b4a513b9.d44d6",
+ "type": "block",
+ "name": "block : atomic",
+ "xml": "<block atomic=\"true\">",
+ "atomic": "true",
+ "comments": "",
+ "outputs": 1,
+ "x": 962.7456226348877,
+ "y": 1214.0782737731934,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ []
+ ]
+ },
+ {
+ "id": "bad651b2.12a17",
+ "type": "set",
+ "name": "set prop.lan.devicePortId",
+ "xml": "<set>\n<parameter name='prop.lan.devicePortId' value='`$portResp.success[0].id`' />\n",
+ "comments": "",
+ "x": 509.4028129577637,
+ "y": 1252.1794338226318,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "1d5fca27.3bbea6",
+ "type": "comment",
+ "name": "Create port",
+ "info": "",
+ "comments": "",
+ "x": 468.41149139404297,
+ "y": 1165.522253036499,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "14cdbea6.6ff3c1",
+ "type": "call",
+ "name": "call sdwan-get-tenant-auth",
+ "xml": "<call module='GENERIC-RESOURCE-API' rpc='sdwan-get-tenant-auth' mode='sync' >\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 515.411491394043,
+ "y": 1114.1886892318726,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ []
+ ]
+ },
+ {
+ "id": "f52cabac.abeb68",
+ "type": "execute",
+ "name": "execute RestApiCallNode bridge domain create",
+ "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/sdlan-bridge-domain.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/overlay-network/bridge-domains'`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"bridgeDomainResp\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />",
+ "comments": "",
+ "outputs": 1,
+ "x": 989.3958015441895,
+ "y": 1294.188857793808,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "441eed4c.baf224",
+ "fa3f1c96.1fc6d"
+ ]
+ ]
+ },
+ {
+ "id": "441eed4c.baf224",
+ "type": "success",
+ "name": "success",
+ "xml": "<outcome value='success'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1310.3958282470703,
+ "y": 1311.1891782283783,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "a63cb83c.98c9e8"
+ ]
+ ]
+ },
+ {
+ "id": "fa3f1c96.1fc6d",
+ "type": "failure",
+ "name": "failure",
+ "xml": "<outcome value='failure'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1313.3958549499512,
+ "y": 1276.1889598369598,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "421c7bf9.398d94"
+ ]
+ ]
+ },
+ {
+ "id": "421c7bf9.398d94",
+ "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 executing Create bridge domain rest api\" />\n",
+ "comments": "",
+ "x": 1516.3962440490723,
+ "y": 1272.1890671253204,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "a63cb83c.98c9e8",
+ "type": "block",
+ "name": "block : atomic",
+ "xml": "<block atomic=\"true\">",
+ "atomic": "true",
+ "comments": "",
+ "outputs": 1,
+ "x": 1517.395809173584,
+ "y": 1307.1889336109161,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ []
+ ]
+ },
+ {
+ "id": "7044fc7.42f8204",
+ "type": "comment",
+ "name": "Create bridge domain",
+ "info": "",
+ "comments": "",
+ "x": 933.061695098877,
+ "y": 1260.6330835819244,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "a66a0a0e.fef0c8",
+ "type": "switchNode",
+ "name": "switch portSwitch",
+ "xml": "<switch test=\"`$prop.lan.portSwitch == 'layer2-port'`\">\n\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 489.17326736450195,
+ "y": 1295.855489730835,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "cc6612da.43a9"
+ ]
+ ]
+ },
+ {
+ "id": "cc6612da.43a9",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 668.1732978820801,
+ "y": 1295.966812133789,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "f52cabac.abeb68"
+ ]
+ ]
+ },
+ {
+ "id": "f2a2fd31.6afea",
+ "type": "execute",
+ "name": "execute split ip and mask",
+ "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='split' >\n<parameter name=\"original_string\" value='`$prop.lan.ipAddress`'/>\n<parameter name=\"regex\" value=\"/\"/>\n<parameter name=\"ctx_memory_result_key\" value=\"ipandMask\"/>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 513.71826171875,
+ "y": 1395.7540397644043,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "c87ddd20.90349",
+ "aaf35528.c457d8"
+ ]
+ ]
+ },
+ {
+ "id": "aaf35528.c457d8",
+ "type": "failure",
+ "name": "success",
+ "xml": "<outcome value='success'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 714.7182807922363,
+ "y": 1373.7540311813354,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "f3c46122.a1ec5"
+ ]
+ ]
+ },
+ {
+ "id": "c87ddd20.90349",
+ "type": "failure",
+ "name": "failure",
+ "xml": "<outcome value='failure'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 714.7182846069336,
+ "y": 1414.7540349960327,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "3701541a.3aea9c"
+ ]
+ ]
+ },
+ {
+ "id": "f3c46122.a1ec5",
+ "type": "set",
+ "name": "set ipAddress prefixLength",
+ "xml": "<set>\n<parameter name='prop.lan.ip-address' value='`$ipandMask[0]`' />\n<parameter name='prop.lan.prefixLength' value='`$ipandMask[1]`' />",
+ "comments": "",
+ "x": 911.7182998657227,
+ "y": 1371.7540311813354,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "3701541a.3aea9c",
+ "type": "returnFailure",
+ "name": "return failure",
+ "xml": "<return status='failure'>\n<parameter name='error-code' value='' />\n<parameter name='error-message' value=\"An error occured while splitting sna1_route\" />\n",
+ "comments": "",
+ "x": 869.7182922363281,
+ "y": 1411.7540340423584,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "6cdf4550.c744bc",
+ "type": "comment",
+ "name": "Create wan port",
+ "info": "",
+ "comments": "",
+ "x": 486.7281379699707,
+ "y": 1348.7640895843506,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "2701cb4.59cff34",
+ "type": "comment",
+ "name": "TODO: split ip/mask",
+ "info": "",
+ "comments": "",
+ "x": 910.7279319763184,
+ "y": 1333.9343032836914,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "7299f238.fa9f1c",
+ "type": "execute",
+ "name": "execute RestApiCallNode IPSubnets create",
+ "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/sdlan-ip-subnets.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/overlay-network/ip-subnets'`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"lanPortResp\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />",
+ "comments": "",
+ "outputs": 1,
+ "x": 572.489631652832,
+ "y": 1471.8749294281006,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "fe753b01.7a4008",
+ "c50acfa.66a383"
+ ]
+ ]
+ },
+ {
+ "id": "c50acfa.66a383",
+ "type": "failure",
+ "name": "failure",
+ "xml": "<outcome value='failure'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 841.4896621704102,
+ "y": 1458.8749017715454,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "da685c50.c0fca"
+ ]
+ ]
+ },
+ {
+ "id": "fe753b01.7a4008",
+ "type": "success",
+ "name": "success",
+ "xml": "<outcome value='success'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 838.4896354675293,
+ "y": 1493.8751201629639,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "7c874cb1.b7ec64"
+ ]
+ ]
+ },
+ {
+ "id": "da685c50.c0fca",
+ "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 executing Create device port rest api\" />\n",
+ "comments": "",
+ "x": 994.4900436401367,
+ "y": 1454.8751277923584,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "7c874cb1.b7ec64",
+ "type": "block",
+ "name": "block : atomic",
+ "xml": "<block atomic=\"true\">",
+ "atomic": "true",
+ "comments": "",
+ "outputs": 1,
+ "x": 985.489616394043,
+ "y": 1494.8748760223389,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "220d830a.a3737c"
+ ]
+ ]
+ },
+ {
+ "id": "220d830a.a3737c",
+ "type": "set",
+ "name": "set prop.lan.lanPortId",
+ "xml": "<set>\n<parameter name='prop.lan.lanPortId' value='`lanPortResp.success[0].id`' />\n",
+ "comments": "",
+ "x": 1192.378719329834,
+ "y": 1497.208342552185,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "1e3434c6.db511b",
+ "type": "execute",
+ "name": "execute RestApiCallNode create vpn topology",
+ "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/sdwan-vpn-topology.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/overlay-network/' + $prop.vpn1Id + '/topology'`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"put\"/>\n<parameter name=\"responsePrefix\" value=\"vpn-result\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />",
+ "comments": "",
+ "outputs": 1,
+ "x": 598.0000534057617,
+ "y": 1630.333706855774,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "dad634fb.8374a8",
+ "222fdfc3.31cbd"
+ ]
+ ]
+ },
+ {
+ "id": "222fdfc3.31cbd",
+ "type": "success",
+ "name": "success",
+ "xml": "<outcome value='success'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 836.9999675750732,
+ "y": 1677.333193898201,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "a113b13a.6f74c"
+ ]
+ ]
+ },
+ {
+ "id": "a113b13a.6f74c",
+ "type": "block",
+ "name": "block : atomic",
+ "xml": "<block atomic=\"true\">",
+ "atomic": "true",
+ "comments": "",
+ "outputs": 1,
+ "x": 1006.999906539917,
+ "y": 1680.333193898201,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ []
+ ]
+ },
+ {
+ "id": "66af30b.a74d8d",
+ "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 executing Create vpn topology failed\" />\n",
+ "comments": "",
+ "x": 1007.0000286102295,
+ "y": 1636.333193898201,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "dad634fb.8374a8",
+ "type": "failure",
+ "name": "failure",
+ "xml": "<outcome value='failure'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 839.999906539917,
+ "y": 1636.333193898201,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "66af30b.a74d8d"
+ ]
+ ]
+ },
+ {
+ "id": "e4f03070.b443a",
+ "type": "execute",
+ "name": "execute RestApiCallNode create vpn ",
+ "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/sdwan-vpn.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/overlay-network/vpn'`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"put\"/>\n<parameter name=\"responsePrefix\" value=\"vpn-result\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />",
+ "comments": "",
+ "outputs": 1,
+ "x": 559.9984092712402,
+ "y": 1561.8328762054443,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "93f9856d.ae6458",
+ "98bd094d.9d68c8"
+ ]
+ ]
+ },
+ {
+ "id": "98bd094d.9d68c8",
+ "type": "success",
+ "name": "success",
+ "xml": "<outcome value='success'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 780.99831199646,
+ "y": 1583.8328419923782,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "54c36251.c8076c"
+ ]
+ ]
+ },
+ {
+ "id": "54c36251.c8076c",
+ "type": "block",
+ "name": "block : atomic",
+ "xml": "<block atomic=\"true\">",
+ "atomic": "true",
+ "comments": "",
+ "outputs": 1,
+ "x": 950.9982509613037,
+ "y": 1586.8328419923782,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ []
+ ]
+ },
+ {
+ "id": "719bdb7c.5a10b4",
+ "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 executing Create vpn failed\" />\n",
+ "comments": "",
+ "x": 950.9983730316162,
+ "y": 1542.8328419923782,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "93f9856d.ae6458",
+ "type": "failure",
+ "name": "failure",
+ "xml": "<outcome value='failure'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 783.9982509613037,
+ "y": 1542.8328419923782,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "719bdb7c.5a10b4"
+ ]
+ ]
+ },
+ {
+ "id": "cdd2e071.957e3",
+ "type": "switchNode",
+ "name": "switch ActivateSDWANVpnInstance",
+ "xml": "<switch test=\"`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.request-information.request-action == 'ActivateSDWANVpnInstance'`\">\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1147.0002365112305,
+ "y": 848.3332567214966,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "f5335833.4ba238"
+ ]
+ ]
+ },
+ {
+ "id": "2141a4d0.4ed0ac",
+ "type": "block",
+ "name": "block",
+ "xml": "<block>\n",
+ "atomic": "false",
+ "comments": "",
+ "outputs": 1,
+ "x": 904.3333396911621,
+ "y": 777.3333368301392,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "566234f6.d57f8c",
+ "cdd2e071.957e3",
+ "785db3d8.98fb5c"
+ ]
+ ]
+ },
+ {
+ "id": "f5335833.4ba238",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1242.666748046875,
+ "y": 922.3333377838135,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "deda6015.73137"
+ ]
+ ]
+ },
+ {
+ "id": "deda6015.73137",
+ "type": "for",
+ "name": "for vf-modules.vf-module_length",
+ "xml": "<for index='pidx' start='0' end='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param_length`' >\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1456.916633605957,
+ "y": 923.8333144187927,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "6ef0c48a.c4e20c"
+ ]
+ ]
+ },
+ {
+ "id": "6ef0c48a.c4e20c",
+ "type": "switchNode",
+ "name": "switch vpn-id",
+ "xml": "<switch test=\"`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].name == 'vpn-id'`\">\n \n\n\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1703.9166717529297,
+ "y": 918.8333973884583,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "45631feb.4e63d"
+ ]
+ ]
+ },
+ {
+ "id": "45631feb.4e63d",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1854.6666259765625,
+ "y": 920.3333129882812,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "4fe0c915.7019d8"
+ ]
+ ]
+ },
+ {
+ "id": "4fe0c915.7019d8",
+ "type": "set",
+ "name": "set prop.vpn1Id",
+ "xml": "<set>\n<parameter name='prop.vpn1Id' value='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].value`' />\n",
+ "comments": "",
+ "x": 2028.6673736572266,
+ "y": 920.3333714008331,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "18aa70c2.f51f1f",
+ "type": "set",
+ "name": "Add sites to list and update length",
+ "xml": "<set>\n<parameter name='prop.siteIds[$prop.siteIds_length]' value='`$prop.attach.siteId`' />\n<parameter name='prop.siteIds_length' value='`$prop.siteIds_length + 1`' />\n\n\n\n\n\n\n\n\n\n\n\n\n\n",
+ "comments": "",
+ "x": 2459.000747680664,
+ "y": 826.3333714008331,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "95fdece9.83f56",
+ "type": "set",
+ "name": "Add site attachement to list and update length",
+ "xml": "<set>\n<parameter name='prop.siteAttachements[$prop.siteAttachements_length].siteId' value='`$prop.attach.siteId`' />\n<parameter name='prop.siteAttachements[$prop.siteAttachements_length].roles[0]' value='`$prop.role`' />\n<parameter name='prop.siteAttachements[$prop.siteAttachements_length].roles_length' value='1' />\n<parameter name='prop.siteAttachements_length' value='`$prop.siteAttachements_length + 1`' />\n\n\n\n\n\n\n\n\n\n\n\n\n",
+ "comments": "",
+ "x": 2490.0006408691406,
+ "y": 869.3333377838135,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "11a6133a.d1ed1d",
+ "type": "set",
+ "name": "set prop.siteAttachement_length=0",
+ "xml": "<set>\n<parameter name='prop.siteAttachements_length' value='0' />\n<parameter name='prop.siteIds_length' value='0' />\n\n\n\n",
+ "comments": "",
+ "x": 576.0000152587891,
+ "y": 574.333330154419,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "78c531f9.c452d",
+ "type": "block",
+ "name": "block atomic",
+ "xml": "<block atomic=\"true\">\n",
+ "atomic": "false",
+ "comments": "",
+ "outputs": 1,
+ "x": 1689.3336715698242,
+ "y": 802.3333358764648,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "78502254.1e1d1c",
+ "63d66e16.071a8",
+ "5671530f.b2ba5c"
+ ]
+ ]
+ },
+ {
+ "id": "63d66e16.071a8",
+ "type": "switchNode",
+ "name": "switch role",
+ "xml": "<switch test=\"`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].name == 'role'`\">\n \n\n\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1851.666603088379,
+ "y": 733.3333349227905,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "5896f487.b2b6fc"
+ ]
+ ]
+ },
+ {
+ "id": "5896f487.b2b6fc",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 2014.6666069030762,
+ "y": 728.3333358764648,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "21c68e35.ea4b92"
+ ]
+ ]
+ },
+ {
+ "id": "21c68e35.ea4b92",
+ "type": "block",
+ "name": "block : atomic",
+ "xml": "<block atomic=\"true\">",
+ "atomic": "true",
+ "outputs": 1,
+ "x": 2182.666648864746,
+ "y": 722.3333339691162,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "c62b7f98.336c5",
+ "2c113cab.56e434",
+ "c2240666.9ee948"
+ ]
+ ]
+ },
+ {
+ "id": "2c113cab.56e434",
+ "type": "switchNode",
+ "name": "switch sd-wan-edge",
+ "xml": "<switch test=\"`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].value == 'sd-wan-edge'`\">\n\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 2377.666778564453,
+ "y": 683.3333253860474,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "ba2b297.cd792d8"
+ ]
+ ]
+ },
+ {
+ "id": "c62b7f98.336c5",
+ "type": "switchNode",
+ "name": "switch dsvpn-hub",
+ "xml": "<switch test=\"`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].name == 'dsvpn-hub'`\">\n \n\n\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 2374.6668853759766,
+ "y": 738.333340883255,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "f4f54567.510e38"
+ ]
+ ]
+ },
+ {
+ "id": "8ed96cca.37dc4",
+ "type": "set",
+ "name": "set spoke role",
+ "xml": "<set>\n<parameter name='prop.role' value=\"spoke\" />\n",
+ "comments": "",
+ "x": 2707.6669006347656,
+ "y": 677.3333711624146,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "4cf4d59c.e1707c",
+ "type": "set",
+ "name": "set hub role",
+ "xml": "<set>\n<parameter name='prop.role' value=\"hub\" />\n",
+ "comments": "",
+ "x": 2706.666660308838,
+ "y": 732.3333549499512,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "ba2b297.cd792d8",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 2547.666748046875,
+ "y": 679,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "8ed96cca.37dc4"
+ ]
+ ]
+ },
+ {
+ "id": "f4f54567.510e38",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 2551.666748046875,
+ "y": 734,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ [
+ "4cf4d59c.e1707c"
+ ]
+ ]
+ },
+ {
+ "id": "56401cb0.1f0164",
+ "type": "update",
+ "name": "update SDWAN VPN status to AAI",
+ "xml": "<update plugin='org.onap.ccsdk.sli.adaptors.aai.AAIService' resource='lan-port-config' \n key='sdwan-vpn.sdwan-vpn-id = $vf-module-topology-operation-input.vf-module-information.vf-module-id' >\n<parameter name='sdwan-vpn-id' value='`$vf-module-topology-operation-input.vf-module-information.vf-module-id`' />\n<parameter name='operational-status' value='Active' />\n<parameter name='lan-port-config-id' value='`$prop.lan-port-config-id`' />",
+ "comments": "",
+ "outputs": 1,
+ "x": 560.0312843322754,
+ "y": 1998.031280040741,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ []
+ ]
+ },
+ {
+ "id": "ec89c38e.b0db3",
+ "type": "set",
+ "name": "set vf-module-level-oper-status",
+ "xml": "<set>\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.vf-module-level-oper-status.order-status' value='Active' />\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.vf-module-level-oper-status.last-rpc-action' value='`$vf-module-topology-operation-input.sdnc-request-header.svc-action`' />\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.vf-module-level-oper-status.last-action' value='`$vf-module-topology-operation-input.sdnc-request-header.request-action`' />",
+ "comments": "",
+ "x": 556.6663017272949,
+ "y": 1941.1261107651517,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "233d7734.c6ad18",
+ "type": "set",
+ "name": "set vf-module-id and vf-module-object-path",
+ "xml": "<set>\n<parameter name='vf-module-object-path' value=\"`'restconf/config/GENERIC-RESOURCE-API:services/service/'\n + $vf-module-topology-operation-input.service-information.service-instance-id\n + '/service-data/vnfs/vnf/'\n + $service-data.vnfs.vnf[$vnf-index].vnf-id\n + '/vnf-data/vf-modules/vf-module/'\n + $vf-module-topology-operation-input.vf-module-information.vf-module-id\n + '/vf-module-data/vf-module-topology/'`\"/>\n<parameter name='vnf-object-path'\n value=\"`'restconf/config/GENERIC-RESOURCE-API:services/service/'\n + $vf-module-topology-operation-input.service-information.service-instance-id\n + '/service-data/vnfs/vnf/'\n + $service-data.vnfs.vnf[$vnf-index].vnf-id\n + '/vnf-data/vnf-topology/'`\"/>\n<parameter name='service-object-path'\n value=\"`'restconf/config/GENERIC-RESOURCE-API:services/service/'\n + $vf-module-topology-operation-input.service-information.service-instance-id\n + '/service-data/service-topology/'`\"/>\n",
+ "comments": "",
+ "x": 590.6663017272949,
+ "y": 1892.6261098114774,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "6bb3e148.a2b06",
+ "type": "set",
+ "name": "copy input data in service-data",
+ "xml": "<set>\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.sdnc-request-header.' value='`$vf-module-topology-operation-input.sdnc-request-header.`' />\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.request-information.' value='`$vf-module-topology-operation-input.request-information.`' />\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.service-information.' value='`$vf-module-topology-operation-input.service-information.`' />\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.vf-module-information.' value='`$vf-module-topology-operation-input.vf-module-information.`' />\n",
+ "comments": "",
+ "x": 554.6662559509277,
+ "y": 1844.876064300537,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "307480f2.c3f12",
+ "type": "set",
+ "name": "set device PortId to service data",
+ "xml": "<set>\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param_length].name' value='devicePortId' />\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param_length].value' value='`$prop.lan.devicePortId`' />\n",
+ "comments": "",
+ "x": 561.031322479248,
+ "y": 1738.0314636230469,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "cfe4c928.772628",
+ "type": "set",
+ "name": "set lan PortId to service data",
+ "xml": "<set>\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param_length].name' value='lanPortId' />\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param_length].value' value='`$prop.lan.lanPortId`' />\n",
+ "comments": "",
+ "x": 547.0312461853027,
+ "y": 1792.0312767028809,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ },
+ {
+ "id": "13d1a87e.cc7dd8",
+ "type": "record",
+ "name": "record",
+ "xml": "<record plugin=\"org.onap.ccsdk.sli.core.sli.recording.FileRecorder\">\n<parameter name=\"file\" value=\"/opt/opendaylight/current/data/log/svclogic21.log\"/>\n<parameter name=\"field1\" value=\"__TIMESTAMP__\"/>\n<parameter name=\"field2\" value=\"prop.attach.siteId\"/>\n<parameter name=\"field3\" value='`$prop.attach.siteId`'/>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 2384.0313873291016,
+ "y": 914.5312805175781,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ []
+ ]
+ },
+ {
+ "id": "c2240666.9ee948",
+ "type": "record",
+ "name": "record",
+ "xml": "<record plugin=\"org.onap.ccsdk.sli.core.sli.recording.FileRecorder\">\n<parameter name=\"file\" value=\"/opt/opendaylight/current/data/log/svclogic22.log\"/>\n<parameter name=\"field1\" value=\"__TIMESTAMP__\"/>\n<parameter name=\"field2\" value=\"set spoke role\"/>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 2353.0313987731934,
+ "y": 645.531247138977,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ []
+ ]
+ },
+ {
+ "id": "5671530f.b2ba5c",
+ "type": "record",
+ "name": "record",
+ "xml": "<record plugin=\"org.onap.ccsdk.sli.core.sli.recording.FileRecorder\">\n<parameter name=\"file\" value=\"/opt/opendaylight/current/data/log/svclogic23.log\"/>\n<parameter name=\"field1\" value=\"__TIMESTAMP__\"/>\n<parameter name=\"field2\" value=\"param-name\"/>\n<parameter name=\"field3\" value='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].name`'/>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1847.03125,
+ "y": 677.53125,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ []
+ ]
+ },
+ {
+ "id": "785db3d8.98fb5c",
+ "type": "record",
+ "name": "record",
+ "xml": "<record plugin=\"org.onap.ccsdk.sli.core.sli.recording.FileRecorder\">\n<parameter name=\"file\" value=\"/opt/opendaylight/current/data/log/svclogic24.log\"/>\n<parameter name=\"field1\" value=\"__TIMESTAMP__\"/>\n<parameter name=\"field2\" value=\"request-action\"/>\n<parameter name=\"field3\" value='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.request-information.request-action`'/>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1096.03125,
+ "y": 686.53125,
+ "z": "2f0cf160.dc107e",
+ "wires": [
+ []
+ ]
+ },
+ {
+ "id": "bacdcf2a.07a41",
+ "type": "comment",
+ "name": "**revert the changes",
+ "info": "",
+ "comments": "",
+ "x": 1248.0312767028809,
+ "y": 683.0312824249268,
+ "z": "2f0cf160.dc107e",
+ "wires": []
+ }
+]
\ No newline at end of file diff --git a/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-vf-operation-lanport-create.json b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-vf-operation-lanport-create.json new file mode 100644 index 00000000..b4f838d0 --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-vf-operation-lanport-create.json @@ -0,0 +1,533 @@ +[
+ {
+ "id": "3d343d97.916e12",
+ "type": "method",
+ "name": "sdwan-vf-operation-lanport-create",
+ "xml": "<method rpc='sdwan-vf-operation-lanport-create' mode='sync'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 285,
+ "y": 241.99999237060547,
+ "z": "be7b9c9c.26b5d",
+ "wires": [
+ [
+ "72bd87e4.7210f8"
+ ]
+ ]
+ },
+ {
+ "id": "72bd87e4.7210f8",
+ "type": "block",
+ "name": "block : atomic",
+ "xml": "<block atomic=\"true\">\n",
+ "atomic": "false",
+ "comments": "",
+ "outputs": 1,
+ "x": 444.99999237060547,
+ "y": 374.9999885559082,
+ "z": "be7b9c9c.26b5d",
+ "wires": [
+ [
+ "fa08bbfd.f36978",
+ "662c5c91.bf14f4",
+ "3a8662b6.7187de",
+ "d0f313c6.a0ddd",
+ "87f25b72.4b1968",
+ "c96f1257.64bf8",
+ "9ca9880e.f474f8",
+ "23949443.ee4acc",
+ "64302671.d03c08",
+ "305a60f0.cd87a",
+ "17d1be09.26b4d2",
+ "8ab4415a.f464b",
+ "b65f8656.be0f98",
+ "8944476b.d5f828"
+ ]
+ ]
+ },
+ {
+ "id": "78ad706e.d12e1",
+ "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": 286,
+ "y": 141.99999237060547,
+ "z": "be7b9c9c.26b5d",
+ "wires": [
+ [
+ "3d343d97.916e12"
+ ]
+ ]
+ },
+ {
+ "id": "7c5370ed.0ab17",
+ "type": "dgstart",
+ "name": "DGSTART",
+ "outputs": 1,
+ "x": 115.5,
+ "y": 53,
+ "z": "be7b9c9c.26b5d",
+ "wires": [
+ [
+ "78ad706e.d12e1"
+ ]
+ ]
+ },
+ {
+ "id": "fa08bbfd.f36978",
+ "type": "for",
+ "name": "for loop idx - VF input parameters",
+ "xml": "<for index=\"idx\" start=\"0\" end=\"`$vf-module-topology-operation-input.vf-module-request-input.vf-module-input-parameters.param_length`\">\n\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 791.2501525878906,
+ "y": 357.66665744781494,
+ "z": "be7b9c9c.26b5d",
+ "wires": [
+ [
+ "c93f649f.0099c8"
+ ]
+ ]
+ },
+ {
+ "id": "c93f649f.0099c8",
+ "type": "block",
+ "name": "block",
+ "xml": "<block>\n",
+ "atomic": "false",
+ "comments": "",
+ "outputs": 1,
+ "x": 1006.0284957885742,
+ "y": 355.22224140167236,
+ "z": "be7b9c9c.26b5d",
+ "wires": [
+ [
+ "8f744d78.f7a31",
+ "7468dc64.d34424"
+ ]
+ ]
+ },
+ {
+ "id": "8f744d78.f7a31",
+ "type": "execute",
+ "name": "execute split parameterName",
+ "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='split' >\n<parameter name=\"original_string\" value='`$vf-module-topology-operation-input.vf-module-request-input.vf-module-input-parameters.param[$idx].name`'/>\n<parameter name=\"regex\" value=\"_\"/>\n<parameter name=\"ctx_memory_result_key\" value=\"param-prefix\"/>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1202.2846984863281,
+ "y": 332.97037982940674,
+ "z": "be7b9c9c.26b5d",
+ "wires": [
+ []
+ ]
+ },
+ {
+ "id": "7468dc64.d34424",
+ "type": "set",
+ "name": "set parameterName",
+ "xml": "<set>\n<parameter name=\"`vf-module-topology-operation-input.vf-module-request-input.vf-module-input-parameters.param[$idx].name`\" value='`$param-prefix[$param-prefix_length -1]`'/>\n",
+ "comments": "",
+ "x": 1171.7291259765625,
+ "y": 369.97049617767334,
+ "z": "be7b9c9c.26b5d",
+ "wires": []
+ },
+ {
+ "id": "143889df.349216",
+ "type": "comment",
+ "name": "Take the parameter names by removing prefix",
+ "info": "",
+ "comments": "",
+ "x": 829.2503547668457,
+ "y": 314.3333249092102,
+ "z": "be7b9c9c.26b5d",
+ "wires": []
+ },
+ {
+ "id": "3a8662b6.7187de",
+ "type": "set",
+ "name": "set new vf-module_length",
+ "xml": "<set>\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module_length' value='`$vf-index + 1`' />",
+ "comments": "",
+ "x": 770.186767578125,
+ "y": 516.1629304885864,
+ "z": "be7b9c9c.26b5d",
+ "wires": []
+ },
+ {
+ "id": "662c5c91.bf14f4",
+ "type": "set",
+ "name": "set vf-module-request-input.",
+ "xml": "<set>\n<parameter name='vf-module-request-input.' value='`$vf-module-topology-operation-input.vf-module-request-input.`' />\n",
+ "comments": "",
+ "x": 770.1862945556641,
+ "y": 462.15421867370605,
+ "z": "be7b9c9c.26b5d",
+ "wires": []
+ },
+ {
+ "id": "64302671.d03c08",
+ "type": "set",
+ "name": "copy input data to service data",
+ "xml": "<set>\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-index].vf-module-id' value='`$prop.lan-vf-index`' />\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-index].vf-module-data.sdnc-request-header.' value='`$vf-module-topology-operation-input.sdnc-request-header.`' />\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-index].vf-module-data.request-information.' value='`$vf-module-topology-operation-input.request-information.`' />\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-index].vf-module-data.service-information.' value='`$vf-module-topology-operation-input.service-information.`' />\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-index].vf-module-data.vnf-information.' value='`$vf-module-topology-operation-input.vnf-information.`' />\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-index].vf-module-data.vf-module-information.' value='`$vf-module-topology-operation-input.vf-module-information.`' />\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-index].vf-module-data.vf-module-request-input.' value='`$vf-module-topology-operation-input.vf-module-request-input.`' />\n\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-index].vf-module-data.vf-module-topology.' value='`$tmp.vf-module-topology.`' />\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module_length' value='`$vf-index+1`' />\n",
+ "comments": "",
+ "x": 782.3531112670898,
+ "y": 624.3335423469543,
+ "z": "be7b9c9c.26b5d",
+ "wires": []
+ },
+ {
+ "id": "23949443.ee4acc",
+ "type": "execute",
+ "name": "execute generate-vf-module-index",
+ "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliPluginUtils' method='generateUUID' >\n<parameter name=\"ctx-destination\" value=\"prop.lan-vf-index\"/>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 794.6866760253906,
+ "y": 570.0002617835999,
+ "z": "be7b9c9c.26b5d",
+ "wires": [
+ []
+ ]
+ },
+ {
+ "id": "305a60f0.cd87a",
+ "type": "set",
+ "name": "set vf-module-object-path",
+ "xml": "<set>\n<parameter name='vf-module-object-path' value=\"`'restconf/config/GENERIC-RESOURCE-API:services/service/'\n + $vf-module-topology-operation-input.service-information.service-instance-id\n + '/service-data/vnfs/vnf/'\n + $service-data.vnfs.vnf[$vnf-index].vnf-id\n + '/vnf-data/vf-modules/vf-module/'\n + $vf-module-topology-operation-input.vf-module-information.vf-module-id\n + '/vf-module-data/vf-module-topology/'`\"/>\n<parameter name='vnf-object-path'\n value=\"`'restconf/config/GENERIC-RESOURCE-API:services/service/'\n + $vf-module-topology-operation-input.service-information.service-instance-id\n + '/service-data/vnfs/vnf/'\n + $service-data.vnfs.vnf[$vnf-index].vnf-id\n + '/vnf-data/vnf-topology/'`\"/>\n<parameter name='service-object-path'\n value=\"`'restconf/config/GENERIC-RESOURCE-API:services/service/'\n + $vf-module-topology-operation-input.service-information.service-instance-id\n + '/service-data/service-topology/'`\"/>\n",
+ "comments": "",
+ "x": 770.500036239624,
+ "y": 675.8373885154724,
+ "z": "be7b9c9c.26b5d",
+ "wires": []
+ },
+ {
+ "id": "17d1be09.26b4d2",
+ "type": "set",
+ "name": "set vf-module-level-oper-status",
+ "xml": "<set>\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-index].vf-module-data.vf-module-level-oper-status.order-status' value='Created' />\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-index].vf-module-data.vf-module-level-oper-status.last-rpc-action' value='`$vf-module-topology-operation-input.sdnc-request-header.svc-action`' />\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-index].vf-module-data.vf-module-level-oper-status.last-action' value='`$vf-module-topology-operation-input.sdnc-request-header.request-action`' />",
+ "comments": "",
+ "x": 785.0000953674316,
+ "y": 725.837281703949,
+ "z": "be7b9c9c.26b5d",
+ "wires": []
+ },
+ {
+ "id": "8ab4415a.f464b",
+ "type": "save",
+ "name": "save sdwan lan-port-config resource in AAI",
+ "xml": "<save plugin='org.onap.ccsdk.sli.adaptors.aai.AAIService' resource='lan-port-config' \n key='lan-port-config.lan-port-config-id = $prop.lan-vf-index' >\n<parameter name=\"lan-port-config-id\" value=\"`$prop.vnf-index`\" />\n<parameter name=\"device-id\" value=\"`$prop.lan.deviceName`\" />\n<parameter name=\"port-switch\" value=\"`$prop.lan.portSwitch`\" />\n<parameter name=\"port-type\" value=\"`$prop.lan.portType`\" />\n<parameter name=\"port-number\" value=\"`$prop.lan.portnumber`\" />\n<parameter name=\"ipv4-address\" value=\"`$prop.lan.ipAddress`\" />\n<parameter name='vlan-tag' value=\"`$prop.lan.vlanId`\" />\n<parameter name='operational-status' value='Created' />\n<parameter name='model-customization-id' value='`$vf-module-topology-operation-input.vf-module-information.onap-model-information.model-customization-uuid`' />\n<parameter name='model-invariant-id' value='`$vf-module-topology-operation-input.vf-module-information.onap-model-information.model-invariant-uuid`' />\n<parameter name='model-version-id' value='`$vf-module-topology-operation-input.vf-module-information.onap-model-information.model-version`' />\n<parameter name='selflink' value=\"`'restconf/config/GENERIC-RESOURCE-API:services/service/' + $vf-module-topology-operation-input.service-information.service-instance-id + '/service-data/vnfs/vnf/' + $service-data.vnfs.vnf[$vnf-index].vnf-id + '/vnf-data/vf-modules/vf-module/' + $prop.site-vf-index + '/vf-module-data/'` \" />\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 817.5000152587891,
+ "y": 766.3373422622681,
+ "z": "be7b9c9c.26b5d",
+ "wires": [
+ []
+ ]
+ },
+ {
+ "id": "b65f8656.be0f98",
+ "type": "save",
+ "name": "save service relationship in AAI",
+ "xml": "<save plugin='org.onap.ccsdk.sli.adaptors.aai.AAIService' resource='generic-vnf:relationship-list' \n key='generic-vnf.vnf-id = $service-data.vnfs.vnf[$vnf-index].vnf-id' \n force=\"true\" pfx=\"tmp.AnAI-data\">\n<parameter name=\"relationship-list.relationship[0].related-to\" value=\"sdwan-vpn\" />\n<parameter name=\"relationship-list.relationship[0].related-link\" value=\"`'/network/sdwan-vpns/sdwan-vpn/' + $prop.lan-vf-index`\" />\n<parameter name=\"relationship-list.relationship[0].relationship-data[0].relationship-key\" value=\"lan-port-config-id\" />\n<parameter name=\"relationship-list.relationship[0].relationship-data[0].relationship-value\" value=\"`$prop.lan-vf-index`\" />\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 785.4999313354492,
+ "y": 815.3373589515686,
+ "z": "be7b9c9c.26b5d",
+ "wires": [
+ []
+ ]
+ },
+ {
+ "id": "8944476b.d5f828",
+ "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": 736.2224769592285,
+ "y": 862.5112180709839,
+ "z": "be7b9c9c.26b5d",
+ "wires": []
+ },
+ {
+ "id": "87f25b72.4b1968",
+ "type": "for",
+ "name": "for each vnf",
+ "xml": "<for index='idx' start='0' end='`$service-data.vnfs.vnf_length`' >\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 729,
+ "y": 165.99999713897705,
+ "z": "be7b9c9c.26b5d",
+ "wires": [
+ [
+ "e80313cd.820e4"
+ ]
+ ]
+ },
+ {
+ "id": "e80313cd.820e4",
+ "type": "switchNode",
+ "name": "switch this vnf-id == input vnf-id",
+ "xml": "<switch test=\"`$service-data.vnfs.vnf[$idx].vnf-id == $vf-module-topology-operation-input.vnf-information.vnf-id`\"> \n",
+ "comments": "",
+ "outputs": 1,
+ "x": 981.0000915527344,
+ "y": 164.6666603088379,
+ "z": "be7b9c9c.26b5d",
+ "wires": [
+ [
+ "b80badb7.d9753"
+ ]
+ ]
+ },
+ {
+ "id": "8bc04fc8.d6a11",
+ "type": "set",
+ "name": "set vnf-index",
+ "xml": "<set>\n<parameter name='vnf-index' value='`$idx`' />\n",
+ "comments": "",
+ "x": 1352.6665802001953,
+ "y": 166.66666316986084,
+ "z": "be7b9c9c.26b5d",
+ "wires": []
+ },
+ {
+ "id": "b80badb7.d9753",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1199.333408355713,
+ "y": 166.66664218902588,
+ "z": "be7b9c9c.26b5d",
+ "wires": [
+ [
+ "8bc04fc8.d6a11"
+ ]
+ ]
+ },
+ {
+ "id": "d0f313c6.a0ddd",
+ "type": "switchNode",
+ "name": "switch vnf_length",
+ "xml": "<switch test='`$service-data.vnfs.vnf_length`'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 743.4205932617188,
+ "y": 121.50386619567871,
+ "z": "be7b9c9c.26b5d",
+ "wires": [
+ [
+ "7ab34e25.1cd4e"
+ ]
+ ]
+ },
+ {
+ "id": "7ab34e25.1cd4e",
+ "type": "other",
+ "name": "NULL",
+ "xml": "<outcome value=''>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 930.087272644043,
+ "y": 120.8371639251709,
+ "z": "be7b9c9c.26b5d",
+ "wires": [
+ [
+ "984b3a64.7e1a38"
+ ]
+ ]
+ },
+ {
+ "id": "984b3a64.7e1a38",
+ "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": 1111.7538986206055,
+ "y": 120.8371639251709,
+ "z": "be7b9c9c.26b5d",
+ "wires": []
+ },
+ {
+ "id": "c96f1257.64bf8",
+ "type": "switchNode",
+ "name": "switch vf-modules.vf-module_length",
+ "xml": "<switch test='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module_length`'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 784.6705827713013,
+ "y": 241.50386714935303,
+ "z": "be7b9c9c.26b5d",
+ "wires": [
+ [
+ "ab6c63f4.e55a6",
+ "14b85aee.617c65"
+ ]
+ ]
+ },
+ {
+ "id": "ab6c63f4.e55a6",
+ "type": "other",
+ "name": "Null",
+ "xml": "<outcome value=''>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1015.6705932617188,
+ "y": 217.50386428833008,
+ "z": "be7b9c9c.26b5d",
+ "wires": [
+ [
+ "342d6918.bdf256"
+ ]
+ ]
+ },
+ {
+ "id": "14b85aee.617c65",
+ "type": "other",
+ "name": "other",
+ "xml": "<outcome value='Other'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1015.6705932617188,
+ "y": 257.5038642883301,
+ "z": "be7b9c9c.26b5d",
+ "wires": [
+ [
+ "eedb45d.e2420b8"
+ ]
+ ]
+ },
+ {
+ "id": "342d6918.bdf256",
+ "type": "set",
+ "name": "set vf-index",
+ "xml": "<set>\n<parameter name='vf-index' value='0' />\n",
+ "comments": "",
+ "x": 1158.1705932617188,
+ "y": 217.50386428833008,
+ "z": "be7b9c9c.26b5d",
+ "wires": []
+ },
+ {
+ "id": "eedb45d.e2420b8",
+ "type": "block",
+ "name": "block",
+ "xml": "<block>\n",
+ "atomic": "false",
+ "comments": "",
+ "outputs": 1,
+ "x": 1160.0276374816895,
+ "y": 257.4403762817383,
+ "z": "be7b9c9c.26b5d",
+ "wires": [
+ [
+ "a00dcbbe.533a58",
+ "7019e496.422f8c"
+ ]
+ ]
+ },
+ {
+ "id": "7019e496.422f8c",
+ "type": "set",
+ "name": "set vf-index",
+ "xml": "<set>\n<parameter name='vf-index' value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module_length`' />\n\n\n",
+ "comments": "",
+ "x": 1312.7261123657227,
+ "y": 227.05947497440502,
+ "z": "be7b9c9c.26b5d",
+ "wires": []
+ },
+ {
+ "id": "a00dcbbe.533a58",
+ "type": "for",
+ "name": "for each existing vf-index",
+ "xml": "<for index='idx' start='0' end='`$vf-index`' >\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1369.1546173095703,
+ "y": 280.2816047668457,
+ "z": "be7b9c9c.26b5d",
+ "wires": [
+ [
+ "19e6409a.9c554f"
+ ]
+ ]
+ },
+ {
+ "id": "f530bc4a.54c5c",
+ "type": "comment",
+ "name": "make sure this network doesn't exist already",
+ "info": "",
+ "comments": "",
+ "x": 1592.805347442627,
+ "y": 238.53566217422485,
+ "z": "be7b9c9c.26b5d",
+ "wires": []
+ },
+ {
+ "id": "19e6409a.9c554f",
+ "type": "switchNode",
+ "name": "switch vf-module-id found",
+ "xml": "<switch test=\"`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$idx].vf-module-id == $vf-module-topology-operation-input.vf-module-information.vf-module-id`\">\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1644.4403381347656,
+ "y": 279.8531074523926,
+ "z": "be7b9c9c.26b5d",
+ "wires": [
+ [
+ "24af0b91.ce5344"
+ ]
+ ]
+ },
+ {
+ "id": "24af0b91.ce5344",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1545.1705360412598,
+ "y": 338.4245386123657,
+ "z": "be7b9c9c.26b5d",
+ "wires": [
+ [
+ "bf4e4104.4edb"
+ ]
+ ]
+ },
+ {
+ "id": "bf4e4104.4edb",
+ "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-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$idx].vf-module-id already found in service-data\" />\n",
+ "comments": "",
+ "x": 1692.920639038086,
+ "y": 338.28173068119213,
+ "z": "be7b9c9c.26b5d",
+ "wires": []
+ },
+ {
+ "id": "9ca9880e.f474f8",
+ "type": "call",
+ "name": "call sdwan-get-vf-module-lanport-param",
+ "xml": "<call module='GENERIC-RESOURCE-API' rpc='sdwan-get-vf-module-lanport-param' mode='sync' >\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 804.0000152587891,
+ "y": 408.99999809265137,
+ "z": "be7b9c9c.26b5d",
+ "wires": [
+ []
+ ]
+ }
+]
\ No newline at end of file diff --git a/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-vf-operation-lanport-deactivate.json b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-vf-operation-lanport-deactivate.json new file mode 100644 index 00000000..cb288630 --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-vf-operation-lanport-deactivate.json @@ -0,0 +1,1847 @@ +[
+ {
+ "id": "3eaead5d.8a50e2",
+ "type": "method",
+ "name": "method sdwan-vf-operation-lanport-deactivate",
+ "xml": "<method rpc='sdwan-vf-operation-lanport-deactivate' mode='sync'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 252,
+ "y": 208,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "de2de50e.7db098"
+ ]
+ ]
+ },
+ {
+ "id": "ba6ca55d.d04268",
+ "type": "switchNode",
+ "name": "switch vf-modules.vf-module_length",
+ "xml": "<switch test='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module_length`'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 634.0000076293945,
+ "y": 359.4136486053467,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "96bd0da6.6b228",
+ "d7d04d79.b116e",
+ "bcfd0c5e.e6103"
+ ]
+ ]
+ },
+ {
+ "id": "996651b.9ec83b",
+ "type": "dgstart",
+ "name": "DGSTART",
+ "outputs": 1,
+ "x": 171.00000381469727,
+ "y": 50.413658142089844,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "509643c7.891eac"
+ ]
+ ]
+ },
+ {
+ "id": "509643c7.891eac",
+ "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": 240.28570556640625,
+ "y": 113.65176773071289,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "3eaead5d.8a50e2"
+ ]
+ ]
+ },
+ {
+ "id": "de2de50e.7db098",
+ "type": "block",
+ "name": "block : atomic",
+ "xml": "<block atomic=\"true\">",
+ "atomic": "true",
+ "outputs": 1,
+ "x": 252.6666717529297,
+ "y": 464.08036708831787,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "cd5d97be.4098b8",
+ "cc768085.ce4bc",
+ "ba6ca55d.d04268",
+ "582a5dfb.dfaf24",
+ "6331828e.70aa2c",
+ "60ca269e.96d878",
+ "ba5b2145.40753",
+ "d3ab3217.7d57a",
+ "58afb0e4.ba7df",
+ "2ee3209f.a1bb9",
+ "bfac8597.a517f8",
+ "b282b047.e838d",
+ "89ba2ad0.277798",
+ "e99d476c.3f3ac8",
+ "81163bc0.74e178",
+ "e8785c39.cc512",
+ "86da8112.f0417",
+ "2b5c8466.72828c",
+ "6c0bf23f.5303ac",
+ "16e6f83a.5e7ff8"
+ ]
+ ]
+ },
+ {
+ "id": "cc768085.ce4bc",
+ "type": "for",
+ "name": "for each vnf",
+ "xml": "<for index='idx' start='0' end='`$service-data.vnfs.vnf_length`' >\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 578.0313873291016,
+ "y": 287.6828079223633,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "9776f320.0567"
+ ]
+ ]
+ },
+ {
+ "id": "cd5d97be.4098b8",
+ "type": "switchNode",
+ "name": "switch vnf_length",
+ "xml": "<switch test='`$service-data.vnfs.vnf_length`'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 589.0000190734863,
+ "y": 226.41366863250732,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "2debc059.5aa7"
+ ]
+ ]
+ },
+ {
+ "id": "2debc059.5aa7",
+ "type": "outcome",
+ "name": "NULL",
+ "xml": "<outcome value=''>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 769,
+ "y": 225.41365814208984,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "355351ee.f9153e"
+ ]
+ ]
+ },
+ {
+ "id": "355351ee.f9153e",
+ "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=\"vnf-topology-operation-input.vnf-request-input.vnf-id not found in service-data\" />\n",
+ "comments": "",
+ "x": 918.4287261962891,
+ "y": 226.55657577514648,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ },
+ {
+ "id": "9776f320.0567",
+ "type": "switchNode",
+ "name": "switch this vnf-id == input vnf-id",
+ "xml": "<switch test=\"`$service-data.vnfs.vnf[$idx].vnf-id == $vf-module-topology-operation-input.vnf-information.vnf-id`\"> \n",
+ "comments": "",
+ "outputs": 1,
+ "x": 807.0000152587891,
+ "y": 288.4136643409729,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "f97986b6.bf7158"
+ ]
+ ]
+ },
+ {
+ "id": "f97986b6.bf7158",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1022,
+ "y": 286.41365814208984,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "926d8df9.33314"
+ ]
+ ]
+ },
+ {
+ "id": "926d8df9.33314",
+ "type": "set",
+ "name": "set vnf-index",
+ "xml": "<set>\n<parameter name='vnf-index' value='`$idx`' />\n",
+ "comments": "",
+ "x": 1186,
+ "y": 281.41365814208984,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ },
+ {
+ "id": "d7d04d79.b116e",
+ "type": "outcome",
+ "name": "NULL",
+ "xml": "<outcome value=''>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 856,
+ "y": 393.41365814208984,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "511ce89.f44bb18"
+ ]
+ ]
+ },
+ {
+ "id": "96bd0da6.6b228",
+ "type": "outcome",
+ "name": "0",
+ "xml": "<outcome value='0'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 860.9999961853027,
+ "y": 340.4136571884155,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "511ce89.f44bb18"
+ ]
+ ]
+ },
+ {
+ "id": "511ce89.f44bb18",
+ "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=\"vnf-topology-operation-input.vnf-request-input.vnf-id not found in service-data\" />\n",
+ "comments": "",
+ "x": 1019,
+ "y": 353.41365814208984,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ },
+ {
+ "id": "bcfd0c5e.e6103",
+ "type": "other",
+ "name": "other",
+ "xml": "<outcome value='Other'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 856,
+ "y": 454.41365814208984,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "b8a34756.728a58"
+ ]
+ ]
+ },
+ {
+ "id": "af4bd42d.9f4868",
+ "type": "set",
+ "name": "set vf-module_length",
+ "xml": "<set>\n<parameter name='vf-module-length' value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module_length`' />\n\n",
+ "comments": "",
+ "x": 1210.000015258789,
+ "y": 452.4136720895767,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ },
+ {
+ "id": "b8a34756.728a58",
+ "type": "block",
+ "name": "block : atomic",
+ "xml": "<block atomic=\"true\">",
+ "atomic": "true",
+ "outputs": 1,
+ "x": 1017.0000457763672,
+ "y": 451.413649559021,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "af4bd42d.9f4868",
+ "69a184fd.28972c"
+ ]
+ ]
+ },
+ {
+ "id": "69a184fd.28972c",
+ "type": "for",
+ "name": "for each existing vf-index",
+ "xml": "<for index='idx' start='0' end='`$vf-module-length`' >\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1229.0000305175781,
+ "y": 501.41367053985596,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "72e39d48.4f8944"
+ ]
+ ]
+ },
+ {
+ "id": "72e39d48.4f8944",
+ "type": "switchNode",
+ "name": "switch vf-module-id found",
+ "xml": "<switch test=\"`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$idx].vf-module-id == $vf-module-topology-operation-input.vf-module-information.vf-module-id`\">\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1472,
+ "y": 500.41365814208984,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "5f38c3e.5d3ce3c"
+ ]
+ ]
+ },
+ {
+ "id": "5f38c3e.5d3ce3c",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1670.0000286102295,
+ "y": 487.41366481781006,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "92d909cb.ff6d68"
+ ]
+ ]
+ },
+ {
+ "id": "92d909cb.ff6d68",
+ "type": "block",
+ "name": "block : atomic",
+ "xml": "<block atomic=\"true\">",
+ "atomic": "true",
+ "outputs": 1,
+ "x": 1822,
+ "y": 489.41365814208984,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "4dec85b6.3eab5c",
+ "e85d666e.e8adc8",
+ "15a9af4c.a7f031"
+ ]
+ ]
+ },
+ {
+ "id": "4dec85b6.3eab5c",
+ "type": "set",
+ "name": "set tmp.vidx and ctx.vnf-data",
+ "xml": "<set>\n<parameter name='tmp.vidx' value='`$idx`' />\n<parameter name='ctx.vf-module-data.' value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$idx].vf-module-data.`' />\n",
+ "comments": "",
+ "x": 2050.000114440918,
+ "y": 431.4136619567871,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ },
+ {
+ "id": "e85d666e.e8adc8",
+ "type": "set",
+ "name": "set vf-module-request-input.",
+ "xml": "<set>\n<parameter name='vf-module-request-input.' value='`$ctx.vf-module-data.vf-module-request-input.`' />\n\n",
+ "comments": "",
+ "x": 2054.000114440918,
+ "y": 485.4136619567871,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ },
+ {
+ "id": "582a5dfb.dfaf24",
+ "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": 553.0002136230469,
+ "y": 1926.9149341583252,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ },
+ {
+ "id": "15a9af4c.a7f031",
+ "type": "call",
+ "name": "call sdwan-get-vf-module-lanport-param",
+ "xml": "<call module='GENERIC-RESOURCE-API' rpc='sdwan-get-vf-module-lanport-param' mode='sync' >\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 2084.4551391601562,
+ "y": 536.4241542816162,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ []
+ ]
+ },
+ {
+ "id": "1adddcaf.a133d3",
+ "type": "for",
+ "name": "for vf-modules.vf-module_length",
+ "xml": "<for index='vfidx' start='0' end='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module_length`' >\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 891.2540740966797,
+ "y": 541.4176807403564,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "8d8ac8b6.f23b18"
+ ]
+ ]
+ },
+ {
+ "id": "cc689d86.6d6b1",
+ "type": "switchNode",
+ "name": "switch this deviceName == vf-input",
+ "xml": "<switch test=\"`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].value == '$prop.lan.deviceName'`\">\n \n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1164.2543182373047,
+ "y": 627.417786359787,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "ec201f5b.98b55"
+ ]
+ ]
+ },
+ {
+ "id": "8d8ac8b6.f23b18",
+ "type": "for",
+ "name": "for vf-module-input-param length",
+ "xml": "<for index='pidx' start='0' end='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param_length`' >\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1189.2539901733398,
+ "y": 544.4177227020264,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "cc689d86.6d6b1"
+ ]
+ ]
+ },
+ {
+ "id": "ec201f5b.98b55",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1378.2541313171387,
+ "y": 624.4177711009979,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "137ad5db.05e33a"
+ ]
+ ]
+ },
+ {
+ "id": "42b7ec46.f75e94",
+ "type": "for",
+ "name": "for vf-modules.vf-module_length",
+ "xml": "<for index='pidx' start='0' end='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param_length`' >\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1767.254322052002,
+ "y": 621.4179258346558,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "6fa7e982.f0f398"
+ ]
+ ]
+ },
+ {
+ "id": "6fa7e982.f0f398",
+ "type": "switchNode",
+ "name": "switch deviceId == input vf-id",
+ "xml": "<switch test=\"`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].name == 'deviceId'`\">\n \n\n\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 2059.2542114257812,
+ "y": 622.4178848266602,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "a93d7d08.b19f3"
+ ]
+ ]
+ },
+ {
+ "id": "a93d7d08.b19f3",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 2258.254379272461,
+ "y": 620.4178848266602,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "8ce50095.7309f"
+ ]
+ ]
+ },
+ {
+ "id": "8ce50095.7309f",
+ "type": "set",
+ "name": "set prop.lan.deviceId",
+ "xml": "<set>\n<parameter name='prop.lan.deviceId' value='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].value`' />\n",
+ "comments": "",
+ "x": 2431.254383087158,
+ "y": 620.4179258346558,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ },
+ {
+ "id": "6331828e.70aa2c",
+ "type": "for",
+ "name": "for service-data.vnfs.vnf_length",
+ "xml": "<for index='vnfidx' start='0' end='`$service-data.vnfs.vnf_length`' >\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 637.2539215087891,
+ "y": 476.4176778793335,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "1adddcaf.a133d3"
+ ]
+ ]
+ },
+ {
+ "id": "125425fb.ef4bfa",
+ "type": "switchNode",
+ "name": "switch ActivateSDWANSiteInstance",
+ "xml": "<!--switch test=\"`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.request-information.request-action == 'ActivateSDWANSiteInstance'`\"-->\n<switch test=\"`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.request-information.request-action == 'ActivateSiteInstance'`\">\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1232.0042877197266,
+ "y": 748.417646408081,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "7336ac27.633e24"
+ ]
+ ]
+ },
+ {
+ "id": "38f21693.f6208a",
+ "type": "for",
+ "name": "for vf-modules.vf-module_length",
+ "xml": "<for index='vfidx' start='0' end='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module_length`' >\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 765.0041732788086,
+ "y": 819.4176635742188,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "e28cdf4a.09f99"
+ ]
+ ]
+ },
+ {
+ "id": "58afb0e4.ba7df",
+ "type": "for",
+ "name": "for service-data.vnfs.vnf_length",
+ "xml": "<for index='vnfidx' start='0' end='`$service-data.vnfs.vnf_length`' >\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 629.0039825439453,
+ "y": 646.4175662994385,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "74d2892.3a20c78"
+ ]
+ ]
+ },
+ {
+ "id": "7336ac27.633e24",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1454.0042037963867,
+ "y": 748.4177279472351,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "6d31748d.e3c9bc"
+ ]
+ ]
+ },
+ {
+ "id": "6d31748d.e3c9bc",
+ "type": "for",
+ "name": "for vf-modules.vf-module_length",
+ "xml": "<for index='pidx' start='0' end='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param_length`' >\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1535.2542114257812,
+ "y": 822.9177293777466,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "7cb6a87.6e3f758"
+ ]
+ ]
+ },
+ {
+ "id": "1008121d.0f833e",
+ "type": "switchNode",
+ "name": "switch siteId",
+ "xml": "<switch test=\"`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].name == 'siteId'`\">\n \n\n\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1918.2545700073242,
+ "y": 829.9178366661072,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "7c572003.6098f"
+ ]
+ ]
+ },
+ {
+ "id": "7c572003.6098f",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 2095.2545890808105,
+ "y": 832.9176769256592,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "8daf5324.de268"
+ ]
+ ]
+ },
+ {
+ "id": "63cd961f.c156c8",
+ "type": "set",
+ "name": "set prop.attach.siteId",
+ "xml": "<set>\n<parameter name='prop.attach.siteId' value='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].value`' />\n",
+ "comments": "",
+ "x": 2479.255096435547,
+ "y": 806.9177284240723,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ },
+ {
+ "id": "8daf5324.de268",
+ "type": "block",
+ "name": "block : atomic",
+ "xml": "<block atomic=\"true\">",
+ "atomic": "true",
+ "outputs": 1,
+ "x": 2254.504779815674,
+ "y": 828.4177169799805,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "63cd961f.c156c8",
+ "4f58a0f5.56037",
+ "975b7faf.1862a"
+ ]
+ ]
+ },
+ {
+ "id": "89ba2ad0.277798",
+ "type": "get-resource",
+ "name": "get-resource esr-thirdparty-sdnc",
+ "xml": "<get-resource plugin=\"org.onap.ccsdk.sli.adaptors.aai.AAIService\" \n\t\tresource=\"esr-thirdparty-sdnc\" \n\t\tkey=\"esr-thirdparty-sdnc.thirdparty-sdnc-id = SDWANController AND \n\t\t depth = '1'\"\n pfx='tmp.aai.esr-thirdparty-sdnc' local-only='false' >\n\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 590.0039291381836,
+ "y": 965.9176549911499,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "2d233c53.3f6be4",
+ "f1938aaa.240958",
+ "46bd4734.d48208"
+ ]
+ ]
+ },
+ {
+ "id": "2d233c53.3f6be4",
+ "type": "success",
+ "name": "success",
+ "xml": "<outcome value='success'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 834.0039901733398,
+ "y": 929.9176549911499,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "157032ce.bbb88d"
+ ]
+ ]
+ },
+ {
+ "id": "f1938aaa.240958",
+ "type": "not-found",
+ "name": "not-found",
+ "xml": "<outcome value='not-found'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 836.494873046875,
+ "y": 965.4916915893555,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "4af9366b.00d608"
+ ]
+ ]
+ },
+ {
+ "id": "46bd4734.d48208",
+ "type": "other",
+ "name": "other",
+ "xml": "<outcome value='Other'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 831.827880859375,
+ "y": 1001.8250503540039,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "3961a91d.651c56"
+ ]
+ ]
+ },
+ {
+ "id": "3961a91d.651c56",
+ "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=\"`'Unexpected error occurred while querying esr-thirdparty-sdnc from AnAI with thirdparty-sdnc-id = ' + $tmp.thirdparty-sdnc-id`\" />\n\n",
+ "comments": "",
+ "x": 985.6003723144531,
+ "y": 999.2641372680664,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ },
+ {
+ "id": "4af9366b.00d608",
+ "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=\"`'An error occurred while querying esr-thirdparty-sdnc from AnAI with thirdparty-sdnc-id = ' + $tmp.thirdparty-sdnc-id`\" />\n\n",
+ "comments": "",
+ "x": 982.0662689208984,
+ "y": 963.7773790359497,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ },
+ {
+ "id": "157032ce.bbb88d",
+ "type": "set",
+ "name": "set controller data",
+ "xml": "<set>\n<parameter name='prop.sdncRestApi.thirdpartySdnc.url' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].service-url`\" />\n<parameter name='prop.sdncRestApi.thirdpartySdnc.user' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].user-name`\" />\n<parameter name='prop.sdncRestApi.thirdpartySdnc.password' value=\"`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].password`\" />\n",
+ "comments": "",
+ "x": 994.5041007995605,
+ "y": 927.917594909668,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ },
+ {
+ "id": "e99d476c.3f3ac8",
+ "type": "execute",
+ "name": "execute RestApiCallNode Get token",
+ "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/actokentemplate.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/v2/tokens'`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"token-result\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>",
+ "comments": "",
+ "outputs": 1,
+ "x": 603.9421615600586,
+ "y": 1069.03874874115,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "e801e029.f1d5a",
+ "8d93013.82561"
+ ]
+ ]
+ },
+ {
+ "id": "e801e029.f1d5a",
+ "type": "success",
+ "name": "success",
+ "xml": "<outcome value='success'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 838.9422874450684,
+ "y": 1055.038737297058,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "aaae6df9.4c056"
+ ]
+ ]
+ },
+ {
+ "id": "8d93013.82561",
+ "type": "failure",
+ "name": "failure",
+ "xml": "<outcome value='failure'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 838.1922874450684,
+ "y": 1090.6816444396973,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "5e0c2f7e.4b122"
+ ]
+ ]
+ },
+ {
+ "id": "5e0c2f7e.4b122",
+ "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 executing get token rest api\" />\n",
+ "comments": "",
+ "x": 986.9422950744629,
+ "y": 1091.4317264556885,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ },
+ {
+ "id": "aaae6df9.4c056",
+ "type": "set",
+ "name": "set token-id",
+ "xml": "<set>\n<parameter name='prop.sdncRestApi.token_id' value='`$token-result.data.token_id`' />\n",
+ "comments": "",
+ "x": 980.9422950744629,
+ "y": 1054.0387382507324,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ },
+ {
+ "id": "e8785c39.cc512",
+ "type": "execute",
+ "name": "execute RestApiCallNode device port delete",
+ "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/sdlan-port-del.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/net/ports/action/batch-delete'`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"portResp\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />",
+ "comments": "",
+ "outputs": 1,
+ "x": 630.0312576293945,
+ "y": 1220.4918870925903,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "552b4230.a57a2c",
+ "a21ab43e.f1ce68"
+ ]
+ ]
+ },
+ {
+ "id": "552b4230.a57a2c",
+ "type": "success",
+ "name": "success",
+ "xml": "<outcome value='success'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 879.0313167572021,
+ "y": 1234.4920930862427,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "d1a4e04e.60501"
+ ]
+ ]
+ },
+ {
+ "id": "a21ab43e.f1ce68",
+ "type": "failure",
+ "name": "failure",
+ "xml": "<outcome value='failure'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 879.0313167572021,
+ "y": 1196.491928577423,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "54a6d547.da0aec"
+ ]
+ ]
+ },
+ {
+ "id": "54a6d547.da0aec",
+ "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 executing Create device port rest api\" />\n",
+ "comments": "",
+ "x": 1023.0316505432129,
+ "y": 1195.491928100586,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ },
+ {
+ "id": "d1a4e04e.60501",
+ "type": "block",
+ "name": "block : atomic",
+ "xml": "<block atomic=\"true\">",
+ "atomic": "true",
+ "comments": "",
+ "outputs": 1,
+ "x": 1026.031328201294,
+ "y": 1235.4919319152832,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ []
+ ]
+ },
+ {
+ "id": "c5c8c91e.ca8b48",
+ "type": "comment",
+ "name": "Delete port",
+ "info": "",
+ "comments": "",
+ "x": 531.6971969604492,
+ "y": 1186.9359111785889,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ },
+ {
+ "id": "81163bc0.74e178",
+ "type": "call",
+ "name": "call sdwan-get-tenant-auth",
+ "xml": "<call module='GENERIC-RESOURCE-API' rpc='sdwan-get-tenant-auth' mode='sync' >\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 578.6971969604492,
+ "y": 1135.6023473739624,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ []
+ ]
+ },
+ {
+ "id": "a939bddc.25a0a",
+ "type": "execute",
+ "name": "execute RestApiCallNode bridge domain create",
+ "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/sdlan-bridge-domain.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/overlay-network/bridge-domains'`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"bridgeDomainResp\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />",
+ "comments": "",
+ "outputs": 1,
+ "x": 1052.6815071105957,
+ "y": 1315.6025159358978,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "991e6562.cad008",
+ "a675752c.fef5c8"
+ ]
+ ]
+ },
+ {
+ "id": "991e6562.cad008",
+ "type": "success",
+ "name": "success",
+ "xml": "<outcome value='success'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1373.6815338134766,
+ "y": 1332.6028363704681,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "fb3cfb9f.764a18"
+ ]
+ ]
+ },
+ {
+ "id": "a675752c.fef5c8",
+ "type": "failure",
+ "name": "failure",
+ "xml": "<outcome value='failure'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1376.6815605163574,
+ "y": 1297.6026179790497,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "92f1575b.a1bfb8"
+ ]
+ ]
+ },
+ {
+ "id": "92f1575b.a1bfb8",
+ "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 executing Create bridge domain rest api\" />\n",
+ "comments": "",
+ "x": 1579.6819496154785,
+ "y": 1293.6027252674103,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ },
+ {
+ "id": "fb3cfb9f.764a18",
+ "type": "block",
+ "name": "block : atomic",
+ "xml": "<block atomic=\"true\">",
+ "atomic": "true",
+ "comments": "",
+ "outputs": 1,
+ "x": 1580.6815147399902,
+ "y": 1328.602591753006,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ []
+ ]
+ },
+ {
+ "id": "d50d1b79.abf9a8",
+ "type": "comment",
+ "name": "Create bridge domain",
+ "info": "",
+ "comments": "",
+ "x": 996.3474006652832,
+ "y": 1282.0467417240143,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ },
+ {
+ "id": "60ca269e.96d878",
+ "type": "switchNode",
+ "name": "switch portSwitch",
+ "xml": "<switch test=\"`$prop.lan.portSwitch == 'layer2-port'`\">\n\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 561.4590759277344,
+ "y": 1331.2692050933838,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "13b85938.8b9cd7"
+ ]
+ ]
+ },
+ {
+ "id": "13b85938.8b9cd7",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 749.4590034484863,
+ "y": 1329.3805322647095,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "a939bddc.25a0a"
+ ]
+ ]
+ },
+ {
+ "id": "ba5b2145.40753",
+ "type": "execute",
+ "name": "execute split ip and mask",
+ "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='split' >\n<parameter name=\"original_string\" value='`$prop.lan.ipAddress`'/>\n<parameter name=\"regex\" value=\"/\"/>\n<parameter name=\"ctx_memory_result_key\" value=\"ipandMask\"/>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 577.0039672851562,
+ "y": 1417.1676979064941,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "575235a2.fb9bbc",
+ "3c20212c.49fade"
+ ]
+ ]
+ },
+ {
+ "id": "3c20212c.49fade",
+ "type": "failure",
+ "name": "success",
+ "xml": "<outcome value='success'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 778.0039863586426,
+ "y": 1395.1676893234253,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "bdf015ad.4678f8"
+ ]
+ ]
+ },
+ {
+ "id": "575235a2.fb9bbc",
+ "type": "failure",
+ "name": "failure",
+ "xml": "<outcome value='failure'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 778.0039901733398,
+ "y": 1436.1676931381226,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "133c89f4.2a7c76"
+ ]
+ ]
+ },
+ {
+ "id": "bdf015ad.4678f8",
+ "type": "set",
+ "name": "set ipAddress prefixLength",
+ "xml": "<set>\n<parameter name='prop.lan.ip-address' value='`$ipandMask[0]`' />\n<parameter name='prop.lan.prefixLength' value='`$ipandMask[1]`' />",
+ "comments": "",
+ "x": 975.0040054321289,
+ "y": 1393.1676893234253,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ },
+ {
+ "id": "133c89f4.2a7c76",
+ "type": "returnFailure",
+ "name": "return failure",
+ "xml": "<return status='failure'>\n<parameter name='error-code' value='' />\n<parameter name='error-message' value=\"An error occured while splitting sna1_route\" />\n",
+ "comments": "",
+ "x": 933.0039978027344,
+ "y": 1433.1676921844482,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ },
+ {
+ "id": "372eb63a.83ff6a",
+ "type": "comment",
+ "name": "TODO: split ip/mask",
+ "info": "",
+ "comments": "",
+ "x": 974.0136375427246,
+ "y": 1355.3479614257812,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ },
+ {
+ "id": "86da8112.f0417",
+ "type": "execute",
+ "name": "execute RestApiCallNode IPSubnets delete",
+ "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/sdlan-ip-subnets-del.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/overlay-network/ip-subnets/action/batch-delete'`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"post\"/>\n<parameter name=\"responsePrefix\" value=\"lanPortResp\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />",
+ "comments": "",
+ "outputs": 1,
+ "x": 635.7753372192383,
+ "y": 1493.2885875701904,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "15bd3770.c63fa9",
+ "248a192b.d86396"
+ ]
+ ]
+ },
+ {
+ "id": "248a192b.d86396",
+ "type": "failure",
+ "name": "failure",
+ "xml": "<outcome value='failure'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 904.7753677368164,
+ "y": 1480.2885599136353,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "616ee6f.3d9a718"
+ ]
+ ]
+ },
+ {
+ "id": "15bd3770.c63fa9",
+ "type": "success",
+ "name": "success",
+ "xml": "<outcome value='success'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 901.7753410339355,
+ "y": 1515.2887783050537,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "40c5dea7.9b57"
+ ]
+ ]
+ },
+ {
+ "id": "616ee6f.3d9a718",
+ "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 executing Create device port rest api\" />\n",
+ "comments": "",
+ "x": 1057.775749206543,
+ "y": 1476.2887859344482,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ },
+ {
+ "id": "40c5dea7.9b57",
+ "type": "block",
+ "name": "block : atomic",
+ "xml": "<block atomic=\"true\">",
+ "atomic": "true",
+ "comments": "",
+ "outputs": 1,
+ "x": 1048.7753219604492,
+ "y": 1516.2885341644287,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "339192eb.51711e"
+ ]
+ ]
+ },
+ {
+ "id": "339192eb.51711e",
+ "type": "set",
+ "name": "set prop.lan.lanPortId",
+ "xml": "<set>\n<parameter name='prop.lan.lanPortId' value='`lanPortResp.success[0].id`' />\n",
+ "comments": "",
+ "x": 1255.6644248962402,
+ "y": 1518.622000694275,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ },
+ {
+ "id": "6c0bf23f.5303ac",
+ "type": "execute",
+ "name": "execute RestApiCallNode create vpn topology",
+ "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/sdwan-vpn-topology.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/overlay-network/' + $prop.vpn1Id + '/topology'`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"put\"/>\n<parameter name=\"responsePrefix\" value=\"vpn-result\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />",
+ "comments": "",
+ "outputs": 1,
+ "x": 652.2857360839844,
+ "y": 1651.7474851608276,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "6503000e.7fe09",
+ "f95d774d.951318"
+ ]
+ ]
+ },
+ {
+ "id": "f95d774d.951318",
+ "type": "success",
+ "name": "success",
+ "xml": "<outcome value='success'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 898.2856712341309,
+ "y": 1687.7468357086182,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "1f602715.4e71b9"
+ ]
+ ]
+ },
+ {
+ "id": "1f602715.4e71b9",
+ "type": "block",
+ "name": "block : atomic",
+ "xml": "<block atomic=\"true\">",
+ "atomic": "true",
+ "comments": "",
+ "outputs": 1,
+ "x": 1070.2856121063232,
+ "y": 1701.7468520402908,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ []
+ ]
+ },
+ {
+ "id": "7c916735.dbf778",
+ "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 executing Create vpn topology failed\" />\n",
+ "comments": "",
+ "x": 1070.2857341766357,
+ "y": 1657.7468520402908,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ },
+ {
+ "id": "6503000e.7fe09",
+ "type": "failure",
+ "name": "failure",
+ "xml": "<outcome value='failure'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 902.2855892181396,
+ "y": 1645.7468347549438,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "7c916735.dbf778"
+ ]
+ ]
+ },
+ {
+ "id": "2b5c8466.72828c",
+ "type": "execute",
+ "name": "execute RestApiCallNode create vpn ",
+ "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"templateFileName\" value=\"`$prop.restapi.templateDir + '/sdwan-vpn.json'`\" />\n<parameter name=\"restapiUrl\" value=\"`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/overlay-network/vpn'`\" />\n<parameter name=\"restapiUser\" value=\"`$prop.sdncRestApi.thirdpartySdnc.user`\" />\n<parameter name=\"restapiPassword\" value=\"`$prop.sdncRestApi.thirdpartySdnc.password`\" />\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"put\"/>\n<parameter name=\"responsePrefix\" value=\"vpn-result\"/>\n<parameter name=\"trustStoreFileName\" value=\"/opt/onap/sdnc/data/stores/truststore.onap.client.jks\"/>\n<parameter name=\"trustStorePassword\" value=\"adminadmin\"/>\n<parameter name=\"keyStoreFileName\" value=\"/opt/onap/sdnc/data/stores/sdnc.p12\"/>\n<parameter name=\"keyStorePassword\" value=\"adminadmin\"/>\n<parameter name='customHttpHeaders' value=\"`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`\" />",
+ "comments": "",
+ "outputs": 1,
+ "x": 619.2841186523438,
+ "y": 1585.246587753296,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "593d6e8d.d4036",
+ "22423ed9.18f8e2"
+ ]
+ ]
+ },
+ {
+ "id": "22423ed9.18f8e2",
+ "type": "success",
+ "name": "success",
+ "xml": "<outcome value='success'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 844.2840175628662,
+ "y": 1605.246500134468,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "b88f4563.6b6768"
+ ]
+ ]
+ },
+ {
+ "id": "b88f4563.6b6768",
+ "type": "block",
+ "name": "block : atomic",
+ "xml": "<block atomic=\"true\">",
+ "atomic": "true",
+ "comments": "",
+ "outputs": 1,
+ "x": 1014.28395652771,
+ "y": 1608.246500134468,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ []
+ ]
+ },
+ {
+ "id": "a724847c.2c4088",
+ "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 executing Create vpn failed\" />\n",
+ "comments": "",
+ "x": 1014.2840785980225,
+ "y": 1564.246500134468,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ },
+ {
+ "id": "593d6e8d.d4036",
+ "type": "failure",
+ "name": "failure",
+ "xml": "<outcome value='failure'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 847.28395652771,
+ "y": 1564.246500134468,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "a724847c.2c4088"
+ ]
+ ]
+ },
+ {
+ "id": "1f47d1c3.9d407e",
+ "type": "switchNode",
+ "name": "switch ActivateSDWANVpnInstance",
+ "xml": "<switch test=\"`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.request-information.request-action == 'ActivateSDWANVpnInstance'`\">\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1210.2859420776367,
+ "y": 869.7469148635864,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "6200b940.359218"
+ ]
+ ]
+ },
+ {
+ "id": "e28cdf4a.09f99",
+ "type": "block",
+ "name": "block",
+ "xml": "<block>\n",
+ "atomic": "false",
+ "comments": "",
+ "outputs": 1,
+ "x": 967.6190452575684,
+ "y": 798.746994972229,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "125425fb.ef4bfa",
+ "1f47d1c3.9d407e",
+ "712ec051.8d2a6"
+ ]
+ ]
+ },
+ {
+ "id": "6200b940.359218",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1305.9524536132812,
+ "y": 943.7469959259033,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "309bb160.fe92de"
+ ]
+ ]
+ },
+ {
+ "id": "309bb160.fe92de",
+ "type": "for",
+ "name": "for vf-modules.vf-module_length",
+ "xml": "<for index='pidx' start='0' end='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param_length`' >\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1520.2023391723633,
+ "y": 945.2469725608826,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "1ac88e91.8c9681"
+ ]
+ ]
+ },
+ {
+ "id": "1ac88e91.8c9681",
+ "type": "switchNode",
+ "name": "switch vpn-id",
+ "xml": "<switch test=\"`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].name == 'vpn-id'`\">\n \n\n\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1767.202377319336,
+ "y": 940.2470555305481,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "3a5e3420.dfdfbc"
+ ]
+ ]
+ },
+ {
+ "id": "3a5e3420.dfdfbc",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1917.9523315429688,
+ "y": 941.7469711303711,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "f542060.75c12f8"
+ ]
+ ]
+ },
+ {
+ "id": "f542060.75c12f8",
+ "type": "set",
+ "name": "set prop.vpn1Id",
+ "xml": "<set>\n<parameter name='prop.vpn1Id' value='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].value`' />\n",
+ "comments": "",
+ "x": 2091.953079223633,
+ "y": 941.747029542923,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ },
+ {
+ "id": "4f58a0f5.56037",
+ "type": "set",
+ "name": "Add sites to list and update length",
+ "xml": "<set>\n<parameter name='prop.siteIds[$prop.siteIds_length]' value='`$prop.attach.siteId`' />\n<parameter name='prop.siteIds_length' value='`$prop.siteIds_length + 1`' />\n\n\n\n\n\n\n\n\n\n\n\n\n\n",
+ "comments": "",
+ "x": 2522.2864532470703,
+ "y": 847.747029542923,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ },
+ {
+ "id": "975b7faf.1862a",
+ "type": "set",
+ "name": "Add site attachement to list and update length",
+ "xml": "<set>\n<parameter name='prop.siteAttachements[$prop.siteAttachements_length].siteId' value='`$prop.attach.siteId`' />\n<parameter name='prop.siteAttachements[$prop.siteAttachements_length].roles[0]' value='`$prop.role`' />\n<parameter name='prop.siteAttachements[$prop.siteAttachements_length].roles_length' value='1' />\n<parameter name='prop.siteAttachements_length' value='`$prop.siteAttachements_length + 1`' />\n\n\n\n\n\n\n\n\n\n\n\n\n",
+ "comments": "",
+ "x": 2553.286346435547,
+ "y": 890.7469959259033,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ },
+ {
+ "id": "d3ab3217.7d57a",
+ "type": "set",
+ "name": "set prop.siteAttachement_length=0",
+ "xml": "<set>\n<parameter name='prop.siteAttachements_length' value='0' />\n<parameter name='prop.siteIds_length' value='0' />\n\n\n\n",
+ "comments": "",
+ "x": 639.2857208251953,
+ "y": 595.7469882965088,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ },
+ {
+ "id": "7cb6a87.6e3f758",
+ "type": "block",
+ "name": "block atomic",
+ "xml": "<block atomic=\"true\">\n",
+ "atomic": "false",
+ "comments": "",
+ "outputs": 1,
+ "x": 1752.6193771362305,
+ "y": 823.7469940185547,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "1008121d.0f833e",
+ "38f1f3d9.ea90fc",
+ "65c7e0ab.e924d"
+ ]
+ ]
+ },
+ {
+ "id": "38f1f3d9.ea90fc",
+ "type": "switchNode",
+ "name": "switch role",
+ "xml": "<switch test=\"`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].name == 'role'`\">\n \n\n\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1914.9523086547852,
+ "y": 754.7469930648804,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "e4b2cfb7.2be02"
+ ]
+ ]
+ },
+ {
+ "id": "e4b2cfb7.2be02",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 2077.9523124694824,
+ "y": 749.7469940185547,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "cbd09e2f.5bc81"
+ ]
+ ]
+ },
+ {
+ "id": "cbd09e2f.5bc81",
+ "type": "block",
+ "name": "block : atomic",
+ "xml": "<block atomic=\"true\">",
+ "atomic": "true",
+ "outputs": 1,
+ "x": 2245.9523544311523,
+ "y": 743.746992111206,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "3c601cb.4b2f2e4",
+ "2d319605.7a6e9a"
+ ]
+ ]
+ },
+ {
+ "id": "2d319605.7a6e9a",
+ "type": "switchNode",
+ "name": "switch sd-wan-edge",
+ "xml": "<switch test=\"`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].value == 'sd-wan-edge'`\">\n\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 2440.9524841308594,
+ "y": 704.7469835281372,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "bb6dcfdd.128fa"
+ ]
+ ]
+ },
+ {
+ "id": "3c601cb.4b2f2e4",
+ "type": "switchNode",
+ "name": "switch dsvpn-hub",
+ "xml": "<switch test=\"`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].name == 'dsvpn-hub'`\">\n \n\n\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 2437.952590942383,
+ "y": 759.7469990253448,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "b131819c.daa97"
+ ]
+ ]
+ },
+ {
+ "id": "91128780.38fd08",
+ "type": "set",
+ "name": "set spoke role",
+ "xml": "<set>\n<parameter name='prop.role' value=\"spoke\" />\n",
+ "comments": "",
+ "x": 2770.952606201172,
+ "y": 698.7470293045044,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ },
+ {
+ "id": "c4199cad.d68d",
+ "type": "set",
+ "name": "set hub role",
+ "xml": "<set>\n<parameter name='prop.role' value=\"hub\" />\n",
+ "comments": "",
+ "x": 2769.952365875244,
+ "y": 753.747013092041,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ },
+ {
+ "id": "bb6dcfdd.128fa",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 2610.9524536132812,
+ "y": 700.4136581420898,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "91128780.38fd08"
+ ]
+ ]
+ },
+ {
+ "id": "b131819c.daa97",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 2614.9524536132812,
+ "y": 755.4136581420898,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "c4199cad.d68d"
+ ]
+ ]
+ },
+ {
+ "id": "16e6f83a.5e7ff8",
+ "type": "update",
+ "name": "update SDWAN VPN status to AAI",
+ "xml": "<update plugin='org.onap.ccsdk.sli.adaptors.aai.AAIService' resource='lan-port-config' \n key='sdwan-vpn.sdwan-vpn-id = $vf-module-topology-operation-input.vf-module-information.vf-module-id' >\n<parameter name='sdwan-vpn-id' value='`$vf-module-topology-operation-input.vf-module-information.vf-module-id`' />\n<parameter name='operational-status' value='PendingDelete' />\n<parameter name='lan-port-config-id' value='`$prop.lan-port-config-id`' />",
+ "comments": "",
+ "outputs": 1,
+ "x": 617.3170700073242,
+ "y": 1867.4452047348022,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ []
+ ]
+ },
+ {
+ "id": "65c7e0ab.e924d",
+ "type": "record",
+ "name": "record",
+ "xml": "<record plugin=\"org.onap.ccsdk.sli.core.sli.recording.FileRecorder\">\n<parameter name=\"file\" value=\"/opt/opendaylight/current/data/log/svclogic23.log\"/>\n<parameter name=\"field1\" value=\"__TIMESTAMP__\"/>\n<parameter name=\"field2\" value=\"param-name\"/>\n<parameter name=\"field3\" value='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].name`'/>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1910.3169555664062,
+ "y": 698.9449081420898,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ []
+ ]
+ },
+ {
+ "id": "712ec051.8d2a6",
+ "type": "record",
+ "name": "record",
+ "xml": "<record plugin=\"org.onap.ccsdk.sli.core.sli.recording.FileRecorder\">\n<parameter name=\"file\" value=\"/opt/opendaylight/current/data/log/svclogic24.log\"/>\n<parameter name=\"field1\" value=\"__TIMESTAMP__\"/>\n<parameter name=\"field2\" value=\"request-action\"/>\n<parameter name=\"field3\" value='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.request-information.request-action`'/>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1153.3171730041504,
+ "y": 699.9450273513794,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ []
+ ]
+ },
+ {
+ "id": "500d4c8a.78bee4",
+ "type": "comment",
+ "name": "**revert the changes",
+ "info": "",
+ "comments": "",
+ "x": 1311.316982269287,
+ "y": 704.4449405670166,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ },
+ {
+ "id": "137ad5db.05e33a",
+ "type": "block",
+ "name": "block : atomic",
+ "xml": "<block atomic=\"true\">",
+ "atomic": "true",
+ "outputs": 1,
+ "x": 1536.3333740234375,
+ "y": 621.6667051315308,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "42b7ec46.f75e94",
+ "5c976c54.43c564"
+ ]
+ ]
+ },
+ {
+ "id": "5c976c54.43c564",
+ "type": "set",
+ "name": "set prop.vnf-id",
+ "xml": "<set>\n<parameter name='prop.vnf-id' value='`$service-data.vnfs.vnf[$vnfidx].vnf-id`' />\n\n",
+ "comments": "",
+ "x": 1728.0000495910645,
+ "y": 551.6666831970215,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ },
+ {
+ "id": "74d2892.3a20c78",
+ "type": "switchNode",
+ "name": "switch prop.vnf-id match",
+ "xml": "<switch test=\"`$service-data.vnfs.vnf[$vnfidx].vnf-id == $prop.vnf-id`\">",
+ "comments": "",
+ "outputs": 1,
+ "x": 886.0003509521484,
+ "y": 673.0000200271606,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "cfdd9f28.400e6"
+ ]
+ ]
+ },
+ {
+ "id": "cfdd9f28.400e6",
+ "type": "outcomeFalse",
+ "name": "false",
+ "xml": "<outcome value='false'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 674.0005035400391,
+ "y": 748.0000233650208,
+ "z": "2a0755d2.04892a",
+ "wires": [
+ [
+ "38f21693.f6208a"
+ ]
+ ]
+ },
+ {
+ "id": "fef5106c.cc924",
+ "type": "comment",
+ "name": "if device-name match with the incomming device-name, sites in this service vnf should not be included",
+ "info": "",
+ "comments": "",
+ "x": 749.0000915527344,
+ "y": 845.0000410079956,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ },
+ {
+ "id": "2ee3209f.a1bb9",
+ "type": "set",
+ "name": "copy input data to service data",
+ "xml": "<set>\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.sdnc-request-header.' value='`$vf-module-topology-operation-input.sdnc-request-header.`' />\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.request-information.' value='`$vf-module-topology-operation-input.request-information.`' />\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.service-information.' value='`$vf-module-topology-operation-input.service-information.`' />\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.vf-module-information.' value='`$vf-module-topology-operation-input.vf-module-information.`' />\n",
+ "comments": "",
+ "x": 605.0000915527344,
+ "y": 1719.6667194366455,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ },
+ {
+ "id": "bfac8597.a517f8",
+ "type": "set",
+ "name": "set vf-module-id and vf-module-object-path",
+ "xml": "<set>\n<parameter name='vf-module-object-path' value=\"`'restconf/config/GENERIC-RESOURCE-API:services/service/'\n + $vf-module-topology-operation-input.service-information.service-instance-id\n + '/service-data/vnfs/vnf/'\n + $service-data.vnfs.vnf[$vnf-index].vnf-id\n + '/vnf-data/vf-modules/vf-module/'\n + $vf-module-topology-operation-input.vf-module-information.vf-module-id\n + '/vf-module-data/vf-module-topology/'`\"/>\n<parameter name='vnf-object-path'\n value=\"`'restconf/config/GENERIC-RESOURCE-API:services/service/'\n + $vf-module-topology-operation-input.service-information.service-instance-id\n + '/service-data/vnfs/vnf/'\n + $service-data.vnfs.vnf[$vnf-index].vnf-id\n + '/vnf-data/vnf-topology/'`\"/>\n<parameter name='service-object-path'\n value=\"`'restconf/config/GENERIC-RESOURCE-API:services/service/'\n + $vf-module-topology-operation-input.service-information.service-instance-id\n + '/service-data/service-topology/'`\"/>\n",
+ "comments": "",
+ "x": 639.3032913208008,
+ "y": 1763.4698286056519,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ },
+ {
+ "id": "b282b047.e838d",
+ "type": "set",
+ "name": "set vf-module-level-oper-status",
+ "xml": "<set>\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.vf-module-level-oper-status.order-status' value='PendingDelete' />\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.vf-module-level-oper-status.last-rpc-action' value='`$vf-module-topology-operation-input.sdnc-request-header.svc-action`' />\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.vf-module-level-oper-status.last-action' value='`$vf-module-topology-operation-input.sdnc-request-header.request-action`' />",
+ "comments": "",
+ "x": 606.3033180236816,
+ "y": 1816.4698705673218,
+ "z": "2a0755d2.04892a",
+ "wires": []
+ }
+]
\ No newline at end of file diff --git a/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-vf-operation-lanport-delete.json b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-vf-operation-lanport-delete.json new file mode 100644 index 00000000..012deec8 --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/json/sdwan/GENERIC-RESOURCE-API_sdwan-vf-operation-lanport-delete.json @@ -0,0 +1,686 @@ +[
+ {
+ "id": "a54d86da.b0b4c8",
+ "type": "method",
+ "name": "method sdwan-vf-operation-lanport-delete",
+ "xml": "<method rpc='sdwan-vf-operation-lanport-delete' mode='sync'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 234.00000762939453,
+ "y": 230.00012350082397,
+ "z": "1f04287d.306418",
+ "wires": [
+ [
+ "4d4d77e8.c38938"
+ ]
+ ]
+ },
+ {
+ "id": "db831233.33e69",
+ "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": 222.28571319580078,
+ "y": 130.65188121795654,
+ "z": "1f04287d.306418",
+ "wires": [
+ [
+ "a54d86da.b0b4c8"
+ ]
+ ]
+ },
+ {
+ "id": "62c65238.af2cac",
+ "type": "dgstart",
+ "name": "DGSTART",
+ "outputs": 1,
+ "x": 143.00000762939453,
+ "y": 68.4137716293335,
+ "z": "1f04287d.306418",
+ "wires": [
+ [
+ "db831233.33e69"
+ ]
+ ]
+ },
+ {
+ "id": "4d4d77e8.c38938",
+ "type": "block",
+ "name": "block : atomic",
+ "xml": "<block atomic=\"true\">",
+ "atomic": "true",
+ "outputs": 1,
+ "x": 250.66670989990234,
+ "y": 459.080491065979,
+ "z": "1f04287d.306418",
+ "wires": [
+ [
+ "26d66719.d43da8",
+ "e7e6cf90.f4145",
+ "2040df5d.c513d",
+ "58084a37.394334",
+ "8cf55d8b.9b86e",
+ "6f98bfc7.8211a",
+ "b57e1a43.a54548",
+ "9d1a9cea.dd56",
+ "49881624.abb0c8",
+ "c5683ab4.530598",
+ "d5b959e7.7e0cc8",
+ "d3e08866.ee2d18"
+ ]
+ ]
+ },
+ {
+ "id": "e7e6cf90.f4145",
+ "type": "for",
+ "name": "for each vnf",
+ "xml": "<for index='idx' start='0' end='`$service-data.vnfs.vnf_length`' >\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 566.0313720703125,
+ "y": 304.6829128265381,
+ "z": "1f04287d.306418",
+ "wires": [
+ [
+ "7275fe1.35167"
+ ]
+ ]
+ },
+ {
+ "id": "26d66719.d43da8",
+ "type": "switchNode",
+ "name": "switch vnf_length",
+ "xml": "<switch test='`$service-data.vnfs.vnf_length`'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 571.0000267028809,
+ "y": 243.41378211975098,
+ "z": "1f04287d.306418",
+ "wires": [
+ [
+ "4f7f751d.4ffa8c"
+ ]
+ ]
+ },
+ {
+ "id": "4f7f751d.4ffa8c",
+ "type": "outcome",
+ "name": "NULL",
+ "xml": "<outcome value=''>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 751.0000076293945,
+ "y": 242.4137716293335,
+ "z": "1f04287d.306418",
+ "wires": [
+ [
+ "b8464fa4.268c7"
+ ]
+ ]
+ },
+ {
+ "id": "b8464fa4.268c7",
+ "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=\"vnf-topology-operation-input.vnf-request-input.vnf-id not found in service-data\" />\n",
+ "comments": "",
+ "x": 900.4287338256836,
+ "y": 243.55668926239014,
+ "z": "1f04287d.306418",
+ "wires": []
+ },
+ {
+ "id": "7275fe1.35167",
+ "type": "switchNode",
+ "name": "switch this vnf-id == input vnf-id",
+ "xml": "<switch test=\"`$service-data.vnfs.vnf[$idx].vnf-id == $vf-module-topology-operation-input.vnf-information.vnf-id`\"> \n",
+ "comments": "",
+ "outputs": 1,
+ "x": 789.0000228881836,
+ "y": 305.41377782821655,
+ "z": "1f04287d.306418",
+ "wires": [
+ [
+ "2f21af21.529ff"
+ ]
+ ]
+ },
+ {
+ "id": "2f21af21.529ff",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1004.0000076293945,
+ "y": 303.4137716293335,
+ "z": "1f04287d.306418",
+ "wires": [
+ [
+ "a1139d12.89e01"
+ ]
+ ]
+ },
+ {
+ "id": "a1139d12.89e01",
+ "type": "set",
+ "name": "set vnf-index",
+ "xml": "<set>\n<parameter name='vnf-index' value='`$idx`' />\n",
+ "comments": "",
+ "x": 1168.0000076293945,
+ "y": 298.4137716293335,
+ "z": "1f04287d.306418",
+ "wires": []
+ },
+ {
+ "id": "2040df5d.c513d",
+ "type": "switchNode",
+ "name": "switch vf-modules.vf-module_length",
+ "xml": "<switch test='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module_length`'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 637.0000419616699,
+ "y": 381.4137964248657,
+ "z": "1f04287d.306418",
+ "wires": [
+ [
+ "6da138cf.958678",
+ "2a607157.3c86fe",
+ "9b455cd1.ad8b9"
+ ]
+ ]
+ },
+ {
+ "id": "2a607157.3c86fe",
+ "type": "outcome",
+ "name": "NULL",
+ "xml": "<outcome value=''>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 859.0000343322754,
+ "y": 415.4138059616089,
+ "z": "1f04287d.306418",
+ "wires": [
+ [
+ "9e4075b3.63ff28"
+ ]
+ ]
+ },
+ {
+ "id": "6da138cf.958678",
+ "type": "outcome",
+ "name": "0",
+ "xml": "<outcome value='0'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 864.0000305175781,
+ "y": 362.41380500793457,
+ "z": "1f04287d.306418",
+ "wires": [
+ [
+ "9e4075b3.63ff28"
+ ]
+ ]
+ },
+ {
+ "id": "9e4075b3.63ff28",
+ "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=\"vnf-topology-operation-input.vnf-request-input.vnf-id not found in service-data\" />\n",
+ "comments": "",
+ "x": 1022.0000343322754,
+ "y": 375.4138059616089,
+ "z": "1f04287d.306418",
+ "wires": []
+ },
+ {
+ "id": "9b455cd1.ad8b9",
+ "type": "other",
+ "name": "other",
+ "xml": "<outcome value='Other'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 859.0000343322754,
+ "y": 476.4138059616089,
+ "z": "1f04287d.306418",
+ "wires": [
+ [
+ "76d683a5.eebfec"
+ ]
+ ]
+ },
+ {
+ "id": "3f214675.09ba1a",
+ "type": "set",
+ "name": "set vf-module_length",
+ "xml": "<set>\n<parameter name='vf-module-length' value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module_length`' />\n\n",
+ "comments": "",
+ "x": 1213.0000495910645,
+ "y": 474.41381990909576,
+ "z": "1f04287d.306418",
+ "wires": []
+ },
+ {
+ "id": "76d683a5.eebfec",
+ "type": "block",
+ "name": "block : atomic",
+ "xml": "<block atomic=\"true\">",
+ "atomic": "true",
+ "outputs": 1,
+ "x": 1020.0000801086426,
+ "y": 473.41379737854004,
+ "z": "1f04287d.306418",
+ "wires": [
+ [
+ "3f214675.09ba1a",
+ "42fcda16.d37964"
+ ]
+ ]
+ },
+ {
+ "id": "42fcda16.d37964",
+ "type": "for",
+ "name": "for each existing vf-index",
+ "xml": "<for index='idx' start='0' end='`$vf-module-length`' >\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1232.0000190734863,
+ "y": 527.4137964248657,
+ "z": "1f04287d.306418",
+ "wires": [
+ [
+ "9de7c553.fd25f8"
+ ]
+ ]
+ },
+ {
+ "id": "9de7c553.fd25f8",
+ "type": "switchNode",
+ "name": "switch vf-module-id found",
+ "xml": "<switch test=\"`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$idx].vf-module-id == $vf-module-topology-operation-input.vf-module-information.vf-module-id`\">\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1503.0000381469727,
+ "y": 528.4138336181641,
+ "z": "1f04287d.306418",
+ "wires": [
+ [
+ "f61f0e52.12de6"
+ ]
+ ]
+ },
+ {
+ "id": "f61f0e52.12de6",
+ "type": "outcomeTrue",
+ "name": "true",
+ "xml": "<outcome value='true'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1716.0001621246338,
+ "y": 515.4138031005859,
+ "z": "1f04287d.306418",
+ "wires": [
+ [
+ "cf9e9748.fd3478"
+ ]
+ ]
+ },
+ {
+ "id": "cf9e9748.fd3478",
+ "type": "block",
+ "name": "block : atomic",
+ "xml": "<block atomic=\"true\">",
+ "atomic": "true",
+ "outputs": 1,
+ "x": 1868.0001335144043,
+ "y": 517.4137964248657,
+ "z": "1f04287d.306418",
+ "wires": [
+ [
+ "1f23fa4e.25db46",
+ "5446fb0a.a3b5a4",
+ "71d1f1bd.544fb"
+ ]
+ ]
+ },
+ {
+ "id": "1f23fa4e.25db46",
+ "type": "set",
+ "name": "set tmp.vidx and ctx.vnf-data",
+ "xml": "<set>\n<parameter name='tmp.vidx' value='`$idx`' />\n<parameter name='ctx.vf-module-data.' value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$idx].vf-module-data.`' />\n",
+ "comments": "",
+ "x": 2090.0001335144043,
+ "y": 513.4137964248657,
+ "z": "1f04287d.306418",
+ "wires": []
+ },
+ {
+ "id": "5446fb0a.a3b5a4",
+ "type": "set",
+ "name": "set vf-module-request-input.",
+ "xml": "<set>\n<parameter name='vf-module-request-input.' value='`$ctx.vf-module-data.vf-module-request-input.`' />\n\n",
+ "comments": "",
+ "x": 2096.0001335144043,
+ "y": 562.4137964248657,
+ "z": "1f04287d.306418",
+ "wires": []
+ },
+ {
+ "id": "71d1f1bd.544fb",
+ "type": "call",
+ "name": "call sdwan-get-vf-module-lan-param",
+ "xml": "<call module='GENERIC-RESOURCE-API' rpc='sdwan-get-vf-module-lan-param' mode='sync' >\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 2124.0003547668457,
+ "y": 610.4138021469116,
+ "z": "1f04287d.306418",
+ "wires": [
+ []
+ ]
+ },
+ {
+ "id": "58084a37.394334",
+ "type": "switchNode",
+ "name": "switch tmp.vidx ",
+ "xml": "<switch test=\"`$tmp.vidx`\">\n\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 576.0312538146973,
+ "y": 554.4298791885376,
+ "z": "1f04287d.306418",
+ "wires": [
+ [
+ "a8fd4f02.a0c39"
+ ]
+ ]
+ },
+ {
+ "id": "a8fd4f02.a0c39",
+ "type": "outcome",
+ "name": "NULL",
+ "xml": "<outcome value=''>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 723.4598960876465,
+ "y": 554.0012893676758,
+ "z": "1f04287d.306418",
+ "wires": [
+ [
+ "e19c0822.f14e78"
+ ]
+ ]
+ },
+ {
+ "id": "e19c0822.f14e78",
+ "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=\"vnf-topology-operation-input.vnf-request-input.vnf-id not found in service-data\" />\n",
+ "comments": "",
+ "x": 872.8886222839355,
+ "y": 555.1442070007324,
+ "z": "1f04287d.306418",
+ "wires": []
+ },
+ {
+ "id": "8cf55d8b.9b86e",
+ "type": "switchNode",
+ "name": "switch vf-module-oper-status",
+ "xml": "<switch test='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.vf-module-level-oper-status.order-status`'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 620.3294143676758,
+ "y": 624.7470846176147,
+ "z": "1f04287d.306418",
+ "wires": [
+ [
+ "56dc0c78.140284",
+ "7bad1343.8cb25c"
+ ]
+ ]
+ },
+ {
+ "id": "56dc0c78.140284",
+ "type": "outcome",
+ "name": "outcome PendingDelete",
+ "xml": "<outcome value='PendingDelete'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 911.1626815795898,
+ "y": 628.8582077026367,
+ "z": "1f04287d.306418",
+ "wires": [
+ [
+ "27edf28.129770e"
+ ]
+ ]
+ },
+ {
+ "id": "7bad1343.8cb25c",
+ "type": "other",
+ "name": "other",
+ "xml": "<outcome value='Other'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 878.1628189086914,
+ "y": 680.8582603931427,
+ "z": "1f04287d.306418",
+ "wires": [
+ [
+ "ea590f8e.65b32"
+ ]
+ ]
+ },
+ {
+ "id": "ea590f8e.65b32",
+ "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=\"`'VNF is not in appropriate state for activate. Current state is ' + $service-data.vnfs.vnf[$tmp.nidx].vnf-data.vnf-level-oper-status.order-status`\" />",
+ "comments": "",
+ "x": 1037.6625862121582,
+ "y": 683.8582594394684,
+ "z": "1f04287d.306418",
+ "wires": []
+ },
+ {
+ "id": "27edf28.129770e",
+ "type": "block",
+ "name": "block : atomic",
+ "xml": "<block atomic=\"true\">",
+ "atomic": "true",
+ "outputs": 1,
+ "x": 1108.469081878662,
+ "y": 639.1833620071411,
+ "z": "1f04287d.306418",
+ "wires": [
+ []
+ ]
+ },
+ {
+ "id": "9d1a9cea.dd56",
+ "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": 591.4406318664551,
+ "y": 1071.635935306549,
+ "z": "1f04287d.306418",
+ "wires": []
+ },
+ {
+ "id": "c5683ab4.530598",
+ "type": "set",
+ "name": "set prop.vnfNewidx",
+ "xml": "<set>\n<parameter name='prop.vnfidxLen' value='`0`' />\n",
+ "comments": "",
+ "x": 598.5272789001465,
+ "y": 695.7472534179688,
+ "z": "1f04287d.306418",
+ "wires": []
+ },
+ {
+ "id": "49881624.abb0c8",
+ "type": "for",
+ "name": "for lidx..service-data.vf-modules.vf-module[]",
+ "xml": "<for index='lidx' start='0' end='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module_length`' >\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 674.5271987915039,
+ "y": 749.7471284866333,
+ "z": "1f04287d.306418",
+ "wires": [
+ [
+ "3538a71e.fcff88"
+ ]
+ ]
+ },
+ {
+ "id": "6f98bfc7.8211a",
+ "type": "set",
+ "name": "set new vnf length",
+ "xml": "<set>\n\t<parameter name=\"service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module_length\" value='`$prop.vnfidxLen`'/>\n\n\t\n",
+ "comments": "",
+ "x": 598.6285705566406,
+ "y": 802.5513463020325,
+ "z": "1f04287d.306418",
+ "wires": []
+ },
+ {
+ "id": "d5b959e7.7e0cc8",
+ "type": "set",
+ "name": "Remove vnf from ServiceData",
+ "xml": "<set>\n\t<parameter name=\"service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$prop.vnfidxLen].\" value=\"\"/>\n",
+ "comments": "",
+ "x": 639.5272369384766,
+ "y": 849.7472591400146,
+ "z": "1f04287d.306418",
+ "wires": []
+ },
+ {
+ "id": "3538a71e.fcff88",
+ "type": "block",
+ "name": "block : atomic",
+ "xml": "<block atomic=\"true\">",
+ "atomic": "true",
+ "outputs": 1,
+ "x": 934.5271892547607,
+ "y": 756.7469882965088,
+ "z": "1f04287d.306418",
+ "wires": [
+ [
+ "10631fee.66247"
+ ]
+ ]
+ },
+ {
+ "id": "d3e08866.ee2d18",
+ "type": "delete",
+ "name": "delete lanport vf instance configuration in AAI",
+ "xml": "<delete plugin=\"org.onap.ccsdk.sli.adaptors.aai.AAIService\" resource='lan-port-config' \n key='site-resource.site-resource-id = $vf-module-topology-operation-input.vf-module-information.vf-module-id'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 673.5276069641113,
+ "y": 1019.008641242981,
+ "z": "1f04287d.306418",
+ "wires": [
+ []
+ ]
+ },
+ {
+ "id": "10631fee.66247",
+ "type": "switchNode",
+ "name": "switch vnf-id found",
+ "xml": "<switch test=\"`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$lidx].vf-module-data.vf-module-information.vf-module-id == $vf-module-topology-operation-input.vf-module-information.vf-module-id`\">\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1120.527256011963,
+ "y": 756.7471489906311,
+ "z": "1f04287d.306418",
+ "wires": [
+ [
+ "5f2f4339.fa3b9c"
+ ]
+ ]
+ },
+ {
+ "id": "5f2f4339.fa3b9c",
+ "type": "outcomeFalse",
+ "name": "false",
+ "xml": "<outcome value='false'>\n",
+ "comments": "",
+ "outputs": 1,
+ "x": 1289.5272636413574,
+ "y": 755.7469863891602,
+ "z": "1f04287d.306418",
+ "wires": [
+ [
+ "282bbccf.a76394"
+ ]
+ ]
+ },
+ {
+ "id": "282bbccf.a76394",
+ "type": "block",
+ "name": "block : atomic",
+ "xml": "<block atomic=\"true\">",
+ "atomic": "true",
+ "outputs": 1,
+ "x": 1443.527102470398,
+ "y": 747.7469873428345,
+ "z": "1f04287d.306418",
+ "wires": [
+ [
+ "15dd9ec6.9cd7d1",
+ "810eaf7a.70186"
+ ]
+ ]
+ },
+ {
+ "id": "15dd9ec6.9cd7d1",
+ "type": "set",
+ "name": "set vnf data",
+ "xml": "<set>\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$prop.vnfidxLen].vnf-id' value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[lidx].vf-module-id`' />\n<parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$prop.vnfidxLen].vnf-data.' value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[lidx].vf-module-data.`' />\n",
+ "comments": "",
+ "x": 1608.5271978378296,
+ "y": 722.747142791748,
+ "z": "1f04287d.306418",
+ "wires": []
+ },
+ {
+ "id": "810eaf7a.70186",
+ "type": "set",
+ "name": "set prop.vnfNewidx",
+ "xml": "<set>\n<parameter name='prop.vnfidxLen' value='`$prop.vnfidxLen + 1`' />\n",
+ "comments": "",
+ "x": 1630.5271978378296,
+ "y": 778.747106552124,
+ "z": "1f04287d.306418",
+ "wires": []
+ },
+ {
+ "id": "b57e1a43.a54548",
+ "type": "set",
+ "name": "set vf-module-object-path",
+ "xml": "<set>\n<parameter name='vf-module-object-path' value=\"`'restconf/config/GENERIC-RESOURCE-API:services/service/'\n + $vf-module-topology-operation-input.service-information.service-instance-id\n + '/service-data/vnfs/vnf/'\n + $service-data.vnfs.vnf[$vnf-index].vnf-id\n + '/vnf-data/vf-modules/vf-module/'\n + $vf-module-topology-operation-input.vf-module-information.vf-module-id\n + '/vf-module-data/vf-module-topology/'`\"/>\n<parameter name='vnf-object-path'\n value=\"`'restconf/config/GENERIC-RESOURCE-API:services/service/'\n + $vf-module-topology-operation-input.service-information.service-instance-id\n + '/service-data/vnfs/vnf/'\n + $service-data.vnfs.vnf[$vnf-index].vnf-id\n + '/vnf-data/vnf-topology/'`\"/>\n<parameter name='service-object-path'\n value=\"`'restconf/config/GENERIC-RESOURCE-API:services/service/'\n + $vf-module-topology-operation-input.service-information.service-instance-id\n + '/service-data/service-topology/'`\"/>\n",
+ "comments": "",
+ "x": 615.3294677734375,
+ "y": 966.0804300308228,
+ "z": "1f04287d.306418",
+ "wires": []
+ },
+ {
+ "id": "eeeb55b5.4909d8",
+ "type": "set",
+ "name": "Remove vnf from ServiceData",
+ "xml": "<set>\n\t<parameter name=\"service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].\" value=\"\"/>\n",
+ "comments": "",
+ "x": 629.3333129882812,
+ "y": 900,
+ "z": "1f04287d.306418",
+ "wires": []
+ }
+]
\ No newline at end of file diff --git a/platform-logic/generic-resource-api/src/main/xml/sdwan/GENERIC-RESOURCE-API_sdwan-get-vf-module-lanport-param.xml b/platform-logic/generic-resource-api/src/main/xml/sdwan/GENERIC-RESOURCE-API_sdwan-get-vf-module-lanport-param.xml new file mode 100644 index 00000000..21f05ed5 --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/xml/sdwan/GENERIC-RESOURCE-API_sdwan-get-vf-module-lanport-param.xml @@ -0,0 +1,80 @@ +<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}'>
+ <method rpc='sdwan-get-vf-module-lanport-param' mode='sync'>
+ <block atomic="true">
+ <for index="idx" start="0" end="`$vf-module-topology-operation-input.vf-module-request-input.vf-module-input-parameters.param_length`">
+ <block>
+ <switch test="`$vf-module-request-input.vf-module-input-parameters.param[$idx].name == 'id'`">
+ <outcome value='true'>
+ <set>
+ <parameter name='prop.lan.id' value='`$vf-module-request-input.vf-module-input-parameters.param[$idx].value`' />
+ </set>
+ </outcome>
+ </switch>
+ <switch test="`$vf-module-request-input.vf-module-input-parameters.param[$idx].name == 'deviceName'`">
+ <outcome value='true'>
+ <set>
+ <parameter name='prop.lan.deviceName' value='`$vf-module-request-input.vf-module-input-parameters.param[$idx].value`' />
+ </set>
+ </outcome>
+ </switch>
+ <switch test="`$vf-module-request-input.vf-module-input-parameters.param[$idx].name == 'portSwitch'`">
+ <outcome value='true'>
+ <set>
+ <parameter name='prop.lan.portSwitch' value='`$vf-module-request-input.vf-module-input-parameters.param[$idx].value`' />
+ </set>
+ </outcome>
+ </switch>
+ <switch test="`$vf-module-request-input.vf-module-input-parameters.param[$idx].name == 'portType'`">
+ <outcome value='true'>
+ <set>
+ <parameter name='prop.lan.portType' value='`$vf-module-request-input.vf-module-input-parameters.param[$idx].value`' />
+ </set>
+ </outcome>
+ </switch>
+ <switch test="`$vf-module-request-input.vf-module-input-parameters.param[$idx].name == 'portNumber'`">
+ <outcome value='true'>
+ <set>
+ <parameter name='prop.lan.portNumber' value='`$vf-module-request-input.vf-module-input-parameters.param[$idx].value`' />
+ </set>
+ </outcome>
+ </switch>
+ <switch test="`$vf-module-request-input.vf-module-input-parameters.param[$idx].name == 'ipAddress'`">
+ <outcome value='true'>
+ <set>
+ <parameter name='prop.lan.ipAddress' value='`$vf-module-request-input.vf-module-input-parameters.param[$idx].value`' />
+ </set>
+ </outcome>
+ </switch>
+ <switch test="`$vf-module-request-input.vf-module-input-parameters.param[$idx].name == 'vlanId'`">
+ <outcome value='true'>
+ <set>
+ <parameter name='prop.lan.vlanId' value='`$vf-module-request-input.vf-module-input-parameters.param[$idx].value`' />
+ </set>
+ </outcome>
+ </switch>
+ <switch test="`$vf-module-request-input.vf-module-input-parameters.param[$idx].name == 'devicePortId'`">
+ <outcome value='true'>
+ <set>
+ <parameter name='prop.lan.devicePortId' value='`$vf-module-request-input.vf-module-input-parameters.param[$idx].value`' />
+ </set>
+ </outcome>
+ </switch>
+ <switch test="`$vf-module-request-input.vf-module-input-parameters.param[$idx].name == 'lanPortId'`">
+ <outcome value='true'>
+ <set>
+ <parameter name='prop.lan.lanPortId' value='`$vf-module-request-input.vf-module-input-parameters.param[$idx].value`' />
+ </set>
+ </outcome>
+ </switch>
+ <return status='success'>
+ <parameter name="ack-final-indicator" value="Y" />
+ <parameter name="error-code" value="200" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </for>
+ </block>
+ </method>
+</service-logic>
\ No newline at end of file diff --git a/platform-logic/generic-resource-api/src/main/xml/sdwan/GENERIC-RESOURCE-API_sdwan-vf-operation-lanport-activate.xml b/platform-logic/generic-resource-api/src/main/xml/sdwan/GENERIC-RESOURCE-API_sdwan-vf-operation-lanport-activate.xml new file mode 100644 index 00000000..15f1e537 --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/xml/sdwan/GENERIC-RESOURCE-API_sdwan-vf-operation-lanport-activate.xml @@ -0,0 +1,425 @@ +<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}'>
+ <method rpc='sdwan-vf-operation-lanport-activate' mode='sync'>
+ <block atomic="true">
+ <switch test='`$service-data.vnfs.vnf_length`'>
+ <outcome value=''>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="vnf-topology-operation-input.vnf-request-input.vnf-id not found in service-data" />
+ </return>
+ </outcome>
+ </switch>
+ <for index='idx' start='0' end='`$service-data.vnfs.vnf_length`' >
+ <switch test="`$service-data.vnfs.vnf[$idx].vnf-id == $vf-module-topology-operation-input.vnf-information.vnf-id`">
+ <outcome value='true'>
+ <set>
+ <parameter name='vnf-index' value='`$idx`' />
+ </set>
+ </outcome>
+ </switch>
+ </for>
+ <switch test='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module_length`'>
+ <outcome value='0'>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="vnf-topology-operation-input.vnf-request-input.vnf-id not found in service-data" />
+ </return>
+ </outcome>
+ <outcome value=''>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="vnf-topology-operation-input.vnf-request-input.vnf-id not found in service-data" />
+ </return>
+ </outcome>
+ <outcome value='Other'>
+ <block atomic="true">
+ <set>
+ <parameter name='vf-module-length' value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module_length`' />
+ </set>
+ <for index='idx' start='0' end='`$vf-module-length`' >
+ <switch test="`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$idx].vf-module-id == $vf-module-topology-operation-input.vf-module-information.vf-module-id`">
+ <outcome value='true'>
+ <block atomic="true">
+ <set>
+ <parameter name='tmp.vidx' value='`$idx`' />
+ <parameter name='ctx.vf-module-data.' value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$idx].vf-module-data.`' />
+ </set>
+ <set>
+ <parameter name='vf-module-request-input.' value='`$ctx.vf-module-data.vf-module-request-input.`' />
+ </set>
+ <call module='GENERIC-RESOURCE-API' rpc='sdwan-get-vf-module-lanport-param' mode='sync' ></call>
+ </block>
+ </outcome>
+ </switch>
+ </for>
+ </block>
+ </outcome>
+ </switch>
+ <for index='vnfidx' start='0' end='`$service-data.vnfs.vnf_length`' >
+ <for index='vfidx' start='0' end='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module_length`' >
+ <for index='pidx' start='0' end='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param_length`' >
+ <switch test="`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].value == '$prop.lan.deviceName'`">
+ <outcome value='true'>
+ <for index='pidx' start='0' end='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param_length`' >
+ <switch test="`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].name == 'deviceId'`">
+ <outcome value='true'>
+ <set>
+ <parameter name='prop.lan.deviceId' value='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].value`' />
+ </set>
+ </outcome>
+ </switch>
+ </for>
+ </outcome>
+ </switch>
+ </for>
+ </for>
+ </for>
+ <set>
+ <parameter name='prop.siteAttachements_length' value='0' />
+ <parameter name='prop.siteIds_length' value='0' />
+ </set>
+ <for index='vnfidx' start='0' end='`$service-data.vnfs.vnf_length`' >
+ <for index='vfidx' start='0' end='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module_length`' >
+ <block>
+ <record plugin="org.onap.ccsdk.sli.core.sli.recording.FileRecorder">
+ <parameter name="file" value="/opt/opendaylight/current/data/log/svclogic24.log"/>
+ <parameter name="field1" value="__TIMESTAMP__"/>
+ <parameter name="field2" value="request-action"/>
+ <parameter name="field3" value='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.request-information.request-action`'/>
+ </record>
+ <switch test="`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.request-information.request-action == 'ActivateSDWANSiteInstance'`">
+ <outcome value='true'>
+ <for index='pidx' start='0' end='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param_length`' >
+ <block atomic="true">
+ <record plugin="org.onap.ccsdk.sli.core.sli.recording.FileRecorder">
+ <parameter name="file" value="/opt/opendaylight/current/data/log/svclogic23.log"/>
+ <parameter name="field1" value="__TIMESTAMP__"/>
+ <parameter name="field2" value="param-name"/>
+ <parameter name="field3" value='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].name`'/>
+ </record>
+ <switch test="`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].name == 'role'`">
+ <outcome value='true'>
+ <block atomic="true">
+ <record plugin="org.onap.ccsdk.sli.core.sli.recording.FileRecorder">
+ <parameter name="file" value="/opt/opendaylight/current/data/log/svclogic22.log"/>
+ <parameter name="field1" value="__TIMESTAMP__"/>
+ <parameter name="field2" value="set spoke role"/>
+ </record>
+ <switch test="`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].value == 'sd-wan-edge'`">
+ <outcome value='true'>
+ <set>
+ <parameter name='prop.role' value="spoke" />
+ </set>
+ </outcome>
+ </switch>
+ <switch test="`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].name == 'dsvpn-hub'`">
+ <outcome value='true'>
+ <set>
+ <parameter name='prop.role' value="hub" />
+ </set>
+ </outcome>
+ </switch>
+ </block>
+ </outcome>
+ </switch>
+ <switch test="`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].name == 'siteId'`">
+ <outcome value='true'>
+ <block atomic="true">
+ <set>
+ <parameter name='prop.attach.siteId' value='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].value`' />
+ </set>
+ <set>
+ <parameter name='prop.siteIds[$prop.siteIds_length]' value='`$prop.attach.siteId`' />
+ <parameter name='prop.siteIds_length' value='`$prop.siteIds_length + 1`' />
+ </set>
+ <set>
+ <parameter name='prop.siteAttachements[$prop.siteAttachements_length].siteId' value='`$prop.attach.siteId`' />
+ <parameter name='prop.siteAttachements[$prop.siteAttachements_length].roles[0]' value='`$prop.role`' />
+ <parameter name='prop.siteAttachements[$prop.siteAttachements_length].roles_length' value='1' />
+ <parameter name='prop.siteAttachements_length' value='`$prop.siteAttachements_length + 1`' />
+ </set>
+ <record plugin="org.onap.ccsdk.sli.core.sli.recording.FileRecorder">
+ <parameter name="file" value="/opt/opendaylight/current/data/log/svclogic21.log"/>
+ <parameter name="field1" value="__TIMESTAMP__"/>
+ <parameter name="field2" value="prop.attach.siteId"/>
+ <parameter name="field3" value='`$prop.attach.siteId`'/>
+ </record>
+ </block>
+ </outcome>
+ </switch>
+ </block>
+ </for>
+ </outcome>
+ </switch>
+ <switch test="`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.request-information.request-action == 'ActivateSDWANVpnInstance'`">
+ <outcome value='true'>
+ <for index='pidx' start='0' end='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param_length`' >
+ <switch test="`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].name == 'vpn-id'`">
+ <outcome value='true'>
+ <set>
+ <parameter name='prop.vpn1Id' value='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].value`' />
+ </set>
+ </outcome>
+ </switch>
+ </for>
+ </outcome>
+ </switch>
+ </block>
+ </for>
+ </for>
+ <get-resource plugin="org.onap.ccsdk.sli.adaptors.aai.AAIService"
+ resource="esr-thirdparty-sdnc"
+ key="esr-thirdparty-sdnc.thirdparty-sdnc-id = SDWANController AND
+ depth = '1'"
+ pfx='tmp.aai.esr-thirdparty-sdnc' local-only='false' >
+ <outcome value='success'>
+ <set>
+ <parameter name='prop.sdncRestApi.thirdpartySdnc.url' value="`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].service-url`" />
+ <parameter name='prop.sdncRestApi.thirdpartySdnc.user' value="`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].user-name`" />
+ <parameter name='prop.sdncRestApi.thirdpartySdnc.password' value="`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].password`" />
+ </set>
+ </outcome>
+ <outcome value='not-found'>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`'An error occurred while querying esr-thirdparty-sdnc from AnAI with thirdparty-sdnc-id = ' + $tmp.thirdparty-sdnc-id`" />
+ </return>
+ </outcome>
+ <outcome value='Other'>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`'Unexpected error occurred while querying esr-thirdparty-sdnc from AnAI with thirdparty-sdnc-id = ' + $tmp.thirdparty-sdnc-id`" />
+ </return>
+ </outcome>
+ </get-resource>
+ <execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >
+ <parameter name="templateFileName" value="`$prop.restapi.templateDir + '/actokentemplate.json'`" />
+ <parameter name="restapiUrl" value="`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/v2/tokens'`" />
+ <parameter name="format" value="json"/>
+ <parameter name="httpMethod" value="post"/>
+ <parameter name="responsePrefix" value="token-result"/>
+ <parameter name="trustStoreFileName" value="/opt/onap/sdnc/data/stores/truststore.onap.client.jks"/>
+ <parameter name="trustStorePassword" value="adminadmin"/>
+ <parameter name="keyStoreFileName" value="/opt/onap/sdnc/data/stores/sdnc.p12"/>
+ <parameter name="keyStorePassword" value="adminadmin"/>
+ <outcome value='success'>
+ <set>
+ <parameter name='prop.sdncRestApi.token_id' value='`$token-result.data.token_id`' />
+ </set>
+ </outcome>
+ <outcome value='failure'>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="Error executing get token rest api" />
+ </return>
+ </outcome>
+ </execute>
+ <call module='GENERIC-RESOURCE-API' rpc='sdwan-get-tenant-auth' mode='sync' ></call>
+ <execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >
+ <parameter name="templateFileName" value="`$prop.restapi.templateDir + '/sdlan-port.json'`" />
+ <parameter name="restapiUrl" value="`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/net/ports'`" />
+ <parameter name="restapiUser" value="`$prop.sdncRestApi.thirdpartySdnc.user`" />
+ <parameter name="restapiPassword" value="`$prop.sdncRestApi.thirdpartySdnc.password`" />
+ <parameter name="format" value="json"/>
+ <parameter name="httpMethod" value="post"/>
+ <parameter name="responsePrefix" value="portResp"/>
+ <parameter name="trustStoreFileName" value="/opt/onap/sdnc/data/stores/truststore.onap.client.jks"/>
+ <parameter name="trustStorePassword" value="adminadmin"/>
+ <parameter name="keyStoreFileName" value="/opt/onap/sdnc/data/stores/sdnc.p12"/>
+ <parameter name="keyStorePassword" value="adminadmin"/>
+ <parameter name='customHttpHeaders' value="`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`" />
+ <outcome value='failure'>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="Error executing Create device port rest api" />
+ </return>
+ </outcome>
+ <outcome value='success'>
+ <block atomic="true"></block>
+ </outcome>
+ </execute>
+ <set>
+ <parameter name='prop.lan.devicePortId' value='`$portResp.success[0].id`' />
+ </set>
+ <switch test="`$prop.lan.portSwitch == 'layer2-port'`">
+ <outcome value='true'>
+ <execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >
+ <parameter name="templateFileName" value="`$prop.restapi.templateDir + '/sdlan-bridge-domain.json'`" />
+ <parameter name="restapiUrl" value="`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/overlay-network/bridge-domains'`" />
+ <parameter name="restapiUser" value="`$prop.sdncRestApi.thirdpartySdnc.user`" />
+ <parameter name="restapiPassword" value="`$prop.sdncRestApi.thirdpartySdnc.password`" />
+ <parameter name="format" value="json"/>
+ <parameter name="httpMethod" value="post"/>
+ <parameter name="responsePrefix" value="bridgeDomainResp"/>
+ <parameter name="trustStoreFileName" value="/opt/onap/sdnc/data/stores/truststore.onap.client.jks"/>
+ <parameter name="trustStorePassword" value="adminadmin"/>
+ <parameter name="keyStoreFileName" value="/opt/onap/sdnc/data/stores/sdnc.p12"/>
+ <parameter name="keyStorePassword" value="adminadmin"/>
+ <parameter name='customHttpHeaders' value="`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`" />
+ <outcome value='failure'>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="Error executing Create bridge domain rest api" />
+ </return>
+ </outcome>
+ <outcome value='success'>
+ <block atomic="true"></block>
+ </outcome>
+ </execute>
+ </outcome>
+ </switch>
+ <execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='split' >
+ <parameter name="original_string" value='`$prop.lan.ipAddress`'/>
+ <parameter name="regex" value="/"/>
+ <parameter name="ctx_memory_result_key" value="ipandMask"/>
+ <outcome value='success'>
+ <set>
+ <parameter name='prop.lan.ip-address' value='`$ipandMask[0]`' />
+ <parameter name='prop.lan.prefixLength' value='`$ipandMask[1]`' />
+ </set>
+ </outcome>
+ <outcome value='failure'>
+ <return status='failure'>
+ <parameter name='error-code' value='' />
+ <parameter name='error-message' value="An error occured while splitting sna1_route" />
+ </return>
+ </outcome>
+ </execute>
+ <execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >
+ <parameter name="templateFileName" value="`$prop.restapi.templateDir + '/sdlan-ip-subnets.json'`" />
+ <parameter name="restapiUrl" value="`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/overlay-network/ip-subnets'`" />
+ <parameter name="restapiUser" value="`$prop.sdncRestApi.thirdpartySdnc.user`" />
+ <parameter name="restapiPassword" value="`$prop.sdncRestApi.thirdpartySdnc.password`" />
+ <parameter name="format" value="json"/>
+ <parameter name="httpMethod" value="post"/>
+ <parameter name="responsePrefix" value="lanPortResp"/>
+ <parameter name="trustStoreFileName" value="/opt/onap/sdnc/data/stores/truststore.onap.client.jks"/>
+ <parameter name="trustStorePassword" value="adminadmin"/>
+ <parameter name="keyStoreFileName" value="/opt/onap/sdnc/data/stores/sdnc.p12"/>
+ <parameter name="keyStorePassword" value="adminadmin"/>
+ <parameter name='customHttpHeaders' value="`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`" />
+ <outcome value='failure'>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="Error executing Create device port rest api" />
+ </return>
+ </outcome>
+ <outcome value='success'>
+ <block atomic="true">
+ <set>
+ <parameter name='prop.lan.lanPortId' value='`lanPortResp.success[0].id`' />
+ </set>
+ </block>
+ </outcome>
+ </execute>
+ <execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >
+ <parameter name="templateFileName" value="`$prop.restapi.templateDir + '/sdwan-vpn.json'`" />
+ <parameter name="restapiUrl" value="`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/overlay-network/vpn'`" />
+ <parameter name="restapiUser" value="`$prop.sdncRestApi.thirdpartySdnc.user`" />
+ <parameter name="restapiPassword" value="`$prop.sdncRestApi.thirdpartySdnc.password`" />
+ <parameter name="format" value="json"/>
+ <parameter name="httpMethod" value="put"/>
+ <parameter name="responsePrefix" value="vpn-result"/>
+ <parameter name="trustStoreFileName" value="/opt/onap/sdnc/data/stores/truststore.onap.client.jks"/>
+ <parameter name="trustStorePassword" value="adminadmin"/>
+ <parameter name="keyStoreFileName" value="/opt/onap/sdnc/data/stores/sdnc.p12"/>
+ <parameter name="keyStorePassword" value="adminadmin"/>
+ <parameter name='customHttpHeaders' value="`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`" />
+ <outcome value='failure'>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="Error executing Create vpn failed" />
+ </return>
+ </outcome>
+ <outcome value='success'>
+ <block atomic="true"></block>
+ </outcome>
+ </execute>
+ <execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >
+ <parameter name="templateFileName" value="`$prop.restapi.templateDir + '/sdwan-vpn-topology.json'`" />
+ <parameter name="restapiUrl" value="`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/overlay-network/' + $prop.vpn1Id + '/topology'`" />
+ <parameter name="restapiUser" value="`$prop.sdncRestApi.thirdpartySdnc.user`" />
+ <parameter name="restapiPassword" value="`$prop.sdncRestApi.thirdpartySdnc.password`" />
+ <parameter name="format" value="json"/>
+ <parameter name="httpMethod" value="put"/>
+ <parameter name="responsePrefix" value="vpn-result"/>
+ <parameter name="trustStoreFileName" value="/opt/onap/sdnc/data/stores/truststore.onap.client.jks"/>
+ <parameter name="trustStorePassword" value="adminadmin"/>
+ <parameter name="keyStoreFileName" value="/opt/onap/sdnc/data/stores/sdnc.p12"/>
+ <parameter name="keyStorePassword" value="adminadmin"/>
+ <parameter name='customHttpHeaders' value="`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`" />
+ <outcome value='failure'>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="Error executing Create vpn topology failed" />
+ </return>
+ </outcome>
+ <outcome value='success'>
+ <block atomic="true"></block>
+ </outcome>
+ </execute>
+ <set>
+ <parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param_length].name' value='devicePortId' />
+ <parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param_length].value' value='`$prop.lan.devicePortId`' />
+ </set>
+ <set>
+ <parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param_length].name' value='lanPortId' />
+ <parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param_length].value' value='`$prop.lan.lanPortId`' />
+ </set>
+ <set>
+ <parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.sdnc-request-header.' value='`$vf-module-topology-operation-input.sdnc-request-header.`' />
+ <parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.request-information.' value='`$vf-module-topology-operation-input.request-information.`' />
+ <parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.service-information.' value='`$vf-module-topology-operation-input.service-information.`' />
+ <parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.vf-module-information.' value='`$vf-module-topology-operation-input.vf-module-information.`' />
+ </set>
+ <set>
+ <parameter name='vf-module-object-path' value="`'restconf/config/GENERIC-RESOURCE-API:services/service/'
+ + $vf-module-topology-operation-input.service-information.service-instance-id
+ + '/service-data/vnfs/vnf/'
+ + $service-data.vnfs.vnf[$vnf-index].vnf-id
+ + '/vnf-data/vf-modules/vf-module/'
+ + $vf-module-topology-operation-input.vf-module-information.vf-module-id
+ + '/vf-module-data/vf-module-topology/'`"/>
+ <parameter name='vnf-object-path'
+ value="`'restconf/config/GENERIC-RESOURCE-API:services/service/'
+ + $vf-module-topology-operation-input.service-information.service-instance-id
+ + '/service-data/vnfs/vnf/'
+ + $service-data.vnfs.vnf[$vnf-index].vnf-id
+ + '/vnf-data/vnf-topology/'`"/>
+ <parameter name='service-object-path'
+ value="`'restconf/config/GENERIC-RESOURCE-API:services/service/'
+ + $vf-module-topology-operation-input.service-information.service-instance-id
+ + '/service-data/service-topology/'`"/>
+ </set>
+ <set>
+ <parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.vf-module-level-oper-status.order-status' value='Active' />
+ <parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.vf-module-level-oper-status.last-rpc-action' value='`$vf-module-topology-operation-input.sdnc-request-header.svc-action`' />
+ <parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.vf-module-level-oper-status.last-action' value='`$vf-module-topology-operation-input.sdnc-request-header.request-action`' />
+ </set>
+ <update plugin='org.onap.ccsdk.sli.adaptors.aai.AAIService' resource='lan-port-config'
+ key='sdwan-vpn.sdwan-vpn-id = $vf-module-topology-operation-input.vf-module-information.vf-module-id' >
+ <parameter name='sdwan-vpn-id' value='`$vf-module-topology-operation-input.vf-module-information.vf-module-id`' />
+ <parameter name='operational-status' value='Active' />
+ <parameter name='lan-port-config-id' value='`$prop.lan-port-config-id`' />
+ </update>
+ <return status='success'>
+ <parameter name="ack-final-indicator" value="Y" />
+ <parameter name="error-code" value="200" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </method>
+</service-logic>
\ No newline at end of file diff --git a/platform-logic/generic-resource-api/src/main/xml/sdwan/GENERIC-RESOURCE-API_sdwan-vf-operation-lanport-create.xml b/platform-logic/generic-resource-api/src/main/xml/sdwan/GENERIC-RESOURCE-API_sdwan-vf-operation-lanport-create.xml new file mode 100644 index 00000000..607a19f6 --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/xml/sdwan/GENERIC-RESOURCE-API_sdwan-vf-operation-lanport-create.xml @@ -0,0 +1,136 @@ +<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}'>
+ <method rpc='sdwan-vf-operation-lanport-create' mode='sync'>
+ <block atomic="true">
+ <switch test='`$service-data.vnfs.vnf_length`'>
+ <outcome value=''>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="404" />
+ <parameter name="error-message" value="There are no VNFs in MD-SAL" />
+ </return>
+ </outcome>
+ </switch>
+ <for index='idx' start='0' end='`$service-data.vnfs.vnf_length`' >
+ <switch test="`$service-data.vnfs.vnf[$idx].vnf-id == $vf-module-topology-operation-input.vnf-information.vnf-id`">
+ <outcome value='true'>
+ <set>
+ <parameter name='vnf-index' value='`$idx`' />
+ </set>
+ </outcome>
+ </switch>
+ </for>
+ <switch test='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module_length`'>
+ <outcome value=''>
+ <set>
+ <parameter name='vf-index' value='0' />
+ </set>
+ </outcome>
+ <outcome value='Other'>
+ <block>
+ <set>
+ <parameter name='vf-index' value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module_length`' />
+ </set>
+ <for index='idx' start='0' end='`$vf-index`' >
+ <switch test="`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$idx].vf-module-id == $vf-module-topology-operation-input.vf-module-information.vf-module-id`">
+ <outcome value='true'>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$idx].vf-module-id already found in service-data" />
+ </return>
+ </outcome>
+ </switch>
+ </for>
+ </block>
+ </outcome>
+ </switch>
+ <for index="idx" start="0" end="`$vf-module-topology-operation-input.vf-module-request-input.vf-module-input-parameters.param_length`">
+ <block>
+ <execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='split' >
+ <parameter name="original_string" value='`$vf-module-topology-operation-input.vf-module-request-input.vf-module-input-parameters.param[$idx].name`'/>
+ <parameter name="regex" value="_"/>
+ <parameter name="ctx_memory_result_key" value="param-prefix"/>
+ </execute>
+ <set>
+ <parameter name="`vf-module-topology-operation-input.vf-module-request-input.vf-module-input-parameters.param[$idx].name`" value='`$param-prefix[$param-prefix_length -1]`'/>
+ </set>
+ </block>
+ </for>
+ <call module='GENERIC-RESOURCE-API' rpc='sdwan-get-vf-module-lanport-param' mode='sync' ></call>
+ <set>
+ <parameter name='vf-module-request-input.' value='`$vf-module-topology-operation-input.vf-module-request-input.`' />
+ </set>
+ <set>
+ <parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module_length' value='`$vf-index + 1`' />
+ </set>
+ <execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliPluginUtils' method='generateUUID' >
+ <parameter name="ctx-destination" value="prop.lan-vf-index"/>
+ </execute>
+ <set>
+ <parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-index].vf-module-id' value='`$prop.lan-vf-index`' />
+ <parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-index].vf-module-data.sdnc-request-header.' value='`$vf-module-topology-operation-input.sdnc-request-header.`' />
+ <parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-index].vf-module-data.request-information.' value='`$vf-module-topology-operation-input.request-information.`' />
+ <parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-index].vf-module-data.service-information.' value='`$vf-module-topology-operation-input.service-information.`' />
+ <parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-index].vf-module-data.vnf-information.' value='`$vf-module-topology-operation-input.vnf-information.`' />
+ <parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-index].vf-module-data.vf-module-information.' value='`$vf-module-topology-operation-input.vf-module-information.`' />
+ <parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-index].vf-module-data.vf-module-request-input.' value='`$vf-module-topology-operation-input.vf-module-request-input.`' />
+ <parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-index].vf-module-data.vf-module-topology.' value='`$tmp.vf-module-topology.`' />
+ <parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module_length' value='`$vf-index+1`' />
+ </set>
+ <set>
+ <parameter name='vf-module-object-path' value="`'restconf/config/GENERIC-RESOURCE-API:services/service/'
+ + $vf-module-topology-operation-input.service-information.service-instance-id
+ + '/service-data/vnfs/vnf/'
+ + $service-data.vnfs.vnf[$vnf-index].vnf-id
+ + '/vnf-data/vf-modules/vf-module/'
+ + $vf-module-topology-operation-input.vf-module-information.vf-module-id
+ + '/vf-module-data/vf-module-topology/'`"/>
+ <parameter name='vnf-object-path'
+ value="`'restconf/config/GENERIC-RESOURCE-API:services/service/'
+ + $vf-module-topology-operation-input.service-information.service-instance-id
+ + '/service-data/vnfs/vnf/'
+ + $service-data.vnfs.vnf[$vnf-index].vnf-id
+ + '/vnf-data/vnf-topology/'`"/>
+ <parameter name='service-object-path'
+ value="`'restconf/config/GENERIC-RESOURCE-API:services/service/'
+ + $vf-module-topology-operation-input.service-information.service-instance-id
+ + '/service-data/service-topology/'`"/>
+ </set>
+ <set>
+ <parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-index].vf-module-data.vf-module-level-oper-status.order-status' value='Created' />
+ <parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-index].vf-module-data.vf-module-level-oper-status.last-rpc-action' value='`$vf-module-topology-operation-input.sdnc-request-header.svc-action`' />
+ <parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$vf-index].vf-module-data.vf-module-level-oper-status.last-action' value='`$vf-module-topology-operation-input.sdnc-request-header.request-action`' />
+ </set>
+ <save plugin='org.onap.ccsdk.sli.adaptors.aai.AAIService' resource='lan-port-config'
+ key='lan-port-config.lan-port-config-id = $prop.lan-vf-index' >
+ <parameter name="lan-port-config-id" value="`$prop.vnf-index`" />
+ <parameter name="device-id" value="`$prop.lan.deviceName`" />
+ <parameter name="port-switch" value="`$prop.lan.portSwitch`" />
+ <parameter name="port-type" value="`$prop.lan.portType`" />
+ <parameter name="port-number" value="`$prop.lan.portnumber`" />
+ <parameter name="ipv4-address" value="`$prop.lan.ipAddress`" />
+ <parameter name='vlan-tag' value="`$prop.lan.vlanId`" />
+ <parameter name='operational-status' value='Created' />
+ <parameter name='model-customization-id' value='`$vf-module-topology-operation-input.vf-module-information.onap-model-information.model-customization-uuid`' />
+ <parameter name='model-invariant-id' value='`$vf-module-topology-operation-input.vf-module-information.onap-model-information.model-invariant-uuid`' />
+ <parameter name='model-version-id' value='`$vf-module-topology-operation-input.vf-module-information.onap-model-information.model-version`' />
+ <parameter name='selflink' value="`'restconf/config/GENERIC-RESOURCE-API:services/service/' + $vf-module-topology-operation-input.service-information.service-instance-id + '/service-data/vnfs/vnf/' + $service-data.vnfs.vnf[$vnf-index].vnf-id + '/vnf-data/vf-modules/vf-module/' + $prop.site-vf-index + '/vf-module-data/'` " />
+ </save>
+ <save plugin='org.onap.ccsdk.sli.adaptors.aai.AAIService' resource='generic-vnf:relationship-list'
+ key='generic-vnf.vnf-id = $service-data.vnfs.vnf[$vnf-index].vnf-id'
+ force="true" pfx="tmp.AnAI-data">
+ <parameter name="relationship-list.relationship[0].related-to" value="sdwan-vpn" />
+ <parameter name="relationship-list.relationship[0].related-link" value="`'/network/sdwan-vpns/sdwan-vpn/' + $prop.lan-vf-index`" />
+ <parameter name="relationship-list.relationship[0].relationship-data[0].relationship-key" value="lan-port-config-id" />
+ <parameter name="relationship-list.relationship[0].relationship-data[0].relationship-value" value="`$prop.lan-vf-index`" />
+ </save>
+ <return status='success'>
+ <parameter name="ack-final-indicator" value="Y" />
+ <parameter name="error-code" value="200" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </method>
+</service-logic>
\ No newline at end of file diff --git a/platform-logic/generic-resource-api/src/main/xml/sdwan/GENERIC-RESOURCE-API_sdwan-vf-operation-lanport-deactivate.xml b/platform-logic/generic-resource-api/src/main/xml/sdwan/GENERIC-RESOURCE-API_sdwan-vf-operation-lanport-deactivate.xml new file mode 100644 index 00000000..77575c2f --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/xml/sdwan/GENERIC-RESOURCE-API_sdwan-vf-operation-lanport-deactivate.xml @@ -0,0 +1,413 @@ +<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}'>
+ <method rpc='sdwan-vf-operation-lanport-deactivate' mode='sync'>
+ <block atomic="true">
+ <switch test='`$service-data.vnfs.vnf_length`'>
+ <outcome value=''>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="vnf-topology-operation-input.vnf-request-input.vnf-id not found in service-data" />
+ </return>
+ </outcome>
+ </switch>
+ <for index='idx' start='0' end='`$service-data.vnfs.vnf_length`' >
+ <switch test="`$service-data.vnfs.vnf[$idx].vnf-id == $vf-module-topology-operation-input.vnf-information.vnf-id`">
+ <outcome value='true'>
+ <set>
+ <parameter name='vnf-index' value='`$idx`' />
+ </set>
+ </outcome>
+ </switch>
+ </for>
+ <switch test='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module_length`'>
+ <outcome value='0'>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="vnf-topology-operation-input.vnf-request-input.vnf-id not found in service-data" />
+ </return>
+ </outcome>
+ <outcome value=''>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="vnf-topology-operation-input.vnf-request-input.vnf-id not found in service-data" />
+ </return>
+ </outcome>
+ <outcome value='Other'>
+ <block atomic="true">
+ <set>
+ <parameter name='vf-module-length' value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module_length`' />
+ </set>
+ <for index='idx' start='0' end='`$vf-module-length`' >
+ <switch test="`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$idx].vf-module-id == $vf-module-topology-operation-input.vf-module-information.vf-module-id`">
+ <outcome value='true'>
+ <block atomic="true">
+ <set>
+ <parameter name='tmp.vidx' value='`$idx`' />
+ <parameter name='ctx.vf-module-data.' value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$idx].vf-module-data.`' />
+ </set>
+ <set>
+ <parameter name='vf-module-request-input.' value='`$ctx.vf-module-data.vf-module-request-input.`' />
+ </set>
+ <call module='GENERIC-RESOURCE-API' rpc='sdwan-get-vf-module-lanport-param' mode='sync' ></call>
+ </block>
+ </outcome>
+ </switch>
+ </for>
+ </block>
+ </outcome>
+ </switch>
+ <for index='vnfidx' start='0' end='`$service-data.vnfs.vnf_length`' >
+ <for index='vfidx' start='0' end='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module_length`' >
+ <for index='pidx' start='0' end='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param_length`' >
+ <switch test="`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].value == '$prop.lan.deviceName'`">
+ <outcome value='true'>
+ <block atomic="true">
+ <set>
+ <parameter name='prop.vnf-id' value='`$service-data.vnfs.vnf[$vnfidx].vnf-id`' />
+ </set>
+ <for index='pidx' start='0' end='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param_length`' >
+ <switch test="`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].name == 'deviceId'`">
+ <outcome value='true'>
+ <set>
+ <parameter name='prop.lan.deviceId' value='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].value`' />
+ </set>
+ </outcome>
+ </switch>
+ </for>
+ </block>
+ </outcome>
+ </switch>
+ </for>
+ </for>
+ </for>
+ <set>
+ <parameter name='prop.siteAttachements_length' value='0' />
+ <parameter name='prop.siteIds_length' value='0' />
+ </set>
+ <for index='vnfidx' start='0' end='`$service-data.vnfs.vnf_length`' >
+ <switch test="`$service-data.vnfs.vnf[$vnfidx].vnf-id == $prop.vnf-id`">
+ <outcome value='false'>
+ <for index='vfidx' start='0' end='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module_length`' >
+ <block>
+ <record plugin="org.onap.ccsdk.sli.core.sli.recording.FileRecorder">
+ <parameter name="file" value="/opt/opendaylight/current/data/log/svclogic24.log"/>
+ <parameter name="field1" value="__TIMESTAMP__"/>
+ <parameter name="field2" value="request-action"/>
+ <parameter name="field3" value='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.request-information.request-action`'/>
+ </record>
+ <!--switch test="`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.request-information.request-action == 'ActivateSDWANSiteInstance'`"-->
+ <switch test="`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.request-information.request-action == 'ActivateSiteInstance'`">
+ <outcome value='true'>
+ <for index='pidx' start='0' end='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param_length`' >
+ <block atomic="true">
+ <record plugin="org.onap.ccsdk.sli.core.sli.recording.FileRecorder">
+ <parameter name="file" value="/opt/opendaylight/current/data/log/svclogic23.log"/>
+ <parameter name="field1" value="__TIMESTAMP__"/>
+ <parameter name="field2" value="param-name"/>
+ <parameter name="field3" value='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].name`'/>
+ </record>
+ <switch test="`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].name == 'role'`">
+ <outcome value='true'>
+ <block atomic="true">
+ <switch test="`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].value == 'sd-wan-edge'`">
+ <outcome value='true'>
+ <set>
+ <parameter name='prop.role' value="spoke" />
+ </set>
+ </outcome>
+ </switch>
+ <switch test="`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].name == 'dsvpn-hub'`">
+ <outcome value='true'>
+ <set>
+ <parameter name='prop.role' value="hub" />
+ </set>
+ </outcome>
+ </switch>
+ </block>
+ </outcome>
+ </switch>
+ <switch test="`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].name == 'siteId'`">
+ <outcome value='true'>
+ <block atomic="true">
+ <set>
+ <parameter name='prop.attach.siteId' value='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].value`' />
+ </set>
+ <set>
+ <parameter name='prop.siteIds[$prop.siteIds_length]' value='`$prop.attach.siteId`' />
+ <parameter name='prop.siteIds_length' value='`$prop.siteIds_length + 1`' />
+ </set>
+ <set>
+ <parameter name='prop.siteAttachements[$prop.siteAttachements_length].siteId' value='`$prop.attach.siteId`' />
+ <parameter name='prop.siteAttachements[$prop.siteAttachements_length].roles[0]' value='`$prop.role`' />
+ <parameter name='prop.siteAttachements[$prop.siteAttachements_length].roles_length' value='1' />
+ <parameter name='prop.siteAttachements_length' value='`$prop.siteAttachements_length + 1`' />
+ </set>
+ </block>
+ </outcome>
+ </switch>
+ </block>
+ </for>
+ </outcome>
+ </switch>
+ <switch test="`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.request-information.request-action == 'ActivateSDWANVpnInstance'`">
+ <outcome value='true'>
+ <for index='pidx' start='0' end='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param_length`' >
+ <switch test="`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].name == 'vpn-id'`">
+ <outcome value='true'>
+ <set>
+ <parameter name='prop.vpn1Id' value='`$service-data.vnfs.vnf[$vnfidx].vnf-data.vf-modules.vf-module[$vfidx].vf-module-data.vf-module-request-input.vf-module-input-parameters.param[$pidx].value`' />
+ </set>
+ </outcome>
+ </switch>
+ </for>
+ </outcome>
+ </switch>
+ </block>
+ </for>
+ </outcome>
+ </switch>
+ </for>
+ <get-resource plugin="org.onap.ccsdk.sli.adaptors.aai.AAIService"
+ resource="esr-thirdparty-sdnc"
+ key="esr-thirdparty-sdnc.thirdparty-sdnc-id = SDWANController AND
+ depth = '1'"
+ pfx='tmp.aai.esr-thirdparty-sdnc' local-only='false' >
+ <outcome value='success'>
+ <set>
+ <parameter name='prop.sdncRestApi.thirdpartySdnc.url' value="`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].service-url`" />
+ <parameter name='prop.sdncRestApi.thirdpartySdnc.user' value="`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].user-name`" />
+ <parameter name='prop.sdncRestApi.thirdpartySdnc.password' value="`$tmp.aai.esr-thirdparty-sdnc.esr-system-info-list.esr-system-info[0].password`" />
+ </set>
+ </outcome>
+ <outcome value='not-found'>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`'An error occurred while querying esr-thirdparty-sdnc from AnAI with thirdparty-sdnc-id = ' + $tmp.thirdparty-sdnc-id`" />
+ </return>
+ </outcome>
+ <outcome value='Other'>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`'Unexpected error occurred while querying esr-thirdparty-sdnc from AnAI with thirdparty-sdnc-id = ' + $tmp.thirdparty-sdnc-id`" />
+ </return>
+ </outcome>
+ </get-resource>
+ <execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >
+ <parameter name="templateFileName" value="`$prop.restapi.templateDir + '/actokentemplate.json'`" />
+ <parameter name="restapiUrl" value="`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/v2/tokens'`" />
+ <parameter name="format" value="json"/>
+ <parameter name="httpMethod" value="post"/>
+ <parameter name="responsePrefix" value="token-result"/>
+ <parameter name="trustStoreFileName" value="/opt/onap/sdnc/data/stores/truststore.onap.client.jks"/>
+ <parameter name="trustStorePassword" value="adminadmin"/>
+ <parameter name="keyStoreFileName" value="/opt/onap/sdnc/data/stores/sdnc.p12"/>
+ <parameter name="keyStorePassword" value="adminadmin"/>
+ <outcome value='success'>
+ <set>
+ <parameter name='prop.sdncRestApi.token_id' value='`$token-result.data.token_id`' />
+ </set>
+ </outcome>
+ <outcome value='failure'>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="Error executing get token rest api" />
+ </return>
+ </outcome>
+ </execute>
+ <call module='GENERIC-RESOURCE-API' rpc='sdwan-get-tenant-auth' mode='sync' ></call>
+ <execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >
+ <parameter name="templateFileName" value="`$prop.restapi.templateDir + '/sdlan-port-del.json'`" />
+ <parameter name="restapiUrl" value="`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/net/ports/action/batch-delete'`" />
+ <parameter name="restapiUser" value="`$prop.sdncRestApi.thirdpartySdnc.user`" />
+ <parameter name="restapiPassword" value="`$prop.sdncRestApi.thirdpartySdnc.password`" />
+ <parameter name="format" value="json"/>
+ <parameter name="httpMethod" value="post"/>
+ <parameter name="responsePrefix" value="portResp"/>
+ <parameter name="trustStoreFileName" value="/opt/onap/sdnc/data/stores/truststore.onap.client.jks"/>
+ <parameter name="trustStorePassword" value="adminadmin"/>
+ <parameter name="keyStoreFileName" value="/opt/onap/sdnc/data/stores/sdnc.p12"/>
+ <parameter name="keyStorePassword" value="adminadmin"/>
+ <parameter name='customHttpHeaders' value="`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`" />
+ <outcome value='failure'>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="Error executing Create device port rest api" />
+ </return>
+ </outcome>
+ <outcome value='success'>
+ <block atomic="true"></block>
+ </outcome>
+ </execute>
+ <switch test="`$prop.lan.portSwitch == 'layer2-port'`">
+ <outcome value='true'>
+ <execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >
+ <parameter name="templateFileName" value="`$prop.restapi.templateDir + '/sdlan-bridge-domain.json'`" />
+ <parameter name="restapiUrl" value="`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/overlay-network/bridge-domains'`" />
+ <parameter name="restapiUser" value="`$prop.sdncRestApi.thirdpartySdnc.user`" />
+ <parameter name="restapiPassword" value="`$prop.sdncRestApi.thirdpartySdnc.password`" />
+ <parameter name="format" value="json"/>
+ <parameter name="httpMethod" value="post"/>
+ <parameter name="responsePrefix" value="bridgeDomainResp"/>
+ <parameter name="trustStoreFileName" value="/opt/onap/sdnc/data/stores/truststore.onap.client.jks"/>
+ <parameter name="trustStorePassword" value="adminadmin"/>
+ <parameter name="keyStoreFileName" value="/opt/onap/sdnc/data/stores/sdnc.p12"/>
+ <parameter name="keyStorePassword" value="adminadmin"/>
+ <parameter name='customHttpHeaders' value="`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`" />
+ <outcome value='failure'>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="Error executing Create bridge domain rest api" />
+ </return>
+ </outcome>
+ <outcome value='success'>
+ <block atomic="true"></block>
+ </outcome>
+ </execute>
+ </outcome>
+ </switch>
+ <execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='split' >
+ <parameter name="original_string" value='`$prop.lan.ipAddress`'/>
+ <parameter name="regex" value="/"/>
+ <parameter name="ctx_memory_result_key" value="ipandMask"/>
+ <outcome value='success'>
+ <set>
+ <parameter name='prop.lan.ip-address' value='`$ipandMask[0]`' />
+ <parameter name='prop.lan.prefixLength' value='`$ipandMask[1]`' />
+ </set>
+ </outcome>
+ <outcome value='failure'>
+ <return status='failure'>
+ <parameter name='error-code' value='' />
+ <parameter name='error-message' value="An error occured while splitting sna1_route" />
+ </return>
+ </outcome>
+ </execute>
+ <execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >
+ <parameter name="templateFileName" value="`$prop.restapi.templateDir + '/sdlan-ip-subnets-del.json'`" />
+ <parameter name="restapiUrl" value="`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/overlay-network/ip-subnets/action/batch-delete'`" />
+ <parameter name="restapiUser" value="`$prop.sdncRestApi.thirdpartySdnc.user`" />
+ <parameter name="restapiPassword" value="`$prop.sdncRestApi.thirdpartySdnc.password`" />
+ <parameter name="format" value="json"/>
+ <parameter name="httpMethod" value="post"/>
+ <parameter name="responsePrefix" value="lanPortResp"/>
+ <parameter name="trustStoreFileName" value="/opt/onap/sdnc/data/stores/truststore.onap.client.jks"/>
+ <parameter name="trustStorePassword" value="adminadmin"/>
+ <parameter name="keyStoreFileName" value="/opt/onap/sdnc/data/stores/sdnc.p12"/>
+ <parameter name="keyStorePassword" value="adminadmin"/>
+ <parameter name='customHttpHeaders' value="`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`" />
+ <outcome value='failure'>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="Error executing Create device port rest api" />
+ </return>
+ </outcome>
+ <outcome value='success'>
+ <block atomic="true">
+ <set>
+ <parameter name='prop.lan.lanPortId' value='`lanPortResp.success[0].id`' />
+ </set>
+ </block>
+ </outcome>
+ </execute>
+ <execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >
+ <parameter name="templateFileName" value="`$prop.restapi.templateDir + '/sdwan-vpn.json'`" />
+ <parameter name="restapiUrl" value="`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/overlay-network/vpn'`" />
+ <parameter name="restapiUser" value="`$prop.sdncRestApi.thirdpartySdnc.user`" />
+ <parameter name="restapiPassword" value="`$prop.sdncRestApi.thirdpartySdnc.password`" />
+ <parameter name="format" value="json"/>
+ <parameter name="httpMethod" value="put"/>
+ <parameter name="responsePrefix" value="vpn-result"/>
+ <parameter name="trustStoreFileName" value="/opt/onap/sdnc/data/stores/truststore.onap.client.jks"/>
+ <parameter name="trustStorePassword" value="adminadmin"/>
+ <parameter name="keyStoreFileName" value="/opt/onap/sdnc/data/stores/sdnc.p12"/>
+ <parameter name="keyStorePassword" value="adminadmin"/>
+ <parameter name='customHttpHeaders' value="`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`" />
+ <outcome value='failure'>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="Error executing Create vpn failed" />
+ </return>
+ </outcome>
+ <outcome value='success'>
+ <block atomic="true"></block>
+ </outcome>
+ </execute>
+ <execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >
+ <parameter name="templateFileName" value="`$prop.restapi.templateDir + '/sdwan-vpn-topology.json'`" />
+ <parameter name="restapiUrl" value="`$prop.sdncRestApi.thirdpartySdnc.url + '/controller/campus/v1/sdwan/overlay-network/' + $prop.vpn1Id + '/topology'`" />
+ <parameter name="restapiUser" value="`$prop.sdncRestApi.thirdpartySdnc.user`" />
+ <parameter name="restapiPassword" value="`$prop.sdncRestApi.thirdpartySdnc.password`" />
+ <parameter name="format" value="json"/>
+ <parameter name="httpMethod" value="put"/>
+ <parameter name="responsePrefix" value="vpn-result"/>
+ <parameter name="trustStoreFileName" value="/opt/onap/sdnc/data/stores/truststore.onap.client.jks"/>
+ <parameter name="trustStorePassword" value="adminadmin"/>
+ <parameter name="keyStoreFileName" value="/opt/onap/sdnc/data/stores/sdnc.p12"/>
+ <parameter name="keyStorePassword" value="adminadmin"/>
+ <parameter name='customHttpHeaders' value="`'X-ACCESS-TOKEN=' + $prop.sdncRestApi.token_id`" />
+ <outcome value='failure'>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="Error executing Create vpn topology failed" />
+ </return>
+ </outcome>
+ <outcome value='success'>
+ <block atomic="true"></block>
+ </outcome>
+ </execute>
+ <set>
+ <parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.sdnc-request-header.' value='`$vf-module-topology-operation-input.sdnc-request-header.`' />
+ <parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.request-information.' value='`$vf-module-topology-operation-input.request-information.`' />
+ <parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.service-information.' value='`$vf-module-topology-operation-input.service-information.`' />
+ <parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.vf-module-information.' value='`$vf-module-topology-operation-input.vf-module-information.`' />
+ </set>
+ <set>
+ <parameter name='vf-module-object-path' value="`'restconf/config/GENERIC-RESOURCE-API:services/service/'
+ + $vf-module-topology-operation-input.service-information.service-instance-id
+ + '/service-data/vnfs/vnf/'
+ + $service-data.vnfs.vnf[$vnf-index].vnf-id
+ + '/vnf-data/vf-modules/vf-module/'
+ + $vf-module-topology-operation-input.vf-module-information.vf-module-id
+ + '/vf-module-data/vf-module-topology/'`"/>
+ <parameter name='vnf-object-path'
+ value="`'restconf/config/GENERIC-RESOURCE-API:services/service/'
+ + $vf-module-topology-operation-input.service-information.service-instance-id
+ + '/service-data/vnfs/vnf/'
+ + $service-data.vnfs.vnf[$vnf-index].vnf-id
+ + '/vnf-data/vnf-topology/'`"/>
+ <parameter name='service-object-path'
+ value="`'restconf/config/GENERIC-RESOURCE-API:services/service/'
+ + $vf-module-topology-operation-input.service-information.service-instance-id
+ + '/service-data/service-topology/'`"/>
+ </set>
+ <set>
+ <parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.vf-module-level-oper-status.order-status' value='PendingDelete' />
+ <parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.vf-module-level-oper-status.last-rpc-action' value='`$vf-module-topology-operation-input.sdnc-request-header.svc-action`' />
+ <parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.vf-module-level-oper-status.last-action' value='`$vf-module-topology-operation-input.sdnc-request-header.request-action`' />
+ </set>
+ <update plugin='org.onap.ccsdk.sli.adaptors.aai.AAIService' resource='lan-port-config'
+ key='sdwan-vpn.sdwan-vpn-id = $vf-module-topology-operation-input.vf-module-information.vf-module-id' >
+ <parameter name='sdwan-vpn-id' value='`$vf-module-topology-operation-input.vf-module-information.vf-module-id`' />
+ <parameter name='operational-status' value='PendingDelete' />
+ <parameter name='lan-port-config-id' value='`$prop.lan-port-config-id`' />
+ </update>
+ <return status='success'>
+ <parameter name="ack-final-indicator" value="Y" />
+ <parameter name="error-code" value="200" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </method>
+</service-logic>
\ No newline at end of file diff --git a/platform-logic/generic-resource-api/src/main/xml/sdwan/GENERIC-RESOURCE-API_sdwan-vf-operation-lanport-delete.xml b/platform-logic/generic-resource-api/src/main/xml/sdwan/GENERIC-RESOURCE-API_sdwan-vf-operation-lanport-delete.xml new file mode 100644 index 00000000..5fb67357 --- /dev/null +++ b/platform-logic/generic-resource-api/src/main/xml/sdwan/GENERIC-RESOURCE-API_sdwan-vf-operation-lanport-delete.xml @@ -0,0 +1,138 @@ +<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}'>
+ <method rpc='sdwan-vf-operation-lanport-delete' mode='sync'>
+ <block atomic="true">
+ <switch test='`$service-data.vnfs.vnf_length`'>
+ <outcome value=''>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="vnf-topology-operation-input.vnf-request-input.vnf-id not found in service-data" />
+ </return>
+ </outcome>
+ </switch>
+ <for index='idx' start='0' end='`$service-data.vnfs.vnf_length`' >
+ <switch test="`$service-data.vnfs.vnf[$idx].vnf-id == $vf-module-topology-operation-input.vnf-information.vnf-id`">
+ <outcome value='true'>
+ <set>
+ <parameter name='vnf-index' value='`$idx`' />
+ </set>
+ </outcome>
+ </switch>
+ </for>
+ <switch test='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module_length`'>
+ <outcome value='0'>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="vnf-topology-operation-input.vnf-request-input.vnf-id not found in service-data" />
+ </return>
+ </outcome>
+ <outcome value=''>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="vnf-topology-operation-input.vnf-request-input.vnf-id not found in service-data" />
+ </return>
+ </outcome>
+ <outcome value='Other'>
+ <block atomic="true">
+ <set>
+ <parameter name='vf-module-length' value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module_length`' />
+ </set>
+ <for index='idx' start='0' end='`$vf-module-length`' >
+ <switch test="`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$idx].vf-module-id == $vf-module-topology-operation-input.vf-module-information.vf-module-id`">
+ <outcome value='true'>
+ <block atomic="true">
+ <set>
+ <parameter name='tmp.vidx' value='`$idx`' />
+ <parameter name='ctx.vf-module-data.' value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$idx].vf-module-data.`' />
+ </set>
+ <set>
+ <parameter name='vf-module-request-input.' value='`$ctx.vf-module-data.vf-module-request-input.`' />
+ </set>
+ <call module='GENERIC-RESOURCE-API' rpc='sdwan-get-vf-module-lan-param' mode='sync' ></call>
+ </block>
+ </outcome>
+ </switch>
+ </for>
+ </block>
+ </outcome>
+ </switch>
+ <switch test="`$tmp.vidx`">
+ <outcome value=''>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="vnf-topology-operation-input.vnf-request-input.vnf-id not found in service-data" />
+ </return>
+ </outcome>
+ </switch>
+ <switch test='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$tmp.vidx].vf-module-data.vf-module-level-oper-status.order-status`'>
+ <outcome value='PendingDelete'>
+ <block atomic="true"></block>
+ </outcome>
+ <outcome value='Other'>
+ <return status='failure'>
+ <parameter name='ack-final' value='Y'/>
+ <parameter name="error-code" value="500" />
+ <parameter name="error-message" value="`'VNF is not in appropriate state for activate. Current state is ' + $service-data.vnfs.vnf[$tmp.nidx].vnf-data.vnf-level-oper-status.order-status`" />
+ </return>
+ </outcome>
+ </switch>
+ <set>
+ <parameter name='prop.vnfidxLen' value='`0`' />
+ </set>
+ <for index='lidx' start='0' end='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module_length`' >
+ <block atomic="true">
+ <switch test="`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$lidx].vf-module-data.vf-module-information.vf-module-id == $vf-module-topology-operation-input.vf-module-information.vf-module-id`">
+ <outcome value='false'>
+ <block atomic="true">
+ <set>
+ <parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$prop.vnfidxLen].vnf-id' value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[lidx].vf-module-id`' />
+ <parameter name='service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$prop.vnfidxLen].vnf-data.' value='`$service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[lidx].vf-module-data.`' />
+ </set>
+ <set>
+ <parameter name='prop.vnfidxLen' value='`$prop.vnfidxLen + 1`' />
+ </set>
+ </block>
+ </outcome>
+ </switch>
+ </block>
+ </for>
+ <set>
+ <parameter name="service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module_length" value='`$prop.vnfidxLen`'/>
+ </set>
+ <set>
+ <parameter name="service-data.vnfs.vnf[$vnf-index].vnf-data.vf-modules.vf-module[$prop.vnfidxLen]." value=""/>
+ </set>
+ <set>
+ <parameter name='vf-module-object-path' value="`'restconf/config/GENERIC-RESOURCE-API:services/service/'
+ + $vf-module-topology-operation-input.service-information.service-instance-id
+ + '/service-data/vnfs/vnf/'
+ + $service-data.vnfs.vnf[$vnf-index].vnf-id
+ + '/vnf-data/vf-modules/vf-module/'
+ + $vf-module-topology-operation-input.vf-module-information.vf-module-id
+ + '/vf-module-data/vf-module-topology/'`"/>
+ <parameter name='vnf-object-path'
+ value="`'restconf/config/GENERIC-RESOURCE-API:services/service/'
+ + $vf-module-topology-operation-input.service-information.service-instance-id
+ + '/service-data/vnfs/vnf/'
+ + $service-data.vnfs.vnf[$vnf-index].vnf-id
+ + '/vnf-data/vnf-topology/'`"/>
+ <parameter name='service-object-path'
+ value="`'restconf/config/GENERIC-RESOURCE-API:services/service/'
+ + $vf-module-topology-operation-input.service-information.service-instance-id
+ + '/service-data/service-topology/'`"/>
+ </set>
+ <delete plugin="org.onap.ccsdk.sli.adaptors.aai.AAIService" resource='lan-port-config'
+ key='site-resource.site-resource-id = $vf-module-topology-operation-input.vf-module-information.vf-module-id'></delete>
+ <return status='success'>
+ <parameter name="ack-final-indicator" value="Y" />
+ <parameter name="error-code" value="200" />
+ <parameter name="error-message" value="`$error-message`" />
+ </return>
+ </block>
+ </method>
+</service-logic>
\ No newline at end of file |