aboutsummaryrefslogtreecommitdiffstats
path: root/appc-config/appc-config-generator/provider/src/main/java/org/onap/sdnc/config/generator/reader/ReaderNode.java
diff options
context:
space:
mode:
authorJakub Dudycz <jakub.dudycz@nokia.com>2018-02-26 11:43:19 +0100
committerPatrick Brady <pb071s@att.com>2018-02-26 19:11:04 +0000
commit534f94b92547efab097040209e61fa06e07f6e43 (patch)
tree29fa789a3538c4e4c51361e03aeb721d25dbd947 /appc-config/appc-config-generator/provider/src/main/java/org/onap/sdnc/config/generator/reader/ReaderNode.java
parent23e0901d5ba71ebadfb99e91d10bda0275708518 (diff)
appc-config-generator-provider sonar fixes part 1
Initial code reformat and import rearrangement Change-Id: I0a808bc3043d8558d96f15e0b695fddf5333bab1 Issue-ID: APPC-671 Signed-off-by: Jakub Dudycz <jakub.dudycz@nokia.com>
Diffstat (limited to 'appc-config/appc-config-generator/provider/src/main/java/org/onap/sdnc/config/generator/reader/ReaderNode.java')
-rw-r--r--appc-config/appc-config-generator/provider/src/main/java/org/onap/sdnc/config/generator/reader/ReaderNode.java16
1 files changed, 8 insertions, 8 deletions
diff --git a/appc-config/appc-config-generator/provider/src/main/java/org/onap/sdnc/config/generator/reader/ReaderNode.java b/appc-config/appc-config-generator/provider/src/main/java/org/onap/sdnc/config/generator/reader/ReaderNode.java
index 501df635e..c657ee531 100644
--- a/appc-config/appc-config-generator/provider/src/main/java/org/onap/sdnc/config/generator/reader/ReaderNode.java
+++ b/appc-config/appc-config-generator/provider/src/main/java/org/onap/sdnc/config/generator/reader/ReaderNode.java
@@ -24,6 +24,8 @@
package org.onap.sdnc.config.generator.reader;
+import com.att.eelf.configuration.EELFLogger;
+import com.att.eelf.configuration.EELFManager;
import java.io.File;
import java.util.Map;
import org.apache.commons.io.FileUtils;
@@ -33,8 +35,6 @@ import org.onap.ccsdk.sli.core.sli.SvcLogicException;
import org.onap.ccsdk.sli.core.sli.SvcLogicJavaPlugin;
import org.onap.sdnc.config.generator.ConfigGeneratorConstant;
import org.onap.sdnc.config.generator.merge.MergeNode;
-import com.att.eelf.configuration.EELFLogger;
-import com.att.eelf.configuration.EELFManager;
public class ReaderNode implements SvcLogicJavaPlugin {
@@ -42,7 +42,7 @@ public class ReaderNode implements SvcLogicJavaPlugin {
public void getFileData(Map<String, String> inParams, SvcLogicContext ctx)
- throws SvcLogicException {
+ throws SvcLogicException {
log.info("Received getFileData call with params : " + inParams);
String responsePrefix = inParams.get(ConfigGeneratorConstant.INPUT_PARAM_RESPONSE_PRIFIX);
try {
@@ -50,17 +50,17 @@ public class ReaderNode implements SvcLogicJavaPlugin {
String fileName = inParams.get(ConfigGeneratorConstant.INPUT_PARAM_FILE_NAME);
String fileData = FileUtils.readFileToString(new File(fileName),
- ConfigGeneratorConstant.STRING_ENCODING);
+ ConfigGeneratorConstant.STRING_ENCODING);
ctx.setAttribute(responsePrefix + ConfigGeneratorConstant.OUTPUT_PARAM_FILE_DATA,
- fileData);
+ fileData);
ctx.setAttribute(responsePrefix + ConfigGeneratorConstant.OUTPUT_PARAM_STATUS,
- ConfigGeneratorConstant.OUTPUT_STATUS_SUCCESS);
+ ConfigGeneratorConstant.OUTPUT_STATUS_SUCCESS);
} catch (Exception e) {
ctx.setAttribute(responsePrefix + ConfigGeneratorConstant.OUTPUT_PARAM_STATUS,
- ConfigGeneratorConstant.OUTPUT_STATUS_FAILURE);
+ ConfigGeneratorConstant.OUTPUT_STATUS_FAILURE);
ctx.setAttribute(responsePrefix + ConfigGeneratorConstant.OUTPUT_PARAM_ERROR_MESSAGE,
- e.getMessage());
+ e.getMessage());
log.error("Failed in merging data to template " + e.getMessage());
throw new SvcLogicException(e.getMessage());
}