diff options
author | Seshu Kumar M <seshu.kumar.m@huawei.com> | 2017-09-27 15:19:46 +0000 |
---|---|---|
committer | Gerrit Code Review <gerrit@onap.org> | 2017-09-27 15:19:46 +0000 |
commit | 054840dc9033bb8eb3c12dba26d4ef5c6d4daabf (patch) | |
tree | a8a74d79f5b0f790a1310991308bd7db22318c59 | |
parent | 688effd1e56189c6ba9e8e80bd4b121974ef8afa (diff) | |
parent | c49835e6f8ced1dc5461d5e9a8a4f9cd798e867d (diff) |
Merge "Removed useless assignment to variables"
4 files changed, 7 insertions, 7 deletions
diff --git a/adapters/mso-adapters-rest-interface/src/main/java/org/openecomp/mso/adapters/tenantrest/TenantRequestCommon.java b/adapters/mso-adapters-rest-interface/src/main/java/org/openecomp/mso/adapters/tenantrest/TenantRequestCommon.java index 98be3c1478..778a329979 100644 --- a/adapters/mso-adapters-rest-interface/src/main/java/org/openecomp/mso/adapters/tenantrest/TenantRequestCommon.java +++ b/adapters/mso-adapters-rest-interface/src/main/java/org/openecomp/mso/adapters/tenantrest/TenantRequestCommon.java @@ -36,7 +36,7 @@ public class TenantRequestCommon { private static MsoLogger LOGGER = MsoLogger.getMsoLogger (MsoLogger.Catalog.RA); public String toJsonString() { try { - String jsonString = null; + String jsonString; ObjectMapper mapper = new ObjectMapper(); mapper.enable(SerializationConfig.Feature.WRAP_ROOT_VALUE); jsonString = mapper.writeValueAsString(this); diff --git a/mso-api-handlers/mso-api-handler-common/src/main/java/org/openecomp/mso/apihandler/common/RequestClientFactory.java b/mso-api-handlers/mso-api-handler-common/src/main/java/org/openecomp/mso/apihandler/common/RequestClientFactory.java index a1f3805c7f..773c5b0a96 100644 --- a/mso-api-handlers/mso-api-handler-common/src/main/java/org/openecomp/mso/apihandler/common/RequestClientFactory.java +++ b/mso-api-handlers/mso-api-handler-common/src/main/java/org/openecomp/mso/apihandler/common/RequestClientFactory.java @@ -35,7 +35,7 @@ public class RequestClientFactory { if(props ==null){ throw new IllegalStateException("properties is null"); } - String url = null; + String url; if(orchestrationURI.contains(CommonConstants.BPEL_SEARCH_STR)){ url = props.getProperty(CommonConstants.BPEL_URL,null) + orchestrationURI; retClient= new BPELRestClient(); diff --git a/mso-api-handlers/mso-api-handler-infra/src/main/java/org/openecomp/mso/apihandlerinfra/Messages.java b/mso-api-handlers/mso-api-handler-infra/src/main/java/org/openecomp/mso/apihandlerinfra/Messages.java index 0f39ad07b6..911808388f 100644 --- a/mso-api-handlers/mso-api-handler-infra/src/main/java/org/openecomp/mso/apihandlerinfra/Messages.java +++ b/mso-api-handlers/mso-api-handler-infra/src/main/java/org/openecomp/mso/apihandlerinfra/Messages.java @@ -28,7 +28,7 @@ import org.openecomp.mso.apihandler.common.ErrorNumbers; public class Messages { - public static final Map<String,String> errors = new HashMap<String,String>(); + public static final Map<String,String> errors = new HashMap<>(); static { errors.put(ErrorNumbers.REQUEST_FAILED_SCHEMA_VALIDATION + "_service", "Service request FAILED schema validation. %s"); errors.put(ErrorNumbers.REQUEST_FAILED_SCHEMA_VALIDATION + "_feature", "Feature request FAILED schema validation. %s"); diff --git a/mso-api-handlers/mso-api-handler-infra/src/main/java/org/openecomp/mso/apihandlerinfra/NetworkInfoHandler.java b/mso-api-handlers/mso-api-handler-infra/src/main/java/org/openecomp/mso/apihandlerinfra/NetworkInfoHandler.java index f61a50bb06..bcea8fd8d5 100644 --- a/mso-api-handlers/mso-api-handler-infra/src/main/java/org/openecomp/mso/apihandlerinfra/NetworkInfoHandler.java +++ b/mso-api-handlers/mso-api-handler-infra/src/main/java/org/openecomp/mso/apihandlerinfra/NetworkInfoHandler.java @@ -85,7 +85,7 @@ public class NetworkInfoHandler { + aicNodeClli + " - tenant id " + tenantId); - Response response = null; + Response response; if (networkType != null) { response = this.getRequestList ("vnfType", networkType, version); } else { @@ -216,7 +216,7 @@ public class NetworkInfoHandler { MsoLogger.setLogContext (requestId, null); getMsoLogger ().debug ("getRequest: " + requestId); - String responseString = null; + String responseString; InfraActiveRequests activeReq = (RequestsDatabase.getInstance()).getRequestFromInfraActive (requestId, "NETWORK"); if (activeReq != null) { @@ -239,7 +239,7 @@ public class NetworkInfoHandler { queryValue, "NETWORK"); - List <NetworkRequest> queryResponseList = new LinkedList <NetworkRequest> (); + List <NetworkRequest> queryResponseList = new LinkedList <> (); if (activeReqList != null) { // build response for active @@ -283,7 +283,7 @@ public class NetworkInfoHandler { } private List <NetworkRequest> infraRequestsResponses (List <? extends InfraRequests> arList, String version) { - List <NetworkRequest> queryResponseList = new LinkedList <NetworkRequest> (); + List <NetworkRequest> queryResponseList = new LinkedList <> (); for (InfraRequests ar : arList) { NetworkRequest qr = fillGeneric (ar); |