summaryrefslogtreecommitdiffstats
path: root/bpmn/so-bpmn-infrastructure-common/src
diff options
context:
space:
mode:
authorr.bogacki <r.bogacki@samsung.com>2019-04-10 08:33:09 +0200
committerr.bogacki <r.bogacki@samsung.com>2019-04-10 16:18:57 +0200
commit565a0054e3b01ef4a730651b7b82102c021c0972 (patch)
treec936d7ba3d0b3d46b19b58a18eccf0186efeb9a0 /bpmn/so-bpmn-infrastructure-common/src
parented66a29ce8e0068740466e13fa6517791cce9aeb (diff)
Fixed latest Sonar blocker issues
Fixed blockers according to Sonar analysis. Change-Id: I2c2d053b66019b74ee20b0a56fb7b93bf931bb61 Issue-ID: SO-1734 Signed-off-by: Robert Bogacki <r.bogacki@samsung.com> Signed-off-by: Katsia Kazak <k.kazak@samsung.com>
Diffstat (limited to 'bpmn/so-bpmn-infrastructure-common/src')
-rw-r--r--bpmn/so-bpmn-infrastructure-common/src/main/java/org/onap/so/bpmn/infrastructure/workflow/service/ServicePluginFactory.java31
1 files changed, 16 insertions, 15 deletions
diff --git a/bpmn/so-bpmn-infrastructure-common/src/main/java/org/onap/so/bpmn/infrastructure/workflow/service/ServicePluginFactory.java b/bpmn/so-bpmn-infrastructure-common/src/main/java/org/onap/so/bpmn/infrastructure/workflow/service/ServicePluginFactory.java
index 896a8bd98c..22c4f95a6f 100644
--- a/bpmn/so-bpmn-infrastructure-common/src/main/java/org/onap/so/bpmn/infrastructure/workflow/service/ServicePluginFactory.java
+++ b/bpmn/so-bpmn-infrastructure-common/src/main/java/org/onap/so/bpmn/infrastructure/workflow/service/ServicePluginFactory.java
@@ -553,21 +553,22 @@ public class ServicePluginFactory {
// Now we need to query terminal points from SP resourcemgr system.
List<Object> locationTerminalPointList = queryTerminalPointsFromServiceProviderSystem(srcLocation, dstLocation);
- Map<String, Object> tpInfoMap = (Map<String, Object>) locationTerminalPointList.get(0);
-
- serviceRequestInputs.put("inner-src-access-provider-id", tpInfoMap.get("access-provider-id"));
- serviceRequestInputs.put("inner-src-access-client-id", tpInfoMap.get("access-client-id"));
- serviceRequestInputs.put("inner-src-access-topology-id", tpInfoMap.get("access-topology-id"));
- serviceRequestInputs.put("inner-src-access-node-id", tpInfoMap.get("access-node-id"));
- serviceRequestInputs.put("inner-src-access-ltp-id", tpInfoMap.get("access-ltp-id"));
- tpInfoMap = (Map<String, Object>) locationTerminalPointList.get(1);
-
- serviceRequestInputs.put("inner-dst-access-provider-id", tpInfoMap.get("access-provider-id"));
- serviceRequestInputs.put("inner-dst-access-client-id", tpInfoMap.get("access-client-id"));
- serviceRequestInputs.put("inner-dst-access-topology-id", tpInfoMap.get("access-topology-id"));
- serviceRequestInputs.put("inner-dst-access-node-id", tpInfoMap.get("access-node-id"));
- serviceRequestInputs.put("inner-dst-access-ltp-id", tpInfoMap.get("access-ltp-id"));
-
+ if (locationTerminalPointList != null) {
+ Map<String, Object> tpInfoMap = (Map<String, Object>) locationTerminalPointList.get(0);
+
+ serviceRequestInputs.put("inner-src-access-provider-id", tpInfoMap.get("access-provider-id"));
+ serviceRequestInputs.put("inner-src-access-client-id", tpInfoMap.get("access-client-id"));
+ serviceRequestInputs.put("inner-src-access-topology-id", tpInfoMap.get("access-topology-id"));
+ serviceRequestInputs.put("inner-src-access-node-id", tpInfoMap.get("access-node-id"));
+ serviceRequestInputs.put("inner-src-access-ltp-id", tpInfoMap.get("access-ltp-id"));
+ tpInfoMap = (Map<String, Object>) locationTerminalPointList.get(1);
+
+ serviceRequestInputs.put("inner-dst-access-provider-id", tpInfoMap.get("access-provider-id"));
+ serviceRequestInputs.put("inner-dst-access-client-id", tpInfoMap.get("access-client-id"));
+ serviceRequestInputs.put("inner-dst-access-topology-id", tpInfoMap.get("access-topology-id"));
+ serviceRequestInputs.put("inner-dst-access-node-id", tpInfoMap.get("access-node-id"));
+ serviceRequestInputs.put("inner-dst-access-ltp-id", tpInfoMap.get("access-ltp-id"));
+ }
String newRequest = getJsonString(uuiObject);
return newRequest;
}