aboutsummaryrefslogtreecommitdiffstats
path: root/controlloop/common/model-impl/mso/src
diff options
context:
space:
mode:
authorMike Babinski <mb1915@att.com>2017-08-22 04:40:23 +0000
committerMike Babinski <mb1915@att.com>2017-08-23 22:19:40 +0000
commit945627aef4645a9a696aeb2150669e43aae9f98a (patch)
treec2c7aa3bc2124def4a41e3f1710946922d2d325d /controlloop/common/model-impl/mso/src
parent1b93494ed7c4808aaf979472a9349177ff99d8d8 (diff)
Fix Sonar Blockers for Drools-Applications
Add null checks to protect against potential null exceptions. Issue-ID: POLICY-111 Change-Id: Ib079d1b48a6858332ea3eaa0e75a991f518a0f9a Signed-off-by: Mike Babinski <mb1915@att.com>
Diffstat (limited to 'controlloop/common/model-impl/mso/src')
-rw-r--r--controlloop/common/model-impl/mso/src/main/java/org/onap/policy/mso/MSOManager.java8
1 files changed, 6 insertions, 2 deletions
diff --git a/controlloop/common/model-impl/mso/src/main/java/org/onap/policy/mso/MSOManager.java b/controlloop/common/model-impl/mso/src/main/java/org/onap/policy/mso/MSOManager.java
index 81d43ef76..9f4fe5bbc 100644
--- a/controlloop/common/model-impl/mso/src/main/java/org/onap/policy/mso/MSOManager.java
+++ b/controlloop/common/model-impl/mso/src/main/java/org/onap/policy/mso/MSOManager.java
@@ -87,8 +87,12 @@ public final class MSOManager {
}
Thread.sleep(20000);
}
-
- System.out.println("***** ######## VF Module Creation timeout. Status: ("+responseGet.request.requestStatus.requestState+")");
+ if (responseGet != null
+ && responseGet.request != null
+ && responseGet.request.requestStatus != null
+ && responseGet.request.requestStatus.requestState != null) {
+ logger.warn("***** ######## VF Module Creation timeout. Status: ( {})", responseGet.request.requestStatus.requestState);
+ }
return responseGet;
} catch (JsonSyntaxException e) {
logger.error("Failed to deserialize into MSOResponse: ", e);