lower code smells 11/107611/3
authorRupinder <rupinsi1@in.ibm.com>
Wed, 13 May 2020 08:32:09 +0000 (14:02 +0530)
committerTakamune Cho <takamune.cho@att.com>
Thu, 14 May 2020 13:42:38 +0000 (13:42 +0000)
Issue-ID: APPC-1859
Change-Id: If95047a9f6b568c8ef4796d48572c23a36ac36fc
Signed-off-by: Rupinder <rupinsi1@in.ibm.com>
appc-dispatcher/appc-request-handler/appc-request-handler-core/src/main/java/org/onap/appc/requesthandler/impl/DmaapOutgoingMessage.java
appc-dispatcher/appc-request-handler/appc-request-handler-core/src/main/java/org/onap/appc/requesthandler/impl/RequestValidatorImpl.java
appc-dispatcher/appc-workflow-management/appc-workflow-management-core/src/main/java/org/onap/appc/workflow/impl/WorkFlowManagerImpl.java
appc-inbound/appc-interfaces-service/bundle/src/main/java/org/onap/appc/interfaces/service/InterfacesServiceProvider.java
appc-oam/appc-oam-bundle/src/main/java/org/onap/appc/oam/AppcOam.java
appc-oam/appc-oam-bundle/src/main/java/org/onap/appc/oam/util/BundleHelper.java
appc-oam/appc-oam-bundle/src/main/java/org/onap/appc/oam/util/ConfigurationHelper.java

index ba39b70..23d0e1c 100644 (file)
@@ -47,7 +47,7 @@ public class DmaapOutgoingMessage {
     @JsonProperty("correlation-id")
     private String correlationID;
 
-    private final static String defaultCambriaPartition = "MSO";
+    private static final String defaultCambriaPartition = "MSO";
     @JsonProperty("cambria.partition")
     private String cambriaPartition = defaultCambriaPartition;
 
index 71545ab..6605d1e 100644 (file)
@@ -27,7 +27,6 @@ package org.onap.appc.requesthandler.impl;
 import com.att.eelf.i18n.EELFResourceManager;
 import com.fasterxml.jackson.databind.JsonNode;
 import com.fasterxml.jackson.databind.ObjectMapper;
-import com.fasterxml.jackson.databind.node.ObjectNode;
 
 import org.apache.commons.io.IOUtils;
 import org.apache.commons.lang.ObjectUtils;
index 659c3fb..172d8c4 100644 (file)
@@ -23,7 +23,6 @@
 package org.onap.appc.workflow.impl;
 
 import org.apache.commons.lang.ObjectUtils;
-import org.apache.commons.lang3.StringUtils;
 import org.onap.appc.common.constant.Constants;
 import org.onap.appc.configuration.Configuration;
 import org.onap.appc.configuration.ConfigurationFactory;
@@ -45,12 +44,10 @@ import org.osgi.framework.BundleContext;
 import org.osgi.framework.FrameworkUtil;
 import org.osgi.framework.ServiceReference;
 import java.util.ArrayList;
-import java.util.List;
 import org.onap.ccsdk.sli.core.dblib.DbLibService;
 import org.onap.ccsdk.sli.core.sli.SvcLogicGraph;
 import javax.sql.rowset.CachedRowSet;
 import java.sql.SQLException;
-import java.sql.Blob;
 import java.io.ObjectInputStream;
 import java.io.IOException;
 import org.slf4j.MDC;
index 242f55f..5b64c95 100644 (file)
@@ -29,7 +29,6 @@ import org.opendaylight.controller.md.sal.binding.api.DataBroker;
 import org.opendaylight.controller.sal.binding.api.BindingAwareBroker.RpcRegistration;
 import org.opendaylight.controller.sal.binding.api.RpcProviderRegistry;
 import org.opendaylight.yang.gen.v1.org.onap.appc.interfaces.service.rev170818.InterfacesServiceService;
-import org.onap.appc.interfaces.service.InterfacesServiceProviderImpl;
 
 import com.att.eelf.configuration.EELFLogger;
 import com.att.eelf.configuration.EELFManager;
index c41abb2..50c6d49 100644 (file)
@@ -91,7 +91,7 @@ public class AppcOam implements AutoCloseable, AppcOamService {
     /**
      * Invalid state message format with fliexible operation, appc name and state values
      */
-    public final static String INVALID_STATE_MESSAGE_FORMAT = "%s API is not allowed when %s is in the %s state.";
+    public static final String INVALID_STATE_MESSAGE_FORMAT = "%s API is not allowed when %s is in the %s state.";
 
     private final EELFLogger logger = EELFManager.getInstance().getLogger(AppcOam.class);
 
index 7639c40..9559b54 100644 (file)
@@ -44,8 +44,8 @@ import java.util.concurrent.Future;
  * Utility class provides general bundle operational helps.
  */
 public class BundleHelper {
-    private final static String PROP_BUNDLE_TO_STOP = "appc.OAM.ToStop.properties";
-    private final static String PROP_BUNDLES_TO_NOT_STOP = "appc.OAM.ToNotStop.properties";
+    private static final String PROP_BUNDLE_TO_STOP = "appc.OAM.ToStop.properties";
+    private static final String PROP_BUNDLES_TO_NOT_STOP = "appc.OAM.ToNotStop.properties";
 
     private final EELFLogger logger;
     private final StateHelper stateHelper;
index 63cff68..d6f2719 100644 (file)
@@ -35,8 +35,8 @@ import java.util.concurrent.TimeUnit;
  * Utility class provides general configuration helps
  */
 public class ConfigurationHelper {
-    final static String PROP_KEY_APPC_NAME = Constants.PROPERTY_APPLICATION_NAME;
-    final static String PROP_KEY_METRIC_STATE = "metric.enabled";
+    static final String PROP_KEY_APPC_NAME = Constants.PROPERTY_APPLICATION_NAME;
+    static final String PROP_KEY_METRIC_STATE = "metric.enabled";
     private final String OAM_OPERATION_TIMEOUT_SECOND = "appc.OAM.api.timeout";
     /** Default operation timeout set to 1 minute */
     private final int DEFAULT_OAM_OPERATION_TIMEOUT = 60;