diff options
author | ychacon <yennifer.chacon@est.tech> | 2021-08-18 15:44:42 +0200 |
---|---|---|
committer | ychacon <yennifer.chacon@est.tech> | 2021-08-20 14:05:13 +0200 |
commit | 98f8fdb9fc6ca51615e2a70614f43e19ad8bcafe (patch) | |
tree | 362694c13b32a360ec7ee8f21535c051ccff3d70 /platform-logic | |
parent | 7cd7fe946ae07d21a3daf57a5f2868f4b4b2e7fc (diff) |
HTTPS Proxy support for A1 adapter southbound
Issue-ID: CCSDK-3153
Signed-off-by: ychacon <yennifer.chacon@est.tech>
Change-Id: I454e7f80ee0ccd94bc5a034dedc201a37e0dfc58
Diffstat (limited to 'platform-logic')
10 files changed, 1720 insertions, 520 deletions
diff --git a/platform-logic/a1Adapter-api/src/main/json/A1-ADAPTER-API_deleteA1Policy.json b/platform-logic/a1Adapter-api/src/main/json/A1-ADAPTER-API_deleteA1Policy.json index 89c14a88..bae3ba86 100644 --- a/platform-logic/a1Adapter-api/src/main/json/A1-ADAPTER-API_deleteA1Policy.json +++ b/platform-logic/a1Adapter-api/src/main/json/A1-ADAPTER-API_deleteA1Policy.json @@ -1,6 +1,6 @@ [ { - "id": "7c435ae3.69565c", + "id": "40b94c2a.1d5be4", "type": "service-logic", "name": "A1-ADAPTER-API ${project.version}", "module": "A1-ADAPTER-API", @@ -8,310 +8,507 @@ "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='A1-ADAPTER-API' version='${project.version}'>", "outputs": 1, - "x": 188, - "y": 153, - "z": "cb244f73.c06648", + "x": 194, + "y": 237, + "z": "5421e0da.e98ea", "wires": [ [ - "710b1a71.cbae84" + "c8e7631.2112ba" ] ] }, { - "id": "710b1a71.cbae84", + "id": "c8e7631.2112ba", "type": "method", "name": "method deleteA1Policy", "xml": "<method rpc='deleteA1Policy' mode='sync'>\n", "comments": "", "outputs": 1, - "x": 248, - "y": 273, - "z": "cb244f73.c06648", + "x": 254, + "y": 357, + "z": "5421e0da.e98ea", "wires": [ [ - "4378a18e.7f739" + "4faf22ab.4c738c" ] ] }, { - "id": "6ce20bdf.ad9a1c", + "id": "166f48b5.9a3a17", "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/A1-Adapter.log\" />\n<parameter name=\"level\" value=\"info\" />\n<parameter name=\"field1\" value=\"Delete Policy:\"/>\n<parameter name=\"field2\" value=\"`$delete-a1-policy-input.near-rt-ric-url`\"/>", + "xml": "<record plugin=\"org.onap.ccsdk.sli.core.sli.recording.FileRecorder\">\n<parameter name=\"file\" value=\"/opt/opendaylight/current/data/log/A1-Adapter.log\" />\n<parameter name=\"level\" value=\"info\" />\n<parameter name=\"field1\" value=\"Delete A1 Policy:\"/>\n<parameter name=\"field2\" value=\"`$delete-a1-policy-input.near-rt-ric-url`\"/>", "comments": "", "outputs": 1, - "x": 712, - "y": 87, - "z": "cb244f73.c06648", + "x": 718, + "y": 171, + "z": "5421e0da.e98ea", "wires": [ [] ] }, { - "id": "4378a18e.7f739", + "id": "4faf22ab.4c738c", "type": "block", "name": "block : atomic", "xml": "<block atomic='true'>", "atomic": "true", "comments": "", "outputs": 1, - "x": 453, - "y": 227, - "z": "cb244f73.c06648", + "x": 459, + "y": 311, + "z": "5421e0da.e98ea", "wires": [ [ - "6ce20bdf.ad9a1c", - "e5238148.fd374", - "bdf5754e.9b53f8", - "7e804e03.9c90b", - "fb64d04f.8f7d68" + "166f48b5.9a3a17", + "b2679b68.1462c8", + "4148a57a.c7efcc", + "f504796c.262f88", + "aba0ccb1.73758" ] ] }, { - "id": "ee4edddb.f32858", + "id": "4e2bdc30.8909a4", "type": "dgstart", "name": "DGSTART", "outputs": 1, - "x": 120, - "y": 89, - "z": "cb244f73.c06648", + "x": 126, + "y": 173, + "z": "5421e0da.e98ea", "wires": [ [ - "7c435ae3.69565c" + "40b94c2a.1d5be4" ] ] }, { - "id": "e5238148.fd374", + "id": "b2679b68.1462c8", "type": "set", "name": "set default status value", "xml": "<set>\n<parameter name='response-code' value='200' />\n<parameter name='response-message' value='deletePolicy executed successfully' />", "comments": "", - "x": 753.0000610351562, - "y": 142, - "z": "cb244f73.c06648", + "x": 759.0000610351562, + "y": 226, + "z": "5421e0da.e98ea", "wires": [] }, { - "id": "bdf5754e.9b53f8", + "id": "4148a57a.c7efcc", "type": "execute", "name": "execute Properties", "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.prop.PropertiesNode' method='readProperties' >\n <parameter name='fileName' value='/opt/onap/ccsdk/data/properties/a1-adapter-api-dg.properties' />\n <parameter name='contextPrefix' value='prop' />\n", "comments": "", "outputs": 1, - "x": 752, - "y": 195, - "z": "cb244f73.c06648", + "x": 758, + "y": 279, + "z": "5421e0da.e98ea", "wires": [ [] ] }, { - "id": "fb64d04f.8f7d68", + "id": "aba0ccb1.73758", "type": "block", "name": "A1 Mediator RestAPI Invocation", "xml": "<block atomic='true'>", "atomic": "true", "comments": "", "outputs": 1, - "x": 782.0001220703125, - "y": 279, - "z": "cb244f73.c06648", + "x": 788.0001220703125, + "y": 363, + "z": "5421e0da.e98ea", "wires": [ [ - "3f182409.0c3914", - "e320e99b.0be3e", - "a9c27d26.b87628" + "c6ab5263.f678d", + "5cd5776d.1e0278", + "628e7bf2.7d9964", + "793b4300.b8738c" ] ] }, { - "id": "e320e99b.0be3e", + "id": "5cd5776d.1e0278", "type": "set", "name": "set tmp variables for A1 Mediator REST API call", "xml": "<set>\n<parameter name=\"tmp.near-rt-ric-url\" value=\"`$delete-a1-policy-input.near-rt-ric-url`\"/>", "comments": "", - "x": 1144.00146484375, - "y": 171.88912963867188, - "z": "cb244f73.c06648", + "x": 1161.00146484375, + "y": 136.88912963867188, + "z": "5421e0da.e98ea", "wires": [] }, { - "id": "3f182409.0c3914", + "id": "c6ab5263.f678d", "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/A1-Adapter.log\" />\n<parameter name=\"level\" value=\"info\" />\n<parameter name=\"field1\" value=\"Setting variables for A1 Adapter Delete Policy Instance.\"/>\n<parameter name=\"field2\" value=\"`$tmp.near-rt-ric-url`\"/>", "comments": "", "outputs": 1, - "x": 1032.0001220703125, - "y": 261, - "z": "cb244f73.c06648", + "x": 1056.0001220703125, + "y": 461, + "z": "5421e0da.e98ea", "wires": [ [] ] }, { - "id": "a9c27d26.b87628", + "id": "628e7bf2.7d9964", "type": "execute", "name": "Delete Policy Instance", "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"restapiUrl\" value=\"`$tmp.near-rt-ric-url`\"/>\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"DELETE\"/>\n<parameter name=\"responsePrefix\" value=\"a1MediatorRsp\"/>\n<parameter name='contentType' value='application/json' />\n<parameter name='accept' value='application/json' />\n<parameter name=\"convertResponse\" value=\"false\"/>", "comments": "", "outputs": 1, - "x": 1077.0006103515625, - "y": 343.0104064941406, - "z": "cb244f73.c06648", + "x": 1096.0006103515625, + "y": 536.0104064941406, + "z": "5421e0da.e98ea", "wires": [ [ - "17d809ef.941376", - "c9c13643.42fb78" + "2eaa9315.f1267c", + "1b5b58af.e3d147" ] ] }, { - "id": "17d809ef.941376", + "id": "2eaa9315.f1267c", "type": "failure", "name": "failure", "xml": "<outcome value='failure'>\n", "comments": "", "outputs": 1, - "x": 1304, - "y": 412.0001220703125, - "z": "cb244f73.c06648", + "x": 1325, + "y": 625.0001220703125, + "z": "5421e0da.e98ea", "wires": [ [ - "8a649ed7.63deb" + "8fd194ab.4d6f48" ] ] }, { - "id": "c9c13643.42fb78", + "id": "1b5b58af.e3d147", "type": "success", "name": "success", "xml": "<outcome value='success'>\n", "comments": "", "outputs": 1, - "x": 1294.000244140625, - "y": 257.0000305175781, - "z": "cb244f73.c06648", + "x": 1315.000244140625, + "y": 470.0000305175781, + "z": "5421e0da.e98ea", "wires": [ [ - "d953eb99.f4fcc" + "4ca53b3d.e09944" ] ] }, { - "id": "cafd39a2.e592f", + "id": "c96895f9.6920d8", "type": "returnFailure", "name": "return failure", "xml": "<return status='failure'>\n<parameter name='ack-final' value='Y'/>\n<parameter name=\"response-code\" value=\"404\" />\n<parameter name=\"response-message\" value=\"Error in Deleting A1 Policy Instance. Aborting\" />", "comments": "", - "x": 1627.0006103515625, - "y": 467.00006103515625, - "z": "cb244f73.c06648", + "x": 1648.0006103515625, + "y": 680.0000610351562, + "z": "5421e0da.e98ea", "wires": [] }, { - "id": "d953eb99.f4fcc", + "id": "4ca53b3d.e09944", "type": "block", "name": "block", "xml": "<block>\n", "atomic": "false", "comments": "", "outputs": 1, - "x": 1467.9998779296875, - "y": 257.00006103515625, - "z": "cb244f73.c06648", + "x": 1488.9998779296875, + "y": 470.00006103515625, + "z": "5421e0da.e98ea", "wires": [ [ - "b7919ed2.bc4b8", - "76b0ec4a.812af4" + "e8211cdb.f1c0b", + "4e8c89de.7e4e78" ] ] }, { - "id": "b7919ed2.bc4b8", + "id": "e8211cdb.f1c0b", "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/A1-Adapter.log\" />\n<parameter name=\"level\" value=\"info\" />\n<parameter name=\"field1\" value=\"A1 Delete Policy Information \"/>\n<parameter name=\"field2\" value=\"`$a1MediatorRsp.httpResponse`\"/>", "comments": "", "outputs": 1, - "x": 1625, - "y": 203, - "z": "cb244f73.c06648", + "x": 1646, + "y": 416, + "z": "5421e0da.e98ea", "wires": [ [] ] }, { - "id": "2d7fa547.79bee2", + "id": "ab28de1f.ae2e2", "type": "set", "name": "set", "xml": "<set>\n<parameter name='response-code' value='500'/>\n<parameter name='response-message' value='Seems A1 Mediator Not Healthy'/>\n", "comments": "", - "x": 1600.75390625, - "y": 360.00390625, - "z": "cb244f73.c06648", + "x": 1621.75390625, + "y": 573.00390625, + "z": "5421e0da.e98ea", "wires": [] }, { - "id": "7e804e03.9c90b", + "id": "f504796c.262f88", "type": "block", "name": "block", "xml": "<block>\n", "atomic": "false", "comments": "", "outputs": 1, - "x": 715.75390625, - "y": 451.00390625, - "z": "cb244f73.c06648", + "x": 697.75390625, + "y": 545.00390625, + "z": "5421e0da.e98ea", "wires": [ [ - "23ec5862.ce8f7" + "2fbb20e3.ff965" ] ] }, { - "id": "23ec5862.ce8f7", + "id": "2fbb20e3.ff965", "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<parameter name='response-code' value='200' />\n<parameter name='response-message' value='deletePolicyInstance executed successfully'/>\n<parameter name='ack-final' value='Y'/>\n", "comments": "", - "x": 876.7539672851562, - "y": 451.00396728515625, - "z": "cb244f73.c06648", + "x": 858.7539672851562, + "y": 545.0039672851562, + "z": "5421e0da.e98ea", "wires": [] }, { - "id": "8a649ed7.63deb", + "id": "8fd194ab.4d6f48", "type": "block", "name": "block", "xml": "<block>\n", "atomic": "false", "comments": "", "outputs": 1, - "x": 1459.00390625, - "y": 411.0039367675781, - "z": "cb244f73.c06648", + "x": 1480.00390625, + "y": 624.0039367675781, + "z": "5421e0da.e98ea", "wires": [ [ - "2d7fa547.79bee2", - "cafd39a2.e592f" + "ab28de1f.ae2e2", + "c96895f9.6920d8" ] ] }, { - "id": "76b0ec4a.812af4", + "id": "4e8c89de.7e4e78", "type": "execute", "name": "set", "xml": "<set>\n<parameter name='body' value='`$a1MediatorRsp.httpResponse`'/>", "comments": "", "outputs": 1, - "x": 1631, - "y": 307, - "z": "cb244f73.c06648", + "x": 1652, + "y": 520, + "z": "5421e0da.e98ea", + "wires": [ + [] + ] + }, + { + "id": "19e9382.863dfc8", + "type": "execute", + "name": "split near-rt-ric URL", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='split'>\n <parameter name=\"original_string\" value=\"`$tmp.near-rt-ric-url`\" />\n <parameter name=\"regex\" value=\"/\"/>\n <parameter name=\"ctx_memory_result_key\" value=\"tmp.near-rt-ric-url-splitList\"/>", + "comments": "", + "outputs": 1, + "x": 2055, + "y": 252, + "z": "5421e0da.e98ea", + "wires": [ + [] + ] + }, + { + "id": "df43d920.c48608", + "type": "for", + "name": "for", + "xml": "<for index='idx' start='3' end=\"`$tmp.near-rt-ric-url-splitList_length`\" >", + "comments": "", + "outputs": 1, + "x": 2021, + "y": 322, + "z": "5421e0da.e98ea", + "wires": [ + [ + "e32aea7c.0c7418" + ] + ] + }, + { + "id": "e32aea7c.0c7418", + "type": "execute", + "name": "set concat url", + "xml": "<set>\n<parameter name='tmp.proxy-url' value=\"`$tmp.proxy-url +'/' + $tmp.near-rt-ric-url-splitList[$idx] `\" />\n\n\n", + "comments": "", + "outputs": 1, + "x": 2199, + "y": 322, + "z": "5421e0da.e98ea", + "wires": [ + [] + ] + }, + { + "id": "695b0eaa.faece", + "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/A1-Adapter.log\" />\n<parameter name=\"level\" value=\"info\" />\n<parameter name=\"field1\" value=\"Delete A1 Policy: Url with proxy: \"/>\n<parameter name=\"field2\" value=\"`$tmp.proxy-url`\"/>\n\n", + "comments": "", + "outputs": 1, + "x": 2021, + "y": 376, + "z": "5421e0da.e98ea", + "wires": [ + [] + ] + }, + { + "id": "c793909b.fccf4", + "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/A1-Adapter.log\" />\n<parameter name=\"level\" value=\"info\" />\n<parameter name=\"field1\" value=\"Delete A1 Policy: No proxy found on properties file \"/>\n", + "comments": "", + "outputs": 1, + "x": 1825, + "y": 288, + "z": "5421e0da.e98ea", + "wires": [ + [] + ] + }, + { + "id": "dbb430eb.1e3ee", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1817, + "y": 356, + "z": "5421e0da.e98ea", + "wires": [ + [ + "19e9382.863dfc8", + "df43d920.c48608", + "695b0eaa.faece", + "cb7535ae.d9c2b8" + ] + ] + }, + { + "id": "cb7535ae.d9c2b8", + "type": "set", + "name": "set variables for A1 Mediator with proxy url", + "xml": "<set>\n<parameter name=\"tmp.near-rt-ric-url\" value=\"`$tmp.proxy-url`\"/>", + "comments": "", + "x": 2131, + "y": 435, + "z": "5421e0da.e98ea", + "wires": [] + }, + { + "id": "3bf50c57.2c0d74", + "type": "outcome", + "name": "No proxy URL", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 1657, + "y": 288, + "z": "5421e0da.e98ea", + "wires": [ + [ + "c793909b.fccf4" + ] + ] + }, + { + "id": "719dd702.c98f88", + "type": "outcome", + "name": "Otherwise", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 1653, + "y": 356, + "z": "5421e0da.e98ea", + "wires": [ + [ + "dbb430eb.1e3ee" + ] + ] + }, + { + "id": "77200c7b.1ac3f4", + "type": "set", + "name": "set tmp url variables with proxy information", + "xml": "<set>\n<parameter name=\"tmp.proxy-url\" value=\"`$prop.a1Mediator.proxy.url`\"/>", + "comments": "", + "x": 1596, + "y": 164, + "z": "5421e0da.e98ea", + "wires": [] + }, + { + "id": "f471f3e5.a3e5c", + "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/A1-Adapter.log\" />\n<parameter name=\"level\" value=\"info\" />\n<parameter name=\"field1\" value=\"Delete A1 Policy: Check for proxy url: \"/>\n<parameter name=\"field2\" value=\"`$tmp.proxy-url`\"/>\n\n", + "comments": "", + "outputs": 1, + "x": 1479, + "y": 239, + "z": "5421e0da.e98ea", "wires": [ [] ] + }, + { + "id": "d521b1c.f9f805", + "type": "switchNode", + "name": "switch", + "xml": "<switch test='`$tmp.proxy-url`'>\n", + "comments": "", + "outputs": 1, + "x": 1478, + "y": 322, + "z": "5421e0da.e98ea", + "wires": [ + [ + "3bf50c57.2c0d74", + "719dd702.c98f88" + ] + ] + }, + { + "id": "793b4300.b8738c", + "type": "block", + "name": "block Substitute proxy address if available", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1141, + "y": 321, + "z": "5421e0da.e98ea", + "wires": [ + [ + "77200c7b.1ac3f4", + "f471f3e5.a3e5c", + "d521b1c.f9f805" + ] + ] } ]
\ No newline at end of file diff --git a/platform-logic/a1Adapter-api/src/main/json/A1-ADAPTER-API_getA1Policy.json b/platform-logic/a1Adapter-api/src/main/json/A1-ADAPTER-API_getA1Policy.json index 65f97d08..679a5648 100644 --- a/platform-logic/a1Adapter-api/src/main/json/A1-ADAPTER-API_getA1Policy.json +++ b/platform-logic/a1Adapter-api/src/main/json/A1-ADAPTER-API_getA1Policy.json @@ -1,6 +1,6 @@ [ { - "id": "9623ac21.784518", + "id": "a60fb60b.241a28", "type": "service-logic", "name": "A1-ADAPTER-API ${project.version}", "module": "A1-ADAPTER-API", @@ -8,325 +8,522 @@ "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='A1-ADAPTER-API' version='${project.version}'>", "outputs": 1, - "x": 168, - "y": 142, - "z": "e064bcd1.68ce88", + "x": 175, + "y": 269, + "z": "7304d8ed.dab258", "wires": [ [ - "ccd84436.04e408" + "57fe6f06.92d82" ] ] }, { - "id": "ccd84436.04e408", + "id": "57fe6f06.92d82", "type": "method", "name": "method getA1Policy", "xml": "<method rpc='getA1Policy' mode='sync'>\n", "comments": "", "outputs": 1, - "x": 227, - "y": 263, - "z": "e064bcd1.68ce88", + "x": 234, + "y": 390, + "z": "7304d8ed.dab258", "wires": [ [ - "c915f152.8fae9" + "5bd5c7d.75cdd38" ] ] }, { - "id": "7b756479.f5b4c4", + "id": "6c7eeb3b.b216c4", "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/A1-Adapter.log\" />\n<parameter name=\"level\" value=\"info\" />\n<parameter name=\"field1\" value=\"Get A1 Policy:\"/>\n<parameter name=\"field2\" value=\"`$get-a1-policy-input.near-rt-ric-url`\"/>", "comments": "", "outputs": 1, - "x": 691, - "y": 77, - "z": "e064bcd1.68ce88", + "x": 695, + "y": 191, + "z": "7304d8ed.dab258", "wires": [ [] ] }, { - "id": "c915f152.8fae9", + "id": "5bd5c7d.75cdd38", "type": "block", "name": "block : atomic", "xml": "<block atomic='true'>", "atomic": "true", "comments": "", "outputs": 1, - "x": 432, - "y": 217, - "z": "e064bcd1.68ce88", + "x": 439, + "y": 344, + "z": "7304d8ed.dab258", "wires": [ [ - "7b756479.f5b4c4", - "ecf93800.1c6098", - "50c242ff.949c04", - "91f0150f.12ce4", - "63a848d9.da34b" + "6c7eeb3b.b216c4", + "ca0351d6.caa3e", + "18c8dded.66a2f2", + "236f6af1.570056", + "bfb54edb.3da1b" ] ] }, { - "id": "9209420.b905c4", + "id": "24f44e9b.4aa622", "type": "dgstart", "name": "DGSTART", "outputs": 1, - "x": 99, - "y": 79, - "z": "e064bcd1.68ce88", + "x": 106, + "y": 206, + "z": "7304d8ed.dab258", "wires": [ [ - "9623ac21.784518" + "a60fb60b.241a28" ] ] }, { - "id": "ecf93800.1c6098", + "id": "ca0351d6.caa3e", "type": "set", "name": "set default status value", "xml": "<set>\n<parameter name='response-code' value='200' />\n<parameter name='response-message' value='Get A1 Policy executed successfully' />", "comments": "", - "x": 732.0000610351562, - "y": 132, - "z": "e064bcd1.68ce88", + "x": 739.0000610351562, + "y": 259, + "z": "7304d8ed.dab258", "wires": [] }, { - "id": "50c242ff.949c04", + "id": "18c8dded.66a2f2", "type": "execute", "name": "execute Properties", "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.prop.PropertiesNode' method='readProperties' >\n <parameter name='fileName' value='/opt/onap/ccsdk/data/properties/a1-adapter-api-dg.properties' />\n <parameter name='contextPrefix' value='prop' />\n", "comments": "", "outputs": 1, - "x": 731, - "y": 185, - "z": "e064bcd1.68ce88", + "x": 738, + "y": 312, + "z": "7304d8ed.dab258", "wires": [ [] ] }, { - "id": "63a848d9.da34b", + "id": "bfb54edb.3da1b", "type": "block", "name": "A1 Mediator RestAPI Invocation", "xml": "<block atomic='true'>", "atomic": "true", "comments": "", "outputs": 1, - "x": 761.0001220703125, - "y": 269, - "z": "e064bcd1.68ce88", + "x": 768.0001220703125, + "y": 396, + "z": "7304d8ed.dab258", "wires": [ [ - "291f2c44.cafa94", - "91d29dbf.a6a538", - "81af0899.ed949" + "a8547794.9858e8", + "ddc15ef5.9b7b4", + "8a8335fe.a1c9b8", + "2e1a3941.d3ca26" ] ] }, { - "id": "91d29dbf.a6a538", + "id": "ddc15ef5.9b7b4", "type": "set", "name": "set tmp variables for A1 Mediator REST API call", "xml": "<set>\n<parameter name=\"tmp.near-rt-ric-url\" value=\"`$get-a1-policy-input.near-rt-ric-url`\"/>", "comments": "", - "x": 1123.00146484375, - "y": 161.88912963867188, - "z": "e064bcd1.68ce88", + "x": 1139.00146484375, + "y": 190.88912963867188, + "z": "7304d8ed.dab258", "wires": [] }, { - "id": "291f2c44.cafa94", + "id": "a8547794.9858e8", "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/A1-Adapter.log\" />\n<parameter name=\"level\" value=\"info\" />\n<parameter name=\"field1\" value=\"Setting variables for A1 Adapter Get Policy Instance.\"/>\n<parameter name=\"field2\" value=\"`$tmp.near-rt-ric-url`\"/>", "comments": "", "outputs": 1, - "x": 1011.0001220703125, - "y": 251, - "z": "e064bcd1.68ce88", + "x": 1024.0001220703125, + "y": 395, + "z": "7304d8ed.dab258", "wires": [ [] ] }, { - "id": "81af0899.ed949", + "id": "8a8335fe.a1c9b8", "type": "execute", "name": "Get Policy Instance", "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"restapiUrl\" value=\"`$tmp.near-rt-ric-url`\"/>\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"GET\"/>\n<parameter name=\"responsePrefix\" value=\"a1MediatorRsp\"/>\n<parameter name='contentType' value='application/json' />\n<parameter name='accept' value='application/json' />\n<parameter name=\"convertResponse\" value=\"false\"/>", "comments": "", "outputs": 1, - "x": 1056.0006103515625, - "y": 333.0104064941406, - "z": "e064bcd1.68ce88", + "x": 1057.0006103515625, + "y": 543.0104064941406, + "z": "7304d8ed.dab258", "wires": [ [ - "13d8386c.8ddea8", - "af0b89cf.ac16e8" + "e4a64d8c.fd97", + "5a45e869.670878" ] ] }, { - "id": "13d8386c.8ddea8", + "id": "e4a64d8c.fd97", "type": "failure", "name": "failure", "xml": "<outcome value='failure'>\n", "comments": "", "outputs": 1, - "x": 1283, - "y": 402.0001220703125, - "z": "e064bcd1.68ce88", + "x": 1267, + "y": 641.0001220703125, + "z": "7304d8ed.dab258", "wires": [ [ - "bf13d67e.e0cbb" + "13b0f676.750d9a" ] ] }, { - "id": "af0b89cf.ac16e8", + "id": "5a45e869.670878", "type": "success", "name": "success", "xml": "<outcome value='success'>\n", "comments": "", "outputs": 1, "x": 1274.000244140625, - "y": 246.00003051757812, - "z": "e064bcd1.68ce88", + "y": 542.0000305175781, + "z": "7304d8ed.dab258", "wires": [ [ - "98798a19.a969a" + "2c53bf53.3bc33" ] ] }, { - "id": "508b9b05.e13d4c", + "id": "df221ec3.a4a66", "type": "returnFailure", "name": "return failure", "xml": "<return status='failure'>\n<parameter name='ack-final' value='Y'/>\n<parameter name=\"response-code\" value=\"500\" />\n<parameter name=\"response-message\" value=\"Error in Getting A1 Policy Instance. Aborting\" />", "comments": "", - "x": 1606.0006103515625, - "y": 456.00006103515625, - "z": "e064bcd1.68ce88", + "x": 1591.0006103515625, + "y": 751.0000610351562, + "z": "7304d8ed.dab258", "wires": [] }, { - "id": "98798a19.a969a", + "id": "2c53bf53.3bc33", "type": "block", "name": "block", "xml": "<block>\n", "atomic": "false", "comments": "", "outputs": 1, - "x": 1446.9998779296875, - "y": 247.00006103515625, - "z": "e064bcd1.68ce88", + "x": 1430.9998779296875, + "y": 541.0000610351562, + "z": "7304d8ed.dab258", "wires": [ [ - "c4d70fbd.f8a89", - "efe59c04.f94ff", - "7d3fa61b.39674" + "cbc08871.96e018", + "98154503.e4bc58", + "168fc93b.3defa7" ] ] }, { - "id": "c4d70fbd.f8a89", + "id": "cbc08871.96e018", "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/A1-Adapter.log\" />\n<parameter name=\"level\" value=\"info\" />\n<parameter name=\"field1\" value=\"A1 Get Policy Information \"/>\n<parameter name=\"field2\" value=\"`$tmp.a1-mediator-restapi.httpResponse`\"/>", "comments": "", "outputs": 1, - "x": 1615, - "y": 219, - "z": "e064bcd1.68ce88", + "x": 1582, + "y": 539, + "z": "7304d8ed.dab258", "wires": [ [] ] }, { - "id": "3864588e.e52d2", + "id": "9092f8ee.72e568", "type": "set", "name": "set", "xml": "<set>\n<parameter name='response-code' value='500'/>\n<parameter name='response-message' value='Seems A1 Mediator Not Healthy'/>\n", "comments": "", - "x": 1579.75390625, - "y": 349.00390625, - "z": "e064bcd1.68ce88", + "x": 1581.75390625, + "y": 667.00390625, + "z": "7304d8ed.dab258", "wires": [] }, { - "id": "91f0150f.12ce4", + "id": "236f6af1.570056", "type": "block", "name": "block", "xml": "<block>\n", "atomic": "false", "comments": "", "outputs": 1, - "x": 694.75390625, - "y": 441.00390625, - "z": "e064bcd1.68ce88", + "x": 701.75390625, + "y": 568.00390625, + "z": "7304d8ed.dab258", "wires": [ [ - "a170f7d2.fa1e18" + "a1bd774.c21d588" ] ] }, { - "id": "a170f7d2.fa1e18", + "id": "a1bd774.c21d588", "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<parameter name='response-code' value='200' />\n<parameter name='response-message' value='Get PolicyInstance executed successfully'/>\n<parameter name='ack-final' value='Y'/>\n", "comments": "", - "x": 855.7539672851562, - "y": 441.00396728515625, - "z": "e064bcd1.68ce88", + "x": 862.7539672851562, + "y": 568.0039672851562, + "z": "7304d8ed.dab258", "wires": [] }, { - "id": "bf13d67e.e0cbb", + "id": "13b0f676.750d9a", "type": "block", "name": "block", "xml": "<block>\n", "atomic": "false", "comments": "", "outputs": 1, - "x": 1438.00390625, - "y": 401.0039367675781, - "z": "e064bcd1.68ce88", + "x": 1427.00390625, + "y": 705.00390625, + "z": "7304d8ed.dab258", "wires": [ [ - "3864588e.e52d2", - "508b9b05.e13d4c" + "9092f8ee.72e568", + "df221ec3.a4a66" ] ] }, { - "id": "efe59c04.f94ff", + "id": "98154503.e4bc58", "type": "execute", "name": "set", "xml": "<set>\n<parameter name='responseBody' value='`$tmp.a1-mediator-restapi.httpResponse`'/>", "comments": "", "outputs": 1, - "x": 1611, - "y": 297, - "z": "e064bcd1.68ce88", + "x": 1581, + "y": 584, + "z": "7304d8ed.dab258", "wires": [ [] ] }, { - "id": "7d3fa61b.39674", + "id": "168fc93b.3defa7", "type": "execute", "name": "execute", "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replaceAll' >\n <parameter name=\"source\" value=\"`$a1MediatorRsp.httpResponse`\"/>\n <parameter name=\"outputPath\" value=\"tmp.a1-mediator-restapi.httpResponse\"/>\n <parameter name=\"target\" value=\"\\n\"/>\n <parameter name=\"replacement\" value=\"\"/>", "comments": "", "outputs": 1, - "x": 1614, - "y": 152, - "z": "e064bcd1.68ce88", + "x": 1587, + "y": 490, + "z": "7304d8ed.dab258", + "wires": [ + [] + ] + }, + { + "id": "2e1a3941.d3ca26", + "type": "block", + "name": "block Substitute proxy address if available", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1144, + "y": 304, + "z": "7304d8ed.dab258", + "wires": [ + [ + "75b00f49.dcc31", + "c836a6e6.960ec8", + "e1b6f74c.e43ab8" + ] + ] + }, + { + "id": "75b00f49.dcc31", + "type": "set", + "name": "set tmp url variables with proxy information", + "xml": "<set>\n<parameter name=\"tmp.proxy-url\" value=\"`$prop.a1Mediator.proxy.url`\"/>", + "comments": "", + "x": 1546, + "y": 181, + "z": "7304d8ed.dab258", + "wires": [] + }, + { + "id": "c836a6e6.960ec8", + "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/A1-Adapter.log\" />\n<parameter name=\"level\" value=\"info\" />\n<parameter name=\"field1\" value=\"A1 Get Policy Information: Check for proxy url: \"/>\n<parameter name=\"field2\" value=\"`$tmp.proxy-url`\"/>\n\n", + "comments": "", + "outputs": 1, + "x": 1429, + "y": 256, + "z": "7304d8ed.dab258", + "wires": [ + [] + ] + }, + { + "id": "26ee6f37.aa426", + "type": "execute", + "name": "split near-rt-ric URL", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='split'>\n <parameter name=\"original_string\" value=\"`$tmp.near-rt-ric-url`\" />\n <parameter name=\"regex\" value=\"/\"/>\n <parameter name=\"ctx_memory_result_key\" value=\"tmp.near-rt-ric-url-splitList\"/>", + "comments": "", + "outputs": 1, + "x": 1978, + "y": 338, + "z": "7304d8ed.dab258", + "wires": [ + [] + ] + }, + { + "id": "2545ffb.f98f8", + "type": "for", + "name": "for", + "xml": "<for index='idx' start='3' end=\"`$tmp.near-rt-ric-url-splitList_length`\" >", + "comments": "", + "outputs": 1, + "x": 1944, + "y": 408, + "z": "7304d8ed.dab258", + "wires": [ + [ + "79fcf81b.cca0a8" + ] + ] + }, + { + "id": "79fcf81b.cca0a8", + "type": "execute", + "name": "set concat url", + "xml": "<set>\n<parameter name='tmp.proxy-url' value=\"`$tmp.proxy-url +'/' + $tmp.near-rt-ric-url-splitList[$idx] `\" />\n\n\n", + "comments": "", + "outputs": 1, + "x": 2122, + "y": 408, + "z": "7304d8ed.dab258", + "wires": [ + [] + ] + }, + { + "id": "4d7fe169.4b287", + "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/A1-Adapter.log\" />\n<parameter name=\"level\" value=\"info\" />\n<parameter name=\"field1\" value=\"A1 Get Policy Information: Url with proxy: \"/>\n<parameter name=\"field2\" value=\"`$tmp.proxy-url`\"/>\n\n", + "comments": "", + "outputs": 1, + "x": 1944, + "y": 471, + "z": "7304d8ed.dab258", "wires": [ [] ] + }, + { + "id": "e1b6f74c.e43ab8", + "type": "switchNode", + "name": "switch", + "xml": "<switch test='`$tmp.proxy-url`'>\n", + "comments": "", + "outputs": 1, + "x": 1428, + "y": 339, + "z": "7304d8ed.dab258", + "wires": [ + [ + "8d722c43.e9664", + "1b872074.8d5e4" + ] + ] + }, + { + "id": "8d722c43.e9664", + "type": "outcome", + "name": "No proxy URL", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 1607, + "y": 305, + "z": "7304d8ed.dab258", + "wires": [ + [ + "af216f88.1be42" + ] + ] + }, + { + "id": "af216f88.1be42", + "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/A1-Adapter.log\" />\n<parameter name=\"level\" value=\"info\" />\n<parameter name=\"field1\" value=\"A1 Get Policy Information: No proxy found on properties file \"/>\n", + "comments": "", + "outputs": 1, + "x": 1775, + "y": 305, + "z": "7304d8ed.dab258", + "wires": [ + [] + ] + }, + { + "id": "1b872074.8d5e4", + "type": "outcome", + "name": "Otherwise", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 1603, + "y": 373, + "z": "7304d8ed.dab258", + "wires": [ + [ + "6c54e9b2.79a338" + ] + ] + }, + { + "id": "6c54e9b2.79a338", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1767, + "y": 373, + "z": "7304d8ed.dab258", + "wires": [ + [ + "26ee6f37.aa426", + "2545ffb.f98f8", + "4d7fe169.4b287", + "b2366d8c.1909" + ] + ] + }, + { + "id": "b2366d8c.1909", + "type": "set", + "name": "set variables for A1 Mediator with proxy url", + "xml": "<set>\n<parameter name=\"tmp.near-rt-ric-url\" value=\"`$tmp.proxy-url`\"/>", + "comments": "", + "x": 2054, + "y": 532, + "z": "7304d8ed.dab258", + "wires": [] } ]
\ No newline at end of file diff --git a/platform-logic/a1Adapter-api/src/main/json/A1-ADAPTER-API_getA1PolicyStatus.json b/platform-logic/a1Adapter-api/src/main/json/A1-ADAPTER-API_getA1PolicyStatus.json index 14b08a80..85db3a55 100644 --- a/platform-logic/a1Adapter-api/src/main/json/A1-ADAPTER-API_getA1PolicyStatus.json +++ b/platform-logic/a1Adapter-api/src/main/json/A1-ADAPTER-API_getA1PolicyStatus.json @@ -1,6 +1,6 @@ [ { - "id": "792b8892.64457", + "id": "7547a4fa.c7bbcc", "type": "service-logic", "name": "A1-ADAPTER-API ${project.version}", "module": "A1-ADAPTER-API", @@ -8,325 +8,522 @@ "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='A1-ADAPTER-API' version='${project.version}'>", "outputs": 1, - "x": 167, - "y": 179, - "z": "6c2cfe41.61b868", + "x": 172, + "y": 213, + "z": "ba6f4cc8.60e08", "wires": [ [ - "11f7d7b8.1b7cb8" + "1108b3bd.2f6f4c" ] ] }, { - "id": "11f7d7b8.1b7cb8", + "id": "1108b3bd.2f6f4c", "type": "method", "name": "method getA1PolicyStatus", "xml": "<method rpc='getA1PolicyStatus' mode='sync'>\n", "comments": "", "outputs": 1, - "x": 226, - "y": 300, - "z": "6c2cfe41.61b868", + "x": 231, + "y": 334, + "z": "ba6f4cc8.60e08", "wires": [ [ - "ea8cdc1c.7ad76" + "423ee9ab.f84d58" ] ] }, { - "id": "606404ab.821cbc", + "id": "86ab57c6.4239e8", "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/A1-Adapter.log\" />\n<parameter name=\"level\" value=\"info\" />\n<parameter name=\"field1\" value=\"Get A1 Policy Status:\"/>\n<parameter name=\"field2\" value=\"`$get-a1-policy-status-input.near-rt-ric-url`\"/>", "comments": "", "outputs": 1, - "x": 690, - "y": 114, - "z": "6c2cfe41.61b868", + "x": 695, + "y": 148, + "z": "ba6f4cc8.60e08", "wires": [ [] ] }, { - "id": "ea8cdc1c.7ad76", + "id": "423ee9ab.f84d58", "type": "block", "name": "block : atomic", "xml": "<block atomic='true'>", "atomic": "true", "comments": "", "outputs": 1, - "x": 431, - "y": 254, - "z": "6c2cfe41.61b868", + "x": 436, + "y": 288, + "z": "ba6f4cc8.60e08", "wires": [ [ - "606404ab.821cbc", - "722eabeb.6d1a7c", - "1786ef85.c617a8", - "9795ae5f.c333", - "1c69a7a7.5059e" + "86ab57c6.4239e8", + "377e4bc4.cf6254", + "d0dee2e1.f5a44", + "2064dc6c.f4a0b4", + "7b79073a.3842e8" ] ] }, { - "id": "90a09247.4437", + "id": "9743b8a8.158568", "type": "dgstart", "name": "DGSTART", "outputs": 1, - "x": 98, - "y": 116, - "z": "6c2cfe41.61b868", + "x": 103, + "y": 150, + "z": "ba6f4cc8.60e08", "wires": [ [ - "792b8892.64457" + "7547a4fa.c7bbcc" ] ] }, { - "id": "722eabeb.6d1a7c", + "id": "377e4bc4.cf6254", "type": "set", "name": "set default status value", "xml": "<set>\n<parameter name='response-code' value='200' />\n<parameter name='response-message' value='Get A1 Policy executed successfully' />", "comments": "", - "x": 731.0000610351562, - "y": 169, - "z": "6c2cfe41.61b868", + "x": 736.0000610351562, + "y": 203, + "z": "ba6f4cc8.60e08", "wires": [] }, { - "id": "1786ef85.c617a8", + "id": "d0dee2e1.f5a44", "type": "execute", "name": "execute Properties", "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.prop.PropertiesNode' method='readProperties' >\n <parameter name='fileName' value='/opt/onap/ccsdk/data/properties/a1-adapter-api-dg.properties' />\n <parameter name='contextPrefix' value='prop' />\n", "comments": "", "outputs": 1, - "x": 730, - "y": 222, - "z": "6c2cfe41.61b868", + "x": 735, + "y": 256, + "z": "ba6f4cc8.60e08", "wires": [ [] ] }, { - "id": "1c69a7a7.5059e", + "id": "7b79073a.3842e8", "type": "block", "name": "A1 Mediator RestAPI Invocation", "xml": "<block atomic='true'>", "atomic": "true", "comments": "", "outputs": 1, - "x": 760.0001220703125, - "y": 306, - "z": "6c2cfe41.61b868", + "x": 765.0001220703125, + "y": 340, + "z": "ba6f4cc8.60e08", "wires": [ [ - "350bef62.ead7a", - "42b67c54.7a5fc4", - "3c854250.ea03ce" + "f6e87f8b.c8e97", + "484e89c8.8a2518", + "106aff5e.8841f1", + "7df3b9b5.9298c8" ] ] }, { - "id": "42b67c54.7a5fc4", + "id": "484e89c8.8a2518", "type": "set", "name": "set tmp variables for A1 Mediator REST API call", "xml": "<set>\n<parameter name=\"tmp.near-rt-ric-url\" value=\"`$get-a1-policy-status-input.near-rt-ric-url`\"/>", "comments": "", - "x": 1122.00146484375, - "y": 198.88912963867188, - "z": "6c2cfe41.61b868", + "x": 1138.00146484375, + "y": 237.88912963867188, + "z": "ba6f4cc8.60e08", "wires": [] }, { - "id": "350bef62.ead7a", + "id": "f6e87f8b.c8e97", "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/A1-Adapter.log\" />\n<parameter name=\"level\" value=\"info\" />\n<parameter name=\"field1\" value=\"Setting variables for A1 Adapter Get Policy Status.\"/>\n<parameter name=\"field2\" value=\"`$tmp.near-rt-ric-url`\"/>", "comments": "", "outputs": 1, - "x": 1009.0001220703125, - "y": 289, - "z": "6c2cfe41.61b868", + "x": 1015.0001220703125, + "y": 416, + "z": "ba6f4cc8.60e08", "wires": [ [] ] }, { - "id": "3c854250.ea03ce", + "id": "106aff5e.8841f1", "type": "execute", "name": "Get Policy Instance Status", "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"restapiUrl\" value=\"`$tmp.near-rt-ric-url`\"/>\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"GET\"/>\n<parameter name=\"responsePrefix\" value=\"a1MediatorRsp\"/>\n<parameter name='contentType' value='application/json' />\n<parameter name='accept' value='application/json' />\n<parameter name=\"convertResponse\" value=\"true\"/>", "comments": "", "outputs": 1, - "x": 1055.0006103515625, - "y": 370.0104064941406, - "z": "6c2cfe41.61b868", + "x": 1079.0006103515625, + "y": 544.0103759765625, + "z": "ba6f4cc8.60e08", "wires": [ [ - "db967cfd.662b5", - "f7373336.a9f2d8" + "f3f6f62a.f41478", + "969a94ea.773e38" ] ] }, { - "id": "db967cfd.662b5", + "id": "f3f6f62a.f41478", "type": "failure", "name": "failure", "xml": "<outcome value='failure'>\n", "comments": "", "outputs": 1, - "x": 1282, - "y": 439.0001220703125, - "z": "6c2cfe41.61b868", + "x": 1303, + "y": 624.0001220703125, + "z": "ba6f4cc8.60e08", "wires": [ [ - "e83b2b7e.0baf9" + "6fa34f65.cd31e" ] ] }, { - "id": "f7373336.a9f2d8", + "id": "969a94ea.773e38", "type": "success", "name": "success", "xml": "<outcome value='success'>\n", "comments": "", "outputs": 1, - "x": 1273.000244140625, - "y": 283.0000305175781, - "z": "6c2cfe41.61b868", + "x": 1307.000244140625, + "y": 470.0000305175781, + "z": "ba6f4cc8.60e08", "wires": [ [ - "ff2d7ebe.e41298" + "bb9a433.67534c" ] ] }, { - "id": "9eba774e.8b338", + "id": "841abfc3.69c46", "type": "returnFailure", "name": "return failure", "xml": "<return status='failure'>\n<parameter name='ack-final' value='Y'/>\n<parameter name=\"response-code\" value=\"404\" />\n<parameter name=\"response-message\" value=\"Error in Getting A1 Policy Status. Aborting\" />", "comments": "", - "x": 1605.0006103515625, - "y": 493.00006103515625, - "z": "6c2cfe41.61b868", + "x": 1610.0006103515625, + "y": 679.0000610351562, + "z": "ba6f4cc8.60e08", "wires": [] }, { - "id": "ff2d7ebe.e41298", + "id": "bb9a433.67534c", "type": "block", "name": "block", "xml": "<block>\n", "atomic": "false", "comments": "", "outputs": 1, - "x": 1445.9998779296875, - "y": 284.00006103515625, - "z": "6c2cfe41.61b868", + "x": 1450.9998779296875, + "y": 470.00006103515625, + "z": "ba6f4cc8.60e08", "wires": [ [ - "a55d0be.aa42678", - "73d80df5.3d29b4", - "49aaac04.dffde4" + "53bf49b8.e46be8", + "23da3b63.1d7a64", + "e316d95e.fbfff8" ] ] }, { - "id": "a55d0be.aa42678", + "id": "53bf49b8.e46be8", "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/A1-Adapter.log\" />\n<parameter name=\"level\" value=\"info\" />\n<parameter name=\"field1\" value=\"A1 Get Policy Status \"/>\n<parameter name=\"field2\" value=\"`$tmp.a1-mediator-restapi.httpResponse`\"/>", "comments": "", "outputs": 1, - "x": 1604, - "y": 230, - "z": "6c2cfe41.61b868", + "x": 1612, + "y": 469, + "z": "ba6f4cc8.60e08", "wires": [ [] ] }, { - "id": "1979a6a.06a3759", + "id": "45d11c3c.69ea24", "type": "set", "name": "set", "xml": "<set>\n<parameter name='response-code' value='500'/>\n<parameter name='response-message' value='Seems A1 Mediator Not Healthy'/>\n", "comments": "", - "x": 1578.75390625, - "y": 386.00390625, - "z": "6c2cfe41.61b868", + "x": 1583.75390625, + "y": 572.00390625, + "z": "ba6f4cc8.60e08", "wires": [] }, { - "id": "9795ae5f.c333", + "id": "2064dc6c.f4a0b4", "type": "block", "name": "block", "xml": "<block>\n", "atomic": "false", "comments": "", "outputs": 1, - "x": 693.75390625, - "y": 478.00390625, - "z": "6c2cfe41.61b868", + "x": 698.75390625, + "y": 560.00390625, + "z": "ba6f4cc8.60e08", "wires": [ [ - "d253316a.832ce" + "fd599731.db71c8" ] ] }, { - "id": "d253316a.832ce", + "id": "fd599731.db71c8", "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<parameter name='response-code' value='200' />\n<parameter name='response-message' value='Get Policy Status executed successfully'/>\n<parameter name='ack-final' value='Y'/>\n", "comments": "", - "x": 854.7539672851562, - "y": 478.00396728515625, - "z": "6c2cfe41.61b868", + "x": 859.7539672851562, + "y": 560.0039672851562, + "z": "ba6f4cc8.60e08", "wires": [] }, { - "id": "e83b2b7e.0baf9", + "id": "6fa34f65.cd31e", "type": "block", "name": "block", "xml": "<block>\n", "atomic": "false", "comments": "", "outputs": 1, - "x": 1437.00390625, - "y": 438.0039367675781, - "z": "6c2cfe41.61b868", + "x": 1442.00390625, + "y": 624.0039367675781, + "z": "ba6f4cc8.60e08", "wires": [ [ - "1979a6a.06a3759", - "9eba774e.8b338" + "45d11c3c.69ea24", + "841abfc3.69c46" ] ] }, { - "id": "73d80df5.3d29b4", + "id": "23da3b63.1d7a64", "type": "execute", "name": "set", "xml": "<set>\n<parameter name='responseBody' value='`$tmp.a1-mediator-restapi.httpResponse`'/>", "comments": "", "outputs": 1, - "x": 1609, - "y": 334, - "z": "6c2cfe41.61b868", + "x": 1614, + "y": 520, + "z": "ba6f4cc8.60e08", "wires": [ [] ] }, { - "id": "49aaac04.dffde4", + "id": "e316d95e.fbfff8", "type": "execute", "name": "execute", "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replaceAll' >\n <parameter name=\"source\" value=\"`$a1MediatorRsp.httpResponse`\"/>\n <parameter name=\"outputPath\" value=\"tmp.a1-mediator-restapi.httpResponse\"/>\n <parameter name=\"target\" value=\"\\n\"/>\n <parameter name=\"replacement\" value=\"\"/>", "comments": "", "outputs": 1, - "x": 1602, - "y": 155, - "z": "6c2cfe41.61b868", + "x": 1616, + "y": 426, + "z": "ba6f4cc8.60e08", + "wires": [ + [] + ] + }, + { + "id": "b988a0f2.cebc8", + "type": "execute", + "name": "split near-rt-ric URL", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='split'>\n <parameter name=\"original_string\" value=\"`$tmp.near-rt-ric-url`\" />\n <parameter name=\"regex\" value=\"/\"/>\n <parameter name=\"ctx_memory_result_key\" value=\"tmp.near-rt-ric-url-splitList\"/>", + "comments": "", + "outputs": 1, + "x": 1994, + "y": 318, + "z": "ba6f4cc8.60e08", + "wires": [ + [] + ] + }, + { + "id": "6e6d1a6a.783024", + "type": "for", + "name": "for", + "xml": "<for index='idx' start='3' end=\"`$tmp.near-rt-ric-url-splitList_length`\" >", + "comments": "", + "outputs": 1, + "x": 1960, + "y": 388, + "z": "ba6f4cc8.60e08", + "wires": [ + [ + "91e4428c.7143b" + ] + ] + }, + { + "id": "91e4428c.7143b", + "type": "execute", + "name": "set concat url", + "xml": "<set>\n<parameter name='tmp.proxy-url' value=\"`$tmp.proxy-url +'/' + $tmp.near-rt-ric-url-splitList[$idx] `\" />\n\n\n", + "comments": "", + "outputs": 1, + "x": 2138, + "y": 388, + "z": "ba6f4cc8.60e08", + "wires": [ + [] + ] + }, + { + "id": "5958734e.49501c", + "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/A1-Adapter.log\" />\n<parameter name=\"level\" value=\"info\" />\n<parameter name=\"field1\" value=\"Get A1 Policy Status: Url with proxy: \"/>\n<parameter name=\"field2\" value=\"`$tmp.proxy-url`\"/>\n\n", + "comments": "", + "outputs": 1, + "x": 1960, + "y": 451, + "z": "ba6f4cc8.60e08", + "wires": [ + [] + ] + }, + { + "id": "d87bfe21.b6db5", + "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/A1-Adapter.log\" />\n<parameter name=\"level\" value=\"info\" />\n<parameter name=\"field1\" value=\"Get A1 Policy Status: No proxy found on properties file \"/>\n", + "comments": "", + "outputs": 1, + "x": 1791, + "y": 285, + "z": "ba6f4cc8.60e08", + "wires": [ + [] + ] + }, + { + "id": "c12bf1b.56d2e1", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1783, + "y": 353, + "z": "ba6f4cc8.60e08", + "wires": [ + [ + "b988a0f2.cebc8", + "6e6d1a6a.783024", + "5958734e.49501c", + "9090a68a.628a58" + ] + ] + }, + { + "id": "9090a68a.628a58", + "type": "set", + "name": "set variables for A1 Mediator with proxy url", + "xml": "<set>\n<parameter name=\"tmp.near-rt-ric-url\" value=\"`$tmp.proxy-url`\"/>", + "comments": "", + "x": 2070, + "y": 512, + "z": "ba6f4cc8.60e08", + "wires": [] + }, + { + "id": "768b81d4.9d20c", + "type": "outcome", + "name": "Otherwise", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 1619, + "y": 353, + "z": "ba6f4cc8.60e08", + "wires": [ + [ + "c12bf1b.56d2e1" + ] + ] + }, + { + "id": "b3216caa.c1505", + "type": "outcome", + "name": "No proxy URL", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 1623, + "y": 285, + "z": "ba6f4cc8.60e08", + "wires": [ + [ + "d87bfe21.b6db5" + ] + ] + }, + { + "id": "5379ad2e.52cba4", + "type": "switchNode", + "name": "switch", + "xml": "<switch test='`$tmp.proxy-url`'>\n", + "comments": "", + "outputs": 1, + "x": 1444, + "y": 319, + "z": "ba6f4cc8.60e08", + "wires": [ + [ + "b3216caa.c1505", + "768b81d4.9d20c" + ] + ] + }, + { + "id": "2151b182.f0aebe", + "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/A1-Adapter.log\" />\n<parameter name=\"level\" value=\"info\" />\n<parameter name=\"field1\" value=\"Get A1 Policy Status: Check for proxy url: \"/>\n<parameter name=\"field2\" value=\"`$tmp.proxy-url`\"/>\n\n", + "comments": "", + "outputs": 1, + "x": 1445, + "y": 236, + "z": "ba6f4cc8.60e08", "wires": [ [] ] + }, + { + "id": "862a1de8.7e469", + "type": "set", + "name": "set tmp url variables with proxy information", + "xml": "<set>\n<parameter name=\"tmp.proxy-url\" value=\"`$prop.a1Mediator.proxy.url`\"/>", + "comments": "", + "x": 1562, + "y": 161, + "z": "ba6f4cc8.60e08", + "wires": [] + }, + { + "id": "7df3b9b5.9298c8", + "type": "block", + "name": "block Substitute proxy address if available", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1117, + "y": 326, + "z": "ba6f4cc8.60e08", + "wires": [ + [ + "862a1de8.7e469", + "2151b182.f0aebe", + "5379ad2e.52cba4" + ] + ] } ]
\ No newline at end of file diff --git a/platform-logic/a1Adapter-api/src/main/json/A1-ADAPTER-API_getA1PolicyType.json b/platform-logic/a1Adapter-api/src/main/json/A1-ADAPTER-API_getA1PolicyType.json index c797668a..e29dc2ad 100644 --- a/platform-logic/a1Adapter-api/src/main/json/A1-ADAPTER-API_getA1PolicyType.json +++ b/platform-logic/a1Adapter-api/src/main/json/A1-ADAPTER-API_getA1PolicyType.json @@ -1,6 +1,6 @@ [ { - "id": "5a3c07ae.e366b8", + "id": "c57a85a7.6d9e28", "type": "service-logic", "name": "A1-ADAPTER-API ${project.version}", "module": "A1-ADAPTER-API", @@ -8,325 +8,522 @@ "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='A1-ADAPTER-API' version='${project.version}'>", "outputs": 1, - "x": 175, - "y": 157.00000095367432, - "z": "4a015e5c.e4da6", + "x": 184, + "y": 217, + "z": "6b10bb22.27b454", "wires": [ [ - "b7bd1ba7.d04778" + "7f8f754.1d44a8c" ] ] }, { - "id": "b7bd1ba7.d04778", + "id": "7f8f754.1d44a8c", "type": "method", "name": "method getA1PolicyType", "xml": "<method rpc='getA1PolicyType' mode='sync'>\n", "comments": "", "outputs": 1, - "x": 238.00000762939453, - "y": 280.0000104904175, - "z": "4a015e5c.e4da6", + "x": 247.00000762939453, + "y": 340.00000953674316, + "z": "6b10bb22.27b454", "wires": [ [ - "3f32665d.c1c8ba" + "84af22f.906a3e" ] ] }, { - "id": "f83e0069.d60a28", + "id": "ed70783e.27b828", "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/A1-Adapter.log\" />\n<parameter name=\"level\" value=\"info\" />\n<parameter name=\"field1\" value=\"Get Policy Type:\"/>\n<parameter name=\"field2\" value=\"`$get-a1-policy-type-input.near-rt-ric-url`\"/>", "comments": "", "outputs": 1, - "x": 703.0000267028809, - "y": 93, - "z": "4a015e5c.e4da6", + "x": 712.0000267028809, + "y": 152.99999904632568, + "z": "6b10bb22.27b454", "wires": [ [] ] }, { - "id": "3f32665d.c1c8ba", + "id": "84af22f.906a3e", "type": "block", "name": "block : atomic", "xml": "<block atomic='true'>", "atomic": "true", "comments": "", "outputs": 1, - "x": 441, - "y": 231.00000095367432, - "z": "4a015e5c.e4da6", + "x": 450, + "y": 291, + "z": "6b10bb22.27b454", "wires": [ [ - "f83e0069.d60a28", - "ece1263.0cc9bd8", - "c4f19376.cb13b", - "644e8ac.a2fb1f4", - "479ab38c.15d78c" + "ed70783e.27b828", + "28381478.4110ac", + "37a94c09.766b94", + "87dae598.c09b78", + "5b5bbe8a.3a76a" ] ] }, { - "id": "e311365b.05491", + "id": "1bc64bfe.dda094", "type": "dgstart", "name": "DGSTART", "outputs": 1, - "x": 108, - "y": 93.00000095367432, - "z": "4a015e5c.e4da6", + "x": 117, + "y": 153, + "z": "6b10bb22.27b454", "wires": [ [ - "5a3c07ae.e366b8" + "c57a85a7.6d9e28" ] ] }, { - "id": "ece1263.0cc9bd8", + "id": "28381478.4110ac", "type": "set", "name": "set default status value", "xml": "<set>\n<parameter name='response-code' value='200' />\n<parameter name='response-message' value='getA1PolicyType executed successfully' />", "comments": "", - "x": 740.0001068115234, - "y": 145.99999904632568, - "z": "4a015e5c.e4da6", + "x": 749.0001068115234, + "y": 205.99999809265137, + "z": "6b10bb22.27b454", "wires": [] }, { - "id": "c4f19376.cb13b", + "id": "37a94c09.766b94", "type": "execute", "name": "execute Properties", "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.prop.PropertiesNode' method='readProperties' >\n <parameter name='fileName' value='/opt/onap/ccsdk/data/properties/a1-adapter-api-dg.properties' />\n <parameter name='contextPrefix' value='prop' />\n", "comments": "", "outputs": 1, - "x": 740, - "y": 199.00000095367432, - "z": "4a015e5c.e4da6", + "x": 749, + "y": 259, + "z": "6b10bb22.27b454", "wires": [ [] ] }, { - "id": "479ab38c.15d78c", + "id": "5b5bbe8a.3a76a", "type": "block", "name": "A1 Mediator RestAPI Invocation", "xml": "<block atomic='true'>", "atomic": "true", "comments": "", "outputs": 1, - "x": 764.0001525878906, - "y": 284.99999475479126, - "z": "4a015e5c.e4da6", + "x": 773.0001525878906, + "y": 344.99999380111694, + "z": "6b10bb22.27b454", "wires": [ [ - "72ae0a37.799b94", - "56399f4b.cae578", - "40012c04.89442c" + "80c7ebd8.e99678", + "c14dac35.e1db6", + "410d2f2e.d71a4", + "d12e5095.54989" ] ] }, { - "id": "72ae0a37.799b94", + "id": "80c7ebd8.e99678", "type": "set", "name": "set tmp variables for A1 Mediator REST API call", "xml": "<set>\n<parameter name=\"tmp.near-rt-ric-url\" value=\"`$get-a1-policy-type-input.near-rt-ric-url`\"/>", "comments": "", - "x": 1214.00146484375, - "y": 217.88914251327515, - "z": "4a015e5c.e4da6", + "x": 1163.00146484375, + "y": 147.88912963867188, + "z": "6b10bb22.27b454", "wires": [] }, { - "id": "56399f4b.cae578", + "id": "c14dac35.e1db6", "type": "execute", "name": "Get Policy Types", "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"restapiUrl\" value=\"`$tmp.near-rt-ric-url`\"/>\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"GET\"/>\n<parameter name=\"responsePrefix\" value=\"a1MediatorRsp\"/>\n<parameter name='contentType' value='application/json' />\n<parameter name='accept' value='application/json' />\n<parameter name=\"convertResponse\" value=\"true\"/>", "comments": "", "outputs": 1, - "x": 1021.000602722168, - "y": 346.010377407074, - "z": "4a015e5c.e4da6", + "x": 1059.0006103515625, + "y": 519.0103759765625, + "z": "6b10bb22.27b454", "wires": [ [ - "90458ba.4afa9f8", - "901d354.b45acc8" + "c5fcaf09.27937", + "855add04.525dc" ] ] }, { - "id": "90458ba.4afa9f8", + "id": "c5fcaf09.27937", "type": "failure", "name": "failure", "xml": "<outcome value='failure'>\n", "comments": "", "outputs": 1, - "x": 1125.0000610351562, - "y": 431.0001196861267, - "z": "4a015e5c.e4da6", + "x": 1240.0000610351562, + "y": 577.0001187324524, + "z": "6b10bb22.27b454", "wires": [ [ - "774aa433.0336b4" + "ddd5d6a3.da1298" ] ] }, { - "id": "901d354.b45acc8", + "id": "855add04.525dc", "type": "success", "name": "success", "xml": "<outcome value='success'>\n", "comments": "", "outputs": 1, - "x": 1257.000244140625, - "y": 330.0000305175781, - "z": "4a015e5c.e4da6", + "x": 1241.0002136230469, + "y": 473.000018119812, + "z": "6b10bb22.27b454", "wires": [ [ - "45b9b49f.441fbc" + "c1626bc6.876598" ] ] }, { - "id": "69c58cb1.928354", + "id": "a71cc3cf.ce06a", "type": "returnFailure", "name": "return failure", "xml": "<return status='failure'>\n<parameter name='ack-final' value='Y'/>\n<parameter name=\"response-code\" value=\"404\" />\n<parameter name=\"response-message\" value=\"Error in Getting A1 Policy Type. Aborting\" />", "comments": "", - "x": 1397.0006103515625, - "y": 484.0001196861267, - "z": "4a015e5c.e4da6", + "x": 1529.0006103515625, + "y": 611.0001220703125, + "z": "6b10bb22.27b454", "wires": [] }, { - "id": "45b9b49f.441fbc", + "id": "c1626bc6.876598", "type": "block", "name": "block", "xml": "<block>\n", "atomic": "false", "comments": "", "outputs": 1, - "x": 1420.9999084472656, - "y": 304.00007343292236, - "z": "4a015e5c.e4da6", + "x": 1404.9998779296875, + "y": 447.00006103515625, + "z": "6b10bb22.27b454", "wires": [ [ - "3592b1c6.fc7b6e", - "6af8fc5a.b2bd5c", - "2c18e75d.32018" + "471d2243.80555c", + "622289fe.925988", + "5eab9cfb.a9aba4" ] ] }, { - "id": "3592b1c6.fc7b6e", + "id": "471d2243.80555c", "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/A1-Adapter.log\" />\n<parameter name=\"level\" value=\"info\" />\n<parameter name=\"field1\" value=\"A1 Policy Type Information \"/>\n<parameter name=\"field2\" value=\"`$tmp.a1-mediator-restapi.httpResponse`\"/>", "comments": "", "outputs": 1, - "x": 1660, - "y": 212, - "z": "4a015e5c.e4da6", + "x": 1576.9999694824219, + "y": 450.9999780654907, + "z": "6b10bb22.27b454", "wires": [ [] ] }, { - "id": "a14ef7ef.d0bba8", + "id": "ce3d916.2cc397", "type": "set", "name": "set", "xml": "<set>\n<parameter name='response-code' value='500'/>\n<parameter name='response-message' value='Seems A1 Mediator Not Healthy'/>\n", "comments": "", - "x": 1378.75390625, - "y": 382.0039367675781, - "z": "4a015e5c.e4da6", + "x": 1511.75390625, + "y": 551.0039367675781, + "z": "6b10bb22.27b454", "wires": [] }, { - "id": "644e8ac.a2fb1f4", + "id": "87dae598.c09b78", "type": "block", "name": "block", "xml": "<block>\n", "atomic": "false", "comments": "", "outputs": 1, - "x": 701.7539405822754, - "y": 407.0039954185486, - "z": "4a015e5c.e4da6", + "x": 696.7539367675781, + "y": 612.0039978027344, + "z": "6b10bb22.27b454", "wires": [ [ - "17123f41.a49541" + "bd48102.d01bdf" ] ] }, { - "id": "17123f41.a49541", + "id": "bd48102.d01bdf", "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<parameter name='response-code' value='200' />\n<parameter name='response-message' value='A1 Adapter is healthy'/>\n<parameter name='health-status' value='200'/>\n<parameter name='ack-final' value='Y'/>\n", "comments": "", - "x": 916.7540321350098, - "y": 407.00393438339233, - "z": "4a015e5c.e4da6", + "x": 911.7540283203125, + "y": 612.0039367675781, + "z": "6b10bb22.27b454", "wires": [] }, { - "id": "774aa433.0336b4", + "id": "ddd5d6a3.da1298", "type": "block", "name": "block", "xml": "<block>\n", "atomic": "false", "comments": "", "outputs": 1, - "x": 1253.0039367675781, - "y": 433.00391912460327, - "z": "4a015e5c.e4da6", + "x": 1368.0039367675781, + "y": 579.003918170929, + "z": "6b10bb22.27b454", "wires": [ [ - "69c58cb1.928354", - "a14ef7ef.d0bba8" + "a71cc3cf.ce06a", + "ce3d916.2cc397" ] ] }, { - "id": "40012c04.89442c", + "id": "410d2f2e.d71a4", "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/A1-Adapter.log\" />\n<parameter name=\"level\" value=\"info\" />\n<parameter name=\"field1\" value=\"Setting variables for A1 Adapter Get Policy Type.\"/>\n<parameter name=\"field2\" value=\"`$tmp.near-rt-ric-url`\"/>", "comments": "", "outputs": 1, - "x": 1144.9999351501465, - "y": 268.00001335144043, - "z": "4a015e5c.e4da6", + "x": 1034.9998779296875, + "y": 455, + "z": "6b10bb22.27b454", "wires": [ [] ] }, { - "id": "6af8fc5a.b2bd5c", + "id": "622289fe.925988", "type": "execute", "name": "set", "xml": "<set>\n<parameter name='responseBody' value=\"`$tmp.a1-mediator-restapi.httpResponse`\"/>", "comments": "", "outputs": 1, - "x": 1709.0001220703125, - "y": 282.0000104904175, - "z": "4a015e5c.e4da6", + "x": 1578.0000915527344, + "y": 505.9999885559082, + "z": "6b10bb22.27b454", "wires": [ [] ] }, { - "id": "2c18e75d.32018", + "id": "5eab9cfb.a9aba4", "type": "execute", "name": "execute", "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='replaceAll' >\n <parameter name=\"source\" value=\"`$a1MediatorRsp.httpResponse`\"/>\n <parameter name=\"outputPath\" value=\"tmp.a1-mediator-restapi.httpResponse\"/>\n <parameter name=\"target\" value=\"\\n\"/>\n <parameter name=\"replacement\" value=\"\"/>", "comments": "", "outputs": 1, - "x": 1663, - "y": 163, - "z": "4a015e5c.e4da6", + "x": 1579.9999694824219, + "y": 401.9999780654907, + "z": "6b10bb22.27b454", "wires": [ [] ] + }, + { + "id": "3646f816.699f88", + "type": "execute", + "name": "split near-rt-ric URL", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='split'>\n <parameter name=\"original_string\" value=\"`$tmp.near-rt-ric-url`\" />\n <parameter name=\"regex\" value=\"/\"/>\n <parameter name=\"ctx_memory_result_key\" value=\"tmp.near-rt-ric-url-splitList\"/>", + "comments": "", + "outputs": 1, + "x": 2114, + "y": 245, + "z": "6b10bb22.27b454", + "wires": [ + [] + ] + }, + { + "id": "6556f21c.11ee1c", + "type": "for", + "name": "for", + "xml": "<for index='idx' start='3' end=\"`$tmp.near-rt-ric-url-splitList_length`\" >", + "comments": "", + "outputs": 1, + "x": 2080, + "y": 315, + "z": "6b10bb22.27b454", + "wires": [ + [ + "afa1cbf9.b42ef8" + ] + ] + }, + { + "id": "afa1cbf9.b42ef8", + "type": "execute", + "name": "set concat url", + "xml": "<set>\n<parameter name='tmp.proxy-url' value=\"`$tmp.proxy-url +'/' + $tmp.near-rt-ric-url-splitList[$idx] `\" />\n\n\n", + "comments": "", + "outputs": 1, + "x": 2258, + "y": 315, + "z": "6b10bb22.27b454", + "wires": [ + [] + ] + }, + { + "id": "1214c3b2.b5293c", + "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/A1-Adapter.log\" />\n<parameter name=\"level\" value=\"info\" />\n<parameter name=\"field1\" value=\"Get Policy Type: Url with proxy: \"/>\n<parameter name=\"field2\" value=\"`$tmp.proxy-url`\"/>\n\n", + "comments": "", + "outputs": 1, + "x": 2080, + "y": 372, + "z": "6b10bb22.27b454", + "wires": [ + [] + ] + }, + { + "id": "ae139c27.9f81c", + "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/A1-Adapter.log\" />\n<parameter name=\"level\" value=\"info\" />\n<parameter name=\"field1\" value=\"Get Policy Type: No proxy found on properties file \"/>\n", + "comments": "", + "outputs": 1, + "x": 1884, + "y": 281, + "z": "6b10bb22.27b454", + "wires": [ + [] + ] + }, + { + "id": "a9cf882b.e74398", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1876, + "y": 349, + "z": "6b10bb22.27b454", + "wires": [ + [ + "3646f816.699f88", + "6556f21c.11ee1c", + "1214c3b2.b5293c", + "e7cb17c0.4634f8" + ] + ] + }, + { + "id": "e7cb17c0.4634f8", + "type": "set", + "name": "set variables for A1 Mediator with proxy url", + "xml": "<set>\n<parameter name=\"tmp.near-rt-ric-url\" value=\"`$tmp.proxy-url`\"/>", + "comments": "", + "x": 2190, + "y": 428, + "z": "6b10bb22.27b454", + "wires": [] + }, + { + "id": "96f3e7b2.57cad8", + "type": "outcome", + "name": "No proxy URL", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 1716, + "y": 281, + "z": "6b10bb22.27b454", + "wires": [ + [ + "ae139c27.9f81c" + ] + ] + }, + { + "id": "d9949951.7f0e98", + "type": "outcome", + "name": "Otherwise", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 1712, + "y": 349, + "z": "6b10bb22.27b454", + "wires": [ + [ + "a9cf882b.e74398" + ] + ] + }, + { + "id": "bb63dde8.4da53", + "type": "switchNode", + "name": "switch", + "xml": "<switch test='`$tmp.proxy-url`'>\n", + "comments": "", + "outputs": 1, + "x": 1537, + "y": 315, + "z": "6b10bb22.27b454", + "wires": [ + [ + "96f3e7b2.57cad8", + "d9949951.7f0e98" + ] + ] + }, + { + "id": "4600604a.a82ae", + "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/A1-Adapter.log\" />\n<parameter name=\"level\" value=\"info\" />\n<parameter name=\"field1\" value=\"Get Policy Type: Check for proxy url: \"/>\n<parameter name=\"field2\" value=\"`$tmp.proxy-url`\"/>\n\n", + "comments": "", + "outputs": 1, + "x": 1538, + "y": 232, + "z": "6b10bb22.27b454", + "wires": [ + [] + ] + }, + { + "id": "ddbc9e41.e0fde", + "type": "set", + "name": "set tmp url variables with proxy information", + "xml": "<set>\n<parameter name=\"tmp.proxy-url\" value=\"`$prop.a1Mediator.proxy.url`\"/>", + "comments": "", + "x": 1655, + "y": 157, + "z": "6b10bb22.27b454", + "wires": [] + }, + { + "id": "d12e5095.54989", + "type": "block", + "name": "block Substitute proxy address if available", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1142, + "y": 307, + "z": "6b10bb22.27b454", + "wires": [ + [ + "ddbc9e41.e0fde", + "4600604a.a82ae", + "bb63dde8.4da53" + ] + ] } ]
\ No newline at end of file diff --git a/platform-logic/a1Adapter-api/src/main/json/A1-ADAPTER-API_putA1Policy.json b/platform-logic/a1Adapter-api/src/main/json/A1-ADAPTER-API_putA1Policy.json index 419d5b71..e7cdfdab 100644 --- a/platform-logic/a1Adapter-api/src/main/json/A1-ADAPTER-API_putA1Policy.json +++ b/platform-logic/a1Adapter-api/src/main/json/A1-ADAPTER-API_putA1Policy.json @@ -1,6 +1,6 @@ [ { - "id": "270a5aa5.bc52d6", + "id": "a6683616.46e428", "type": "service-logic", "name": "A1-ADAPTER-API ${project.version}", "module": "A1-ADAPTER-API", @@ -8,266 +8,463 @@ "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='A1-ADAPTER-API' version='${project.version}'>", "outputs": 1, - "x": 171, - "y": 150, - "z": "33919dc9.0e17ba", + "x": 209, + "y": 202, + "z": "7db096e2.c70bf8", "wires": [ [ - "187cb7f8.135d08" + "55ac3f1d.94381" ] ] }, { - "id": "187cb7f8.135d08", + "id": "55ac3f1d.94381", "type": "method", "name": "method putA1Policy", "xml": "<method rpc='putA1Policy' mode='sync'>\n", "comments": "", "outputs": 1, - "x": 158, - "y": 219, - "z": "33919dc9.0e17ba", + "x": 196, + "y": 271, + "z": "7db096e2.c70bf8", "wires": [ [ - "60165fbc.5b22d8" + "dcec6661.43fb88" ] ] }, { - "id": "ca1b73bb.bd73a", + "id": "b9d05c94.6e887", "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/A1-Adapter.log\" />\n<parameter name=\"level\" value=\"info\" />\n<parameter name=\"field1\" value=\"Put A1 Policy :\"/>\n<parameter name=\"field2\" value=\"`$put-a1-policy-input.near-rt-ric-url`\"/>\n<parameter name=\"field3\" value=\"`$put-a1-policy-input.body`\"/>\n", "comments": "", "outputs": 1, - "x": 472, - "y": 187, - "z": "33919dc9.0e17ba", + "x": 510, + "y": 239, + "z": "7db096e2.c70bf8", "wires": [ [] ] }, { - "id": "60165fbc.5b22d8", + "id": "dcec6661.43fb88", "type": "block", "name": "block : atomic", "xml": "<block atomic='true'>", "atomic": "true", "comments": "", "outputs": 1, - "x": 222, - "y": 286, - "z": "33919dc9.0e17ba", + "x": 260, + "y": 338, + "z": "7db096e2.c70bf8", "wires": [ [ - "ca1b73bb.bd73a", - "3bda5968.b55f7e", - "a7fa8c3e.f91198", - "d671108f.2dd19" + "b9d05c94.6e887", + "5edc5dc0.aa7554", + "de4ae81.e69d418", + "c913644.23cbe98" ] ] }, { - "id": "86499c8c.9221c", + "id": "6234cc0e.af53d4", "type": "dgstart", "name": "DGSTART", "outputs": 1, - "x": 99, - "y": 88, - "z": "33919dc9.0e17ba", + "x": 137, + "y": 140, + "z": "7db096e2.c70bf8", "wires": [ [ - "270a5aa5.bc52d6" + "a6683616.46e428" ] ] }, { - "id": "3bda5968.b55f7e", + "id": "5edc5dc0.aa7554", "type": "execute", "name": "execute Properties", "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.prop.PropertiesNode' method='readProperties' >\n <parameter name='fileName' value='/opt/onap/ccsdk/data/properties/a1-adapter-api-dg.properties' />\n <parameter name='contextPrefix' value='prop' />\n", "comments": "", "outputs": 1, - "x": 506, - "y": 285, - "z": "33919dc9.0e17ba", + "x": 544, + "y": 337, + "z": "7db096e2.c70bf8", "wires": [ [] ] }, { - "id": "f71250c1.d2e79", + "id": "cfebc3e6.36acd", "type": "failure", "name": "failure", "xml": "<outcome value='failure'>\n", "comments": "", "outputs": 1, - "x": 988.0001220703125, - "y": 363.00006103515625, - "z": "33919dc9.0e17ba", + "x": 1026.0001220703125, + "y": 415.00006103515625, + "z": "7db096e2.c70bf8", "wires": [ [ - "424bcc5a.68059c" + "42f98b0.e003174" ] ] }, { - "id": "678803c.a1c0efc", + "id": "6387e9e5.fcf6e8", "type": "success", "name": "success", "xml": "<outcome value='success'>\n", "comments": "", "outputs": 1, - "x": 995.0003051757812, - "y": 453.0000457763672, - "z": "33919dc9.0e17ba", + "x": 1033.0003051757812, + "y": 505.0000457763672, + "z": "7db096e2.c70bf8", "wires": [ [ - "d61f47fe.10e5e8" + "38ff960.c37ae6a" ] ] }, { - "id": "d61f47fe.10e5e8", + "id": "38ff960.c37ae6a", "type": "block", "name": "block", "xml": "<block>\n", "atomic": "false", "comments": "", "outputs": 1, - "x": 1136.9999389648438, - "y": 449.00006103515625, - "z": "33919dc9.0e17ba", + "x": 1174.9999389648438, + "y": 501.00006103515625, + "z": "7db096e2.c70bf8", "wires": [ [ - "44bf0d67.60023c" + "13a7ce3e.7474d2" ] ] }, { - "id": "b1b2cbaf.574838", + "id": "6cc48a1a.2c90b4", "type": "set", "name": "set tmp variables for input RPC parms", "xml": "<set>\n<parameter name=\"tmp.near-rt-ric-url\" value=\"`$put-a1-policy-input.near-rt-ric-url`\"/>\n<parameter name=\"tmp.body\" value=\"`$put-a1-policy-input.body`\"/>", "comments": "", - "x": 884.0010375976562, - "y": 239.88909912109375, - "z": "33919dc9.0e17ba", + "x": 928.0010375976562, + "y": 63.88909912109375, + "z": "7db096e2.c70bf8", "wires": [] }, { - "id": "1fe61572.90f523", + "id": "41cd845d.cbb3bc", "type": "execute", "name": "Put A1 Policy", "xml": "<execute plugin='org.onap.ccsdk.sli.plugins.restapicall.RestapiCallNode' method='sendRequest' >\n<parameter name=\"restapiUrl\" value=\"`$tmp.near-rt-ric-url`\"/>\n<parameter name=\"format\" value=\"json\"/>\n<parameter name=\"httpMethod\" value=\"PUT\"/>\n<parameter name=\"responsePrefix\" value=\"a1MediatorRsp\"/>\n<parameter name='contentType' value='application/json' />\n<parameter name='accept' value='application/json' />\n<parameter name=\"requestBody\" value=\"`$tmp.body`\"/>\n<parameter name=\"convertResponse\" value=\"false\"/>\n", "comments": "", "outputs": 1, - "x": 811.00048828125, - "y": 411.0103759765625, - "z": "33919dc9.0e17ba", + "x": 849.00048828125, + "y": 463.0103759765625, + "z": "7db096e2.c70bf8", "wires": [ [ - "f71250c1.d2e79", - "678803c.a1c0efc" + "cfebc3e6.36acd", + "6387e9e5.fcf6e8" ] ] }, { - "id": "d671108f.2dd19", + "id": "c913644.23cbe98", "type": "block", "name": "A1 Mediator RestAPI Invocation", "xml": "<block atomic='true'>", "atomic": "true", "comments": "", "outputs": 1, - "x": 542.0000305175781, - "y": 350.00006103515625, - "z": "33919dc9.0e17ba", + "x": 580.0000305175781, + "y": 402.00006103515625, + "z": "7db096e2.c70bf8", "wires": [ [ - "8d62fd00.aa56e", - "b1b2cbaf.574838", - "1fe61572.90f523" + "1f2f09a.5ad55f6", + "6cc48a1a.2c90b4", + "41cd845d.cbb3bc", + "378c77.9a4d338a" ] ] }, { - "id": "8d62fd00.aa56e", + "id": "1f2f09a.5ad55f6", "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/A1-Adapter.log\" />\n<parameter name=\"level\" value=\"info\" />\n<parameter name=\"field1\" value=\"Setting variables for Put A1 Policy.\"/>\n<parameter name=\"field2\" value=\"`$tmp.near-rt-ric-url`\"/>\n<parameter name=\"field3\" value=\"`$tmp.body`\"/>", "comments": "", "outputs": 1, - "x": 807.0000610351562, - "y": 335, - "z": "33919dc9.0e17ba", + "x": 830.0000610351562, + "y": 417, + "z": "7db096e2.c70bf8", "wires": [ [] ] }, { - "id": "44bf0d67.60023c", + "id": "13a7ce3e.7474d2", "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/A1-Adapter.log\" />\n<parameter name=\"level\" value=\"info\" />\n<parameter name=\"field1\" value=\"A1 Policy Instance Created.\"/>", "comments": "", "outputs": 1, - "x": 1293, - "y": 448.00006103515625, - "z": "33919dc9.0e17ba", + "x": 1331, + "y": 500.00006103515625, + "z": "7db096e2.c70bf8", "wires": [ [] ] }, { - "id": "a0360147.468f3", + "id": "5e390699.7a2918", "type": "returnFailure", "name": "return failure", "xml": "<return status='failure'>\n<parameter name='ack-final' value='Y'/>\n<parameter name=\"response-code\" value=\"404\" />\n<parameter name=\"response-message\" value=\"Error creating A1 Policy. Aborting A1 Policy creation\" />", "comments": "", - "x": 1286, - "y": 401, - "z": "33919dc9.0e17ba", + "x": 1324, + "y": 453, + "z": "7db096e2.c70bf8", "wires": [] }, { - "id": "a7fa8c3e.f91198", + "id": "de4ae81.e69d418", "type": "set", "name": "set default status value", "xml": "<set>\n<parameter name='response-code' value='200' />\n<parameter name='response-message' value='Put A1 Policy executed successfully' />", "comments": "", - "x": 517, - "y": 240, - "z": "33919dc9.0e17ba", + "x": 555, + "y": 292, + "z": "7db096e2.c70bf8", "wires": [] }, { - "id": "424bcc5a.68059c", + "id": "42f98b0.e003174", "type": "block", "name": "block", "xml": "<block>\n", "atomic": "false", "comments": "", "outputs": 1, - "x": 1124, - "y": 361, - "z": "33919dc9.0e17ba", + "x": 1162, + "y": 413, + "z": "7db096e2.c70bf8", "wires": [ [ - "b8ca1bb9.7870e", - "a0360147.468f3" + "45242a9a.990c74", + "5e390699.7a2918" ] ] }, { - "id": "b8ca1bb9.7870e", + "id": "45242a9a.990c74", "type": "set", "name": "set", "xml": "<set>\n<parameter name='response-code' value='500'/>\n<parameter name='response-message' value='Seems A1 Mediator Not Healthy'/>\n", "comments": "", - "x": 1268, + "x": 1306, + "y": 359, + "z": "7db096e2.c70bf8", + "wires": [] + }, + { + "id": "6a96fe57.d042e", + "type": "execute", + "name": "split near-rt-ric URL", + "xml": "<execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='split'>\n <parameter name=\"original_string\" value=\"`$tmp.near-rt-ric-url`\" />\n <parameter name=\"regex\" value=\"/\"/>\n <parameter name=\"ctx_memory_result_key\" value=\"tmp.near-rt-ric-url-splitList\"/>", + "comments": "", + "outputs": 1, + "x": 1878, + "y": 180, + "z": "7db096e2.c70bf8", + "wires": [ + [] + ] + }, + { + "id": "bba56b28.73aad8", + "type": "for", + "name": "for", + "xml": "<for index='idx' start='3' end=\"`$tmp.near-rt-ric-url-splitList_length`\" >", + "comments": "", + "outputs": 1, + "x": 1844, + "y": 250, + "z": "7db096e2.c70bf8", + "wires": [ + [ + "efb1667d.1585f8" + ] + ] + }, + { + "id": "efb1667d.1585f8", + "type": "execute", + "name": "set concat url", + "xml": "<set>\n<parameter name='tmp.proxy-url' value=\"`$tmp.proxy-url +'/' + $tmp.near-rt-ric-url-splitList[$idx] `\" />\n\n\n", + "comments": "", + "outputs": 1, + "x": 2022, + "y": 250, + "z": "7db096e2.c70bf8", + "wires": [ + [] + ] + }, + { + "id": "d31b610e.4b717", + "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/A1-Adapter.log\" />\n<parameter name=\"level\" value=\"info\" />\n<parameter name=\"field1\" value=\"Put A1 Policy: Url with proxy: \"/>\n<parameter name=\"field2\" value=\"`$tmp.proxy-url`\"/>\n\n", + "comments": "", + "outputs": 1, + "x": 1844, "y": 307, - "z": "33919dc9.0e17ba", + "z": "7db096e2.c70bf8", + "wires": [ + [] + ] + }, + { + "id": "10f86c59.93f224", + "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/A1-Adapter.log\" />\n<parameter name=\"level\" value=\"info\" />\n<parameter name=\"field1\" value=\"Put A1 Policy: No proxy found on properties file \"/>\n", + "comments": "", + "outputs": 1, + "x": 1648, + "y": 216, + "z": "7db096e2.c70bf8", + "wires": [ + [] + ] + }, + { + "id": "a1eabac4.71c208", + "type": "block", + "name": "block", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 1640, + "y": 284, + "z": "7db096e2.c70bf8", + "wires": [ + [ + "6a96fe57.d042e", + "bba56b28.73aad8", + "d31b610e.4b717", + "2462752b.bd93aa" + ] + ] + }, + { + "id": "2462752b.bd93aa", + "type": "set", + "name": "set variables for A1 Mediator with proxy url", + "xml": "<set>\n<parameter name=\"tmp.near-rt-ric-url\" value=\"`$tmp.proxy-url`\"/>", + "comments": "", + "x": 1954, + "y": 363, + "z": "7db096e2.c70bf8", "wires": [] + }, + { + "id": "8b5f261e.23f748", + "type": "outcome", + "name": "No proxy URL", + "xml": "<outcome value=''>\n", + "comments": "", + "outputs": 1, + "x": 1480, + "y": 216, + "z": "7db096e2.c70bf8", + "wires": [ + [ + "10f86c59.93f224" + ] + ] + }, + { + "id": "fcbbd2a7.10f08", + "type": "outcome", + "name": "Otherwise", + "xml": "<outcome value='Other'>\n", + "comments": "", + "outputs": 1, + "x": 1476, + "y": 284, + "z": "7db096e2.c70bf8", + "wires": [ + [ + "a1eabac4.71c208" + ] + ] + }, + { + "id": "921d95cc.6097d8", + "type": "set", + "name": "set tmp url variables with proxy information", + "xml": "<set>\n<parameter name=\"tmp.proxy-url\" value=\"`$prop.a1Mediator.proxy.url`\"/>", + "comments": "", + "x": 1419, + "y": 92, + "z": "7db096e2.c70bf8", + "wires": [] + }, + { + "id": "1fb088e3.0e4167", + "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/A1-Adapter.log\" />\n<parameter name=\"level\" value=\"info\" />\n<parameter name=\"field1\" value=\"Put A1 Policy: Check for proxy url: \"/>\n<parameter name=\"field2\" value=\"`$tmp.proxy-url`\"/>\n\n", + "comments": "", + "outputs": 1, + "x": 1302, + "y": 167, + "z": "7db096e2.c70bf8", + "wires": [ + [] + ] + }, + { + "id": "cea9d686.3a7118", + "type": "switchNode", + "name": "switch", + "xml": "<switch test='`$tmp.proxy-url`'>\n", + "comments": "", + "outputs": 1, + "x": 1301, + "y": 250, + "z": "7db096e2.c70bf8", + "wires": [ + [ + "8b5f261e.23f748", + "fcbbd2a7.10f08" + ] + ] + }, + { + "id": "378c77.9a4d338a", + "type": "block", + "name": "block Substitute proxy address if available", + "xml": "<block>\n", + "atomic": "false", + "comments": "", + "outputs": 1, + "x": 964, + "y": 249, + "z": "7db096e2.c70bf8", + "wires": [ + [ + "921d95cc.6097d8", + "1fb088e3.0e4167", + "cea9d686.3a7118" + ] + ] } ]
\ No newline at end of file diff --git a/platform-logic/a1Adapter-api/src/main/xml/A1-ADAPTER-API_deleteA1Policy.xml b/platform-logic/a1Adapter-api/src/main/xml/A1-ADAPTER-API_deleteA1Policy.xml index a351cc5c..3f264e57 100644 --- a/platform-logic/a1Adapter-api/src/main/xml/A1-ADAPTER-API_deleteA1Policy.xml +++ b/platform-logic/a1Adapter-api/src/main/xml/A1-ADAPTER-API_deleteA1Policy.xml @@ -6,7 +6,7 @@ <record plugin="org.onap.ccsdk.sli.core.sli.recording.FileRecorder"> <parameter name="file" value="/opt/opendaylight/current/data/log/A1-Adapter.log" /> <parameter name="level" value="info" /> - <parameter name="field1" value="Delete Policy:"/> + <parameter name="field1" value="Delete A1 Policy:"/> <parameter name="field2" value="`$delete-a1-policy-input.near-rt-ric-url`"/> </record> <set> @@ -21,6 +21,49 @@ <set> <parameter name="tmp.near-rt-ric-url" value="`$delete-a1-policy-input.near-rt-ric-url`"/> </set> + <block> + <set> + <parameter name="tmp.proxy-url" value="`$prop.a1Mediator.proxy.url`"/> + </set> + <record plugin="org.onap.ccsdk.sli.core.sli.recording.FileRecorder"> + <parameter name="file" value="/opt/opendaylight/current/data/log/A1-Adapter.log" /> + <parameter name="level" value="info" /> + <parameter name="field1" value="Delete A1 Policy: Check for proxy url: "/> + <parameter name="field2" value="`$tmp.proxy-url`"/> + </record> + <switch test='`$tmp.proxy-url`'> + <outcome value=''> + <record plugin="org.onap.ccsdk.sli.core.sli.recording.FileRecorder"> + <parameter name="file" value="/opt/opendaylight/current/data/log/A1-Adapter.log" /> + <parameter name="level" value="info" /> + <parameter name="field1" value="Delete A1 Policy: No proxy found on properties file "/> + </record> + </outcome> + <outcome value='Other'> + <block> + <execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='split'> + <parameter name="original_string" value="`$tmp.near-rt-ric-url`" /> + <parameter name="regex" value="/"/> + <parameter name="ctx_memory_result_key" value="tmp.near-rt-ric-url-splitList"/> + </execute> + <for index='idx' start='3' end="`$tmp.near-rt-ric-url-splitList_length`" > + <set> + <parameter name='tmp.proxy-url' value="`$tmp.proxy-url +'/' + $tmp.near-rt-ric-url-splitList[$idx] `" /> + </set> + </for> + <record plugin="org.onap.ccsdk.sli.core.sli.recording.FileRecorder"> + <parameter name="file" value="/opt/opendaylight/current/data/log/A1-Adapter.log" /> + <parameter name="level" value="info" /> + <parameter name="field1" value="Delete A1 Policy: Url with proxy: "/> + <parameter name="field2" value="`$tmp.proxy-url`"/> + </record> + <set> + <parameter name="tmp.near-rt-ric-url" value="`$tmp.proxy-url`"/> + </set> + </block> + </outcome> + </switch> + </block> <record plugin="org.onap.ccsdk.sli.core.sli.recording.FileRecorder"> <parameter name="file" value="/opt/opendaylight/current/data/log/A1-Adapter.log" /> <parameter name="level" value="info" /> diff --git a/platform-logic/a1Adapter-api/src/main/xml/A1-ADAPTER-API_getA1Policy.xml b/platform-logic/a1Adapter-api/src/main/xml/A1-ADAPTER-API_getA1Policy.xml index 79b4a9c7..2cedc9ca 100644 --- a/platform-logic/a1Adapter-api/src/main/xml/A1-ADAPTER-API_getA1Policy.xml +++ b/platform-logic/a1Adapter-api/src/main/xml/A1-ADAPTER-API_getA1Policy.xml @@ -21,6 +21,49 @@ <set> <parameter name="tmp.near-rt-ric-url" value="`$get-a1-policy-input.near-rt-ric-url`"/> </set> + <block> + <set> + <parameter name="tmp.proxy-url" value="`$prop.a1Mediator.proxy.url`"/> + </set> + <record plugin="org.onap.ccsdk.sli.core.sli.recording.FileRecorder"> + <parameter name="file" value="/opt/opendaylight/current/data/log/A1-Adapter.log" /> + <parameter name="level" value="info" /> + <parameter name="field1" value="A1 Get Policy Information: Check for proxy url: "/> + <parameter name="field2" value="`$tmp.proxy-url`"/> + </record> + <switch test='`$tmp.proxy-url`'> + <outcome value=''> + <record plugin="org.onap.ccsdk.sli.core.sli.recording.FileRecorder"> + <parameter name="file" value="/opt/opendaylight/current/data/log/A1-Adapter.log" /> + <parameter name="level" value="info" /> + <parameter name="field1" value="A1 Get Policy Information: No proxy found on properties file "/> + </record> + </outcome> + <outcome value='Other'> + <block> + <execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='split'> + <parameter name="original_string" value="`$tmp.near-rt-ric-url`" /> + <parameter name="regex" value="/"/> + <parameter name="ctx_memory_result_key" value="tmp.near-rt-ric-url-splitList"/> + </execute> + <for index='idx' start='3' end="`$tmp.near-rt-ric-url-splitList_length`" > + <set> + <parameter name='tmp.proxy-url' value="`$tmp.proxy-url +'/' + $tmp.near-rt-ric-url-splitList[$idx] `" /> + </set> + </for> + <record plugin="org.onap.ccsdk.sli.core.sli.recording.FileRecorder"> + <parameter name="file" value="/opt/opendaylight/current/data/log/A1-Adapter.log" /> + <parameter name="level" value="info" /> + <parameter name="field1" value="A1 Get Policy Information: Url with proxy: "/> + <parameter name="field2" value="`$tmp.proxy-url`"/> + </record> + <set> + <parameter name="tmp.near-rt-ric-url" value="`$tmp.proxy-url`"/> + </set> + </block> + </outcome> + </switch> + </block> <record plugin="org.onap.ccsdk.sli.core.sli.recording.FileRecorder"> <parameter name="file" value="/opt/opendaylight/current/data/log/A1-Adapter.log" /> <parameter name="level" value="info" /> diff --git a/platform-logic/a1Adapter-api/src/main/xml/A1-ADAPTER-API_getA1PolicyStatus.xml b/platform-logic/a1Adapter-api/src/main/xml/A1-ADAPTER-API_getA1PolicyStatus.xml index 703c7dfe..5750c528 100644 --- a/platform-logic/a1Adapter-api/src/main/xml/A1-ADAPTER-API_getA1PolicyStatus.xml +++ b/platform-logic/a1Adapter-api/src/main/xml/A1-ADAPTER-API_getA1PolicyStatus.xml @@ -21,6 +21,49 @@ <set> <parameter name="tmp.near-rt-ric-url" value="`$get-a1-policy-status-input.near-rt-ric-url`"/> </set> + <block> + <set> + <parameter name="tmp.proxy-url" value="`$prop.a1Mediator.proxy.url`"/> + </set> + <record plugin="org.onap.ccsdk.sli.core.sli.recording.FileRecorder"> + <parameter name="file" value="/opt/opendaylight/current/data/log/A1-Adapter.log" /> + <parameter name="level" value="info" /> + <parameter name="field1" value="Get A1 Policy Status: Check for proxy url: "/> + <parameter name="field2" value="`$tmp.proxy-url`"/> + </record> + <switch test='`$tmp.proxy-url`'> + <outcome value=''> + <record plugin="org.onap.ccsdk.sli.core.sli.recording.FileRecorder"> + <parameter name="file" value="/opt/opendaylight/current/data/log/A1-Adapter.log" /> + <parameter name="level" value="info" /> + <parameter name="field1" value="Get A1 Policy Status: No proxy found on properties file "/> + </record> + </outcome> + <outcome value='Other'> + <block> + <execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='split'> + <parameter name="original_string" value="`$tmp.near-rt-ric-url`" /> + <parameter name="regex" value="/"/> + <parameter name="ctx_memory_result_key" value="tmp.near-rt-ric-url-splitList"/> + </execute> + <for index='idx' start='3' end="`$tmp.near-rt-ric-url-splitList_length`" > + <set> + <parameter name='tmp.proxy-url' value="`$tmp.proxy-url +'/' + $tmp.near-rt-ric-url-splitList[$idx] `" /> + </set> + </for> + <record plugin="org.onap.ccsdk.sli.core.sli.recording.FileRecorder"> + <parameter name="file" value="/opt/opendaylight/current/data/log/A1-Adapter.log" /> + <parameter name="level" value="info" /> + <parameter name="field1" value="Get A1 Policy Status: Url with proxy: "/> + <parameter name="field2" value="`$tmp.proxy-url`"/> + </record> + <set> + <parameter name="tmp.near-rt-ric-url" value="`$tmp.proxy-url`"/> + </set> + </block> + </outcome> + </switch> + </block> <record plugin="org.onap.ccsdk.sli.core.sli.recording.FileRecorder"> <parameter name="file" value="/opt/opendaylight/current/data/log/A1-Adapter.log" /> <parameter name="level" value="info" /> diff --git a/platform-logic/a1Adapter-api/src/main/xml/A1-ADAPTER-API_getA1PolicyType.xml b/platform-logic/a1Adapter-api/src/main/xml/A1-ADAPTER-API_getA1PolicyType.xml index cea0bc5f..41091e0a 100644 --- a/platform-logic/a1Adapter-api/src/main/xml/A1-ADAPTER-API_getA1PolicyType.xml +++ b/platform-logic/a1Adapter-api/src/main/xml/A1-ADAPTER-API_getA1PolicyType.xml @@ -21,6 +21,49 @@ <set> <parameter name="tmp.near-rt-ric-url" value="`$get-a1-policy-type-input.near-rt-ric-url`"/> </set> + <block> + <set> + <parameter name="tmp.proxy-url" value="`$prop.a1Mediator.proxy.url`"/> + </set> + <record plugin="org.onap.ccsdk.sli.core.sli.recording.FileRecorder"> + <parameter name="file" value="/opt/opendaylight/current/data/log/A1-Adapter.log" /> + <parameter name="level" value="info" /> + <parameter name="field1" value="Get Policy Type: Check for proxy url: "/> + <parameter name="field2" value="`$tmp.proxy-url`"/> + </record> + <switch test='`$tmp.proxy-url`'> + <outcome value=''> + <record plugin="org.onap.ccsdk.sli.core.sli.recording.FileRecorder"> + <parameter name="file" value="/opt/opendaylight/current/data/log/A1-Adapter.log" /> + <parameter name="level" value="info" /> + <parameter name="field1" value="Get Policy Type: No proxy found on properties file "/> + </record> + </outcome> + <outcome value='Other'> + <block> + <execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='split'> + <parameter name="original_string" value="`$tmp.near-rt-ric-url`" /> + <parameter name="regex" value="/"/> + <parameter name="ctx_memory_result_key" value="tmp.near-rt-ric-url-splitList"/> + </execute> + <for index='idx' start='3' end="`$tmp.near-rt-ric-url-splitList_length`" > + <set> + <parameter name='tmp.proxy-url' value="`$tmp.proxy-url +'/' + $tmp.near-rt-ric-url-splitList[$idx] `" /> + </set> + </for> + <record plugin="org.onap.ccsdk.sli.core.sli.recording.FileRecorder"> + <parameter name="file" value="/opt/opendaylight/current/data/log/A1-Adapter.log" /> + <parameter name="level" value="info" /> + <parameter name="field1" value="Get Policy Type: Url with proxy: "/> + <parameter name="field2" value="`$tmp.proxy-url`"/> + </record> + <set> + <parameter name="tmp.near-rt-ric-url" value="`$tmp.proxy-url`"/> + </set> + </block> + </outcome> + </switch> + </block> <record plugin="org.onap.ccsdk.sli.core.sli.recording.FileRecorder"> <parameter name="file" value="/opt/opendaylight/current/data/log/A1-Adapter.log" /> <parameter name="level" value="info" /> diff --git a/platform-logic/a1Adapter-api/src/main/xml/A1-ADAPTER-API_putA1Policy.xml b/platform-logic/a1Adapter-api/src/main/xml/A1-ADAPTER-API_putA1Policy.xml index d674abfd..2f6abb89 100644 --- a/platform-logic/a1Adapter-api/src/main/xml/A1-ADAPTER-API_putA1Policy.xml +++ b/platform-logic/a1Adapter-api/src/main/xml/A1-ADAPTER-API_putA1Policy.xml @@ -23,6 +23,49 @@ <parameter name="tmp.near-rt-ric-url" value="`$put-a1-policy-input.near-rt-ric-url`"/> <parameter name="tmp.body" value="`$put-a1-policy-input.body`"/> </set> + <block> + <set> + <parameter name="tmp.proxy-url" value="`$prop.a1Mediator.proxy.url`"/> + </set> + <record plugin="org.onap.ccsdk.sli.core.sli.recording.FileRecorder"> + <parameter name="file" value="/opt/opendaylight/current/data/log/A1-Adapter.log" /> + <parameter name="level" value="info" /> + <parameter name="field1" value="Put A1 Policy: Check for proxy url: "/> + <parameter name="field2" value="`$tmp.proxy-url`"/> + </record> + <switch test='`$tmp.proxy-url`'> + <outcome value=''> + <record plugin="org.onap.ccsdk.sli.core.sli.recording.FileRecorder"> + <parameter name="file" value="/opt/opendaylight/current/data/log/A1-Adapter.log" /> + <parameter name="level" value="info" /> + <parameter name="field1" value="Put A1 Policy: No proxy found on properties file "/> + </record> + </outcome> + <outcome value='Other'> + <block> + <execute plugin='org.onap.ccsdk.sli.core.slipluginutils.SliStringUtils' method='split'> + <parameter name="original_string" value="`$tmp.near-rt-ric-url`" /> + <parameter name="regex" value="/"/> + <parameter name="ctx_memory_result_key" value="tmp.near-rt-ric-url-splitList"/> + </execute> + <for index='idx' start='3' end="`$tmp.near-rt-ric-url-splitList_length`" > + <set> + <parameter name='tmp.proxy-url' value="`$tmp.proxy-url +'/' + $tmp.near-rt-ric-url-splitList[$idx] `" /> + </set> + </for> + <record plugin="org.onap.ccsdk.sli.core.sli.recording.FileRecorder"> + <parameter name="file" value="/opt/opendaylight/current/data/log/A1-Adapter.log" /> + <parameter name="level" value="info" /> + <parameter name="field1" value="Put A1 Policy: Url with proxy: "/> + <parameter name="field2" value="`$tmp.proxy-url`"/> + </record> + <set> + <parameter name="tmp.near-rt-ric-url" value="`$tmp.proxy-url`"/> + </set> + </block> + </outcome> + </switch> + </block> <record plugin="org.onap.ccsdk.sli.core.sli.recording.FileRecorder"> <parameter name="file" value="/opt/opendaylight/current/data/log/A1-Adapter.log" /> <parameter name="level" value="info" /> |