Add controller config code
Add SDC config parser code for mutliple SDC client configurations + unit
tests
Issue-ID: CLAMP-81
Change-Id: Ia97007463c6baf40456f97d9627da8b0ed3f4e49
Signed-off-by: Determe, Sebastien (sd378r) <sd378r@intl.att.com>
diff --git a/src/test/resources/clds/sdc-controllers-config-bad.json b/src/test/resources/clds/sdc-controllers-config-bad.json
new file mode 100644
index 0000000..0b417b7
--- /dev/null
+++ b/src/test/resources/clds/sdc-controllers-config-bad.json
@@ -0,0 +1,26 @@
+{
+ "sdc-connections":{,
+ "sdc-controller1":{
+ "user": "User1",
+ "consumerGroup": "consumerGroup1",
+ "consumerId": "consumerId1",
+ "environmentName": "environmentName1",
+ "sdcAddress": "hostname1",
+ "password": "bb3871669d893c7fb8aaacda31b77b4f537E67A081C2726889548ED7BC4C2DE6",
+ "pollingInterval":10,
+ "pollingTimeout":30
+
+ },
+ "sdc-controller2":{
+ "user": "User2",
+ "consumerGroup": "consumerGroup2",
+ "consumerId": "consumerId2",
+ "environmentName": "environmentName2",
+ "sdcAddress": "hostname2",
+ "password": "bb3871669d893c7fb8aaacda31b77b4f537E67A081C2726889548ED7BC4C2DE6",
+ "pollingInterval":10,
+ "pollingTimeout":30
+
+ }
+ }
+}
diff --git a/src/test/resources/clds/sdc-controllers-config-missing-param.json b/src/test/resources/clds/sdc-controllers-config-missing-param.json
new file mode 100644
index 0000000..d99ed58
--- /dev/null
+++ b/src/test/resources/clds/sdc-controllers-config-missing-param.json
@@ -0,0 +1,13 @@
+{
+ "sdc-connections": {
+ "sdc-controller1": {
+ "user": "testuser",
+ "consumerGroup": "consumerGroup",
+ "consumerId": "consumerId",
+ "environmentName": "environmentName",
+ "sdcAddress": "hostname1",
+ "pollingInterval": 10,
+ "pollingTimeout": 30
+ }
+ }
+}
diff --git a/src/test/resources/clds/sdc-controllers-config.json b/src/test/resources/clds/sdc-controllers-config.json
new file mode 100644
index 0000000..df73a50
--- /dev/null
+++ b/src/test/resources/clds/sdc-controllers-config.json
@@ -0,0 +1,26 @@
+{
+ "sdc-connections":{
+ "sdc-controller1":{
+ "user": "User1",
+ "consumerGroup": "consumerGroup1",
+ "consumerId": "consumerId1",
+ "environmentName": "environmentName1",
+ "sdcAddress": "hostname1",
+ "password": "bb3871669d893c7fb8aaacda31b77b4f537E67A081C2726889548ED7BC4C2DE6",
+ "pollingInterval":10,
+ "pollingTimeout":30
+
+ },
+ "sdc-controller2":{
+ "user": "User2",
+ "consumerGroup": "consumerGroup2",
+ "consumerId": "consumerId2",
+ "environmentName": "environmentName2",
+ "sdcAddress": "hostname2",
+ "password": "bb3871669d893c7fb8aaacda31b77b4f537E67A081C2726889548ED7BC4C2DE6",
+ "pollingInterval":10,
+ "pollingTimeout":30
+
+ }
+ }
+}