summaryrefslogtreecommitdiffstats
path: root/examples/examples-onap-bbs/src/main/resources/logic/AAIServiceCreateTask.js
diff options
context:
space:
mode:
authors00370346 <swarup.nayak1@huawei.com>2019-06-11 18:02:57 +0530
committers00370346 <swarup.nayak1@huawei.com>2019-06-11 18:03:02 +0530
commit3f53167d98e00198c15c950d9b7ba4ea8b4a4c05 (patch)
treeed6563d56f7f6b2265eb460891313559ffd0d6ff /examples/examples-onap-bbs/src/main/resources/logic/AAIServiceCreateTask.js
parent46c6d88b3002afef0a05b10c73bceb0c6c9d0c51 (diff)
BBS APEX policy not updating PNF attachment point after relocation
Issue-ID: POLICY-1835 Signed-off-by: s00370346 <swarup.nayak1@huawei.com> Change-Id: I47473444b58fa3b064ba142ce13c5e3520adb8c7
Diffstat (limited to 'examples/examples-onap-bbs/src/main/resources/logic/AAIServiceCreateTask.js')
-rw-r--r--examples/examples-onap-bbs/src/main/resources/logic/AAIServiceCreateTask.js6
1 files changed, 5 insertions, 1 deletions
diff --git a/examples/examples-onap-bbs/src/main/resources/logic/AAIServiceCreateTask.js b/examples/examples-onap-bbs/src/main/resources/logic/AAIServiceCreateTask.js
index a1c11adae..5d18f23b0 100644
--- a/examples/examples-onap-bbs/src/main/resources/logic/AAIServiceCreateTask.js
+++ b/examples/examples-onap-bbs/src/main/resources/logic/AAIServiceCreateTask.js
@@ -41,6 +41,7 @@ var AAI_URL = "localhost:8080";
var CUSTOMER_ID = requestID;
var BBS_CFS_SERVICE_TYPE = "BBS-CFS-Access_Test";
var SERVICE_INSTANCE_ID = serviceInstanceId;
+var AAI_VERSION = "v14";
var HTTP_PROTOCOL = "https://";
var wbClient = Java.type("org.onap.policy.apex.examples.bbs.WebClient");
var client = new wbClient();
@@ -61,6 +62,9 @@ try {
} else if (line.startsWith("AAI_PASSWORD")) {
var str = line.split("=");
AAI_PASSWORD = str[str.length - 1];
+ } else if (line.startsWith("AAI_VERSION")) {
+ var str = line.split("=");
+ AAI_VERSION = str[str.length - 1];
}
}
} catch (err) {
@@ -71,7 +75,7 @@ var aaiUpdateResult = true;
/* Get service instance Id from AAI */
try {
var urlGet = HTTP_PROTOCOL + AAI_URL +
- "/aai/v14/nodes/service-instances/service-instance/" +
+ "/aai/" + AAI_VERSION + "/nodes/service-instances/service-instance/" +
SERVICE_INSTANCE_ID + "?format=resource_and_url";
executor.logger.info("Query url" + urlGet);