summaryrefslogtreecommitdiffstats
path: root/appc-client/client-simulator/src/main
diff options
context:
space:
mode:
Diffstat (limited to 'appc-client/client-simulator/src/main')
-rw-r--r--appc-client/client-simulator/src/main/java/org/openecomp/appc/simulator/client/impl/JsonRequestHandler.java6
-rw-r--r--appc-client/client-simulator/src/main/java/org/openecomp/appc/simulator/client/impl/JsonResponseHandler.java4
-rw-r--r--appc-client/client-simulator/src/main/java/org/openecomp/appc/simulator/client/main/ClientRunner.java5
3 files changed, 10 insertions, 5 deletions
diff --git a/appc-client/client-simulator/src/main/java/org/openecomp/appc/simulator/client/impl/JsonRequestHandler.java b/appc-client/client-simulator/src/main/java/org/openecomp/appc/simulator/client/impl/JsonRequestHandler.java
index 3180e7849..e3a86e01a 100644
--- a/appc-client/client-simulator/src/main/java/org/openecomp/appc/simulator/client/impl/JsonRequestHandler.java
+++ b/appc-client/client-simulator/src/main/java/org/openecomp/appc/simulator/client/impl/JsonRequestHandler.java
@@ -50,7 +50,7 @@ import java.util.Properties;
public class JsonRequestHandler implements RequestHandler {
- private enum modeT {
+ private enum modeT {
SYNCH,
ASYNCH
}
@@ -79,6 +79,10 @@ public class JsonRequestHandler implements RequestHandler {
exceptRpcMap = prepareExceptionsMap();
}
+ public JsonRequestHandler(){
+
+ }
+
private HashMap<String,String> prepareExceptionsMap() {
exceptRpcMap = new HashMap<>();
diff --git a/appc-client/client-simulator/src/main/java/org/openecomp/appc/simulator/client/impl/JsonResponseHandler.java b/appc-client/client-simulator/src/main/java/org/openecomp/appc/simulator/client/impl/JsonResponseHandler.java
index aef034f53..5f14bb849 100644
--- a/appc-client/client-simulator/src/main/java/org/openecomp/appc/simulator/client/impl/JsonResponseHandler.java
+++ b/appc-client/client-simulator/src/main/java/org/openecomp/appc/simulator/client/impl/JsonResponseHandler.java
@@ -65,7 +65,7 @@ public class JsonResponseHandler implements ResponseHandler<Object> {
int errorCode = 0;
boolean isFinal = true;
try {
- JsonNode code = OBJECT_MAPPER.readTree(output).findValue("status").findValue("code");
+ JsonNode code= OBJECT_MAPPER.readTree(output).findValue("status").findValue("code");
if (code == null)
{
LOG.error("Status code doesn't exist. Malformed response : " + output);
@@ -130,7 +130,7 @@ public class JsonResponseHandler implements ResponseHandler<Object> {
this.flushToFile(output, ".error", isFinal);
}
- private void flushToFile(String output, String suffix, boolean isFinal) {
+ private void flushToFile(String output, String suffix, boolean isFinal) {
try (FileWriter fileWriter = new FileWriter(fileName + suffix);){
LOG.info("Output file : " + fileName + suffix);
diff --git a/appc-client/client-simulator/src/main/java/org/openecomp/appc/simulator/client/main/ClientRunner.java b/appc-client/client-simulator/src/main/java/org/openecomp/appc/simulator/client/main/ClientRunner.java
index d28927302..704fbee80 100644
--- a/appc-client/client-simulator/src/main/java/org/openecomp/appc/simulator/client/main/ClientRunner.java
+++ b/appc-client/client-simulator/src/main/java/org/openecomp/appc/simulator/client/main/ClientRunner.java
@@ -37,6 +37,7 @@ import java.util.List;
import java.util.Properties;
public class ClientRunner {
+
public static void main(String ... args) throws Exception {
String folder = args[0];
if (folder == null) {
@@ -66,7 +67,7 @@ public class ClientRunner {
// System.exit(0);
}
- private static Properties getProperties(String folder) {
+ private static Properties getProperties(String folder) {
Properties prop = new Properties();
InputStream conf = null;
@@ -91,7 +92,7 @@ public class ClientRunner {
return prop;
}
- private static List<File> getJsonFiles(String folder) throws FileNotFoundException {
+ private static List<File> getJsonFiles(String folder) throws FileNotFoundException {
Path dir = Paths.get(folder);
FileFilter fileFilter = new WildcardFileFilter("*.json");
return new ArrayList<File>(Arrays.asList(dir.toFile().listFiles(fileFilter)));