summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorprakash.e <prakash.e@huawei.com>2017-12-21 16:52:36 +0530
committerprakash eswaramoorthy <prakash.e@huawei.com>2017-12-21 11:35:14 +0000
commit263950413073f5d1d7af3d2854052af8ec41d281 (patch)
tree5f95b6be67ad9f4e690d78e6d3c51d53d745c28d
parent124fa28fffe41658dd9a7fc77c91b3279a7c92cd (diff)
Removal of unused private field
Change-Id: Ie2d33f7f9dba20a4d0fdf6a33f8574e953633a69 Issue-ID: CCSDK-151 Signed-off-by: prakash.e <prakash.e@huawei.com>
-rw-r--r--dmaap-listener/src/main/java/org/onap/ccsdk/sli/northbound/dmaapclient/SdncDmaapConsumer.java5
-rw-r--r--dmaap-listener/src/main/java/org/onap/ccsdk/sli/northbound/dmaapclient/SdncFlatJsonDmaapConsumer.java6
2 files changed, 5 insertions, 6 deletions
diff --git a/dmaap-listener/src/main/java/org/onap/ccsdk/sli/northbound/dmaapclient/SdncDmaapConsumer.java b/dmaap-listener/src/main/java/org/onap/ccsdk/sli/northbound/dmaapclient/SdncDmaapConsumer.java
index a51ea7c8..a9f5feda 100644
--- a/dmaap-listener/src/main/java/org/onap/ccsdk/sli/northbound/dmaapclient/SdncDmaapConsumer.java
+++ b/dmaap-listener/src/main/java/org/onap/ccsdk/sli/northbound/dmaapclient/SdncDmaapConsumer.java
@@ -35,7 +35,6 @@ public abstract class SdncDmaapConsumer implements Runnable {
private static final Logger LOG = LoggerFactory
.getLogger(SdncDmaapConsumer.class);
- private String propertiesPath = "";
private Properties properties = null;
private MRConsumer consumer = null;
private MRConsumerResponse consumerResponse = null;
@@ -62,13 +61,11 @@ public abstract class SdncDmaapConsumer implements Runnable {
}
public String getProperty(String name) {
- return (properties.getProperty(name, ""));
+ return properties.getProperty(name, "");
}
public void init(Properties properties, String propertiesPath) {
- this.propertiesPath = propertiesPath;
-
try (FileInputStream in = new FileInputStream(new File(propertiesPath))) {
LOG.debug("propertiesPath: " + propertiesPath);
diff --git a/dmaap-listener/src/main/java/org/onap/ccsdk/sli/northbound/dmaapclient/SdncFlatJsonDmaapConsumer.java b/dmaap-listener/src/main/java/org/onap/ccsdk/sli/northbound/dmaapclient/SdncFlatJsonDmaapConsumer.java
index 1d499a1e..ce65e783 100644
--- a/dmaap-listener/src/main/java/org/onap/ccsdk/sli/northbound/dmaapclient/SdncFlatJsonDmaapConsumer.java
+++ b/dmaap-listener/src/main/java/org/onap/ccsdk/sli/northbound/dmaapclient/SdncFlatJsonDmaapConsumer.java
@@ -124,6 +124,8 @@ public class SdncFlatJsonDmaapConsumer extends SdncDmaapConsumer {
private Map<String, String> loadMap(String msgType, String mapDirName) {
Map<String, String> results = new HashMap<>();
+ String dirName = mapDirName;
+
if (mapDirName == null) {
String rootdir = System.getenv(DMAAPLISTENERROOT);
@@ -131,10 +133,10 @@ public class SdncFlatJsonDmaapConsumer extends SdncDmaapConsumer {
rootdir = "/opt/app/dmaap-listener";
}
- mapDirName = rootdir + "/lib";
+ dirName = rootdir + "/lib";
}
- String mapFilename = mapDirName + "/" + msgType + ".map";
+ String mapFilename = dirName + "/" + msgType + ".map";
File mapFile = new File(mapFilename);