Added fix for potential nullpointerexception 81/65981/1
authorChandan Ghosh <cghosh12@in.ibm.com>
Wed, 12 Sep 2018 05:40:11 +0000 (11:10 +0530)
committerChandan Ghosh <cghosh12@in.ibm.com>
Wed, 12 Sep 2018 05:41:56 +0000 (11:11 +0530)
Added fix for potential nullpointerexception reported in sonar

Change-Id: Iea73bbaeb1dc7d8fdecf3243dc123dbfbb3b67b9
Issue-ID: SO-1026
Signed-off-by: Chandan Ghosh <cghosh12@in.ibm.com>
bpmn/so-bpmn-infrastructure-common/src/main/java/org/onap/so/bpmn/infrastructure/workflow/service/ServicePluginFactory.java

index 7226feb..80b64dd 100644 (file)
@@ -233,8 +233,11 @@ public class ServicePluginFactory {
 
                Map<String, Object> vpnRequestInputs = getVPNResourceRequestInputs(resources);
                // here we put client signal to vpn resource inputs
-               vpnRequestInputs.put("src-client-signal", srcClientSignal);
-               vpnRequestInputs.put("dst-client-signal", dstClientSignal);
+               if(null!=vpnRequestInputs) {
+                       vpnRequestInputs.put("src-client-signal", srcClientSignal);
+                       vpnRequestInputs.put("dst-client-signal", dstClientSignal);
+               }
+               
 
                // Now we need to query terminal points from SP resourcemgr system.
                List<Object> locationTerminalPointList = queryTerminalPointsFromServiceProviderSystem(srcLocation, dstLocation);