Code Review
/
nonrtric.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
review
|
tree
raw
|
inline
| side by side
Changed the config loading from consul
[nonrtric.git]
/
policy-agent
/
src
/
test
/
java
/
org
/
oransc
/
policyagent
/
clients
/
A1ClientHelper.java
diff --git
a/policy-agent/src/test/java/org/oransc/policyagent/clients/A1ClientHelper.java
b/policy-agent/src/test/java/org/oransc/policyagent/clients/A1ClientHelper.java
index
7906446
..
79c8b11
100644
(file)
--- a/
policy-agent/src/test/java/org/oransc/policyagent/clients/A1ClientHelper.java
+++ b/
policy-agent/src/test/java/org/oransc/policyagent/clients/A1ClientHelper.java
@@
-20,10
+20,6
@@
package org.oransc.policyagent.clients;
package org.oransc.policyagent.clients;
-import com.google.gson.FieldNamingPolicy;
-import com.google.gson.Gson;
-import com.google.gson.GsonBuilder;
-
import java.util.Arrays;
import java.util.Vector;
import java.util.Arrays;
import java.util.Vector;
@@
-38,19
+34,10
@@
import org.oransc.policyagent.repository.Ric;
import reactor.core.publisher.Mono;
public class A1ClientHelper {
import reactor.core.publisher.Mono;
public class A1ClientHelper {
- private static Gson gson = new GsonBuilder() //
- .setFieldNamingPolicy(FieldNamingPolicy.LOWER_CASE_WITH_DASHES) //
- .create(); //
private A1ClientHelper() {
}
private A1ClientHelper() {
}
- protected static String createInputJsonString(SdncOscAdapterInput inputParams) {
- JSONObject inputJson = new JSONObject();
- inputJson.put("input", new JSONObject(gson.toJson(inputParams)));
- return inputJson.toString();
- }
-
protected static Mono<String> createOutputJsonResponse(String key, String value) {
JSONObject paramsJson = new JSONObject();
paramsJson.put(key, value);
protected static Mono<String> createOutputJsonResponse(String key, String value) {
JSONObject paramsJson = new JSONObject();
paramsJson.put(key, value);
@@
-63,6
+50,7
@@
public class A1ClientHelper {
RicConfig cfg = ImmutableRicConfig.builder().name("ric") //
.baseUrl(url) //
.managedElementIds(new Vector<String>(Arrays.asList("kista_1", "kista_2"))) //
RicConfig cfg = ImmutableRicConfig.builder().name("ric") //
.baseUrl(url) //
.managedElementIds(new Vector<String>(Arrays.asList("kista_1", "kista_2"))) //
+ .controllerName("") //
.build();
return new Ric(cfg);
}
.build();
return new Ric(cfg);
}