aboutsummaryrefslogtreecommitdiffstats
path: root/ms/vlantag-api
diff options
context:
space:
mode:
authorezhil <ezhrajam@in.ibm.com>2018-12-28 23:24:51 +0530
committerezhil <ezhrajam@in.ibm.com>2018-12-28 23:25:02 +0530
commit81c2abdcbe9ca52674be209f7c20ed4cb7e14c86 (patch)
tree54726e4ec31cf1dd541a9c93751442b3e07fc721 /ms/vlantag-api
parent65691146cceb8ee483cd4003f5fcc6fda14c0f01 (diff)
Fixed sonar issues in VlantagApiServiceImpl.java
Fixed major sonar issue Change-Id: I32700d3e42f3838ab2b7498047a782492409e619 Issue-ID: CCSDK-878 Signed-off-by: ezhil <ezhrajam@in.ibm.com>
Diffstat (limited to 'ms/vlantag-api')
-rw-r--r--ms/vlantag-api/src/main/java/org/onap/ccsdk/apps/ms/vlantagapi/core/service/VlantagApiServiceImpl.java5
1 files changed, 3 insertions, 2 deletions
diff --git a/ms/vlantag-api/src/main/java/org/onap/ccsdk/apps/ms/vlantagapi/core/service/VlantagApiServiceImpl.java b/ms/vlantag-api/src/main/java/org/onap/ccsdk/apps/ms/vlantagapi/core/service/VlantagApiServiceImpl.java
index 93f8a21e..abc18c5f 100644
--- a/ms/vlantag-api/src/main/java/org/onap/ccsdk/apps/ms/vlantagapi/core/service/VlantagApiServiceImpl.java
+++ b/ms/vlantag-api/src/main/java/org/onap/ccsdk/apps/ms/vlantagapi/core/service/VlantagApiServiceImpl.java
@@ -1,6 +1,6 @@
/*******************************************************************************
* Copyright © 2017-2018 AT&T Intellectual Property.
- *
+ * Modifications Copyright (C) 2018 IBM.
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
@@ -192,7 +192,7 @@ public class VlantagApiServiceImpl implements VlantagApiService {
* so it will ignore the current range min-max in the policy. Persist in the DB
* if available else Fail.
*/
- if (element.getOverwrite() != null && element.getOverwrite().equalsIgnoreCase("TRUE")) {
+ if (element.getOverwrite() != null && "TRUE".equalsIgnoreCase(element.getOverwrite())) {
Range range = new Range();
range.min = Integer.parseInt(resourceValue);
rangeList.add(range);
@@ -223,6 +223,7 @@ public class VlantagApiServiceImpl implements VlantagApiService {
return resourceValues[i].trim();
}
} catch (IndexOutOfBoundsException e) {
+ log.error("Exception : " + e.getMessage(), e);
throw new VlantagApiException("No Matching Resource Value found from Recipe : \""
+ model.getResourceResolutionRecipe() + "\" for Vlantag Name : " + element.getVlantagName());
}