summaryrefslogtreecommitdiffstats
path: root/services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters
diff options
context:
space:
mode:
Diffstat (limited to 'services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters')
-rw-r--r--services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters/ContextParameterTests.java19
-rw-r--r--services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters/ParameterTests.java29
-rw-r--r--services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters/ProducerConsumerTests.java36
-rw-r--r--services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters/SyncParameterTests.java11
-rw-r--r--services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters/dummyclasses/SuperDooperCarrierTechnologyParameters.java53
-rw-r--r--services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters/dummyclasses/SuperDooperDistributorParameters.java4
-rw-r--r--services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters/dummyclasses/SuperTokenDelimitedEventProtocolParameters.java4
7 files changed, 88 insertions, 68 deletions
diff --git a/services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters/ContextParameterTests.java b/services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters/ContextParameterTests.java
index bfda220a5..56e716dd6 100644
--- a/services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters/ContextParameterTests.java
+++ b/services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters/ContextParameterTests.java
@@ -65,8 +65,8 @@ public class ContextParameterTests {
} catch (final ParameterException e) {
assertEquals("error reading parameters from \"src/test/resources/parameters/serviceContextBadParams.json\""
+ "\n(ParameterRuntimeException):failed to deserialize the parameters for "
- + "\"contextParameters\" to parameter class \"hello\"\njava.lang.ClassNotFoundException: hello",
- e.getMessage());
+ + "\"contextParameters\" to parameter class "
+ + "\"hello\"\njava.lang.ClassNotFoundException: hello", e.getMessage());
}
}
@@ -97,8 +97,10 @@ public class ContextParameterTests {
new ApexParameterHandler().getParameters(arguments);
fail("This test should throw an exception");
} catch (final ParameterException e) {
- assertEquals("error reading parameters from \"src/test/resources/parameters/serviceContextBadClassParams.json\""
- + "\n(ParameterRuntimeException):failed to deserialize the parameters for \"contextParameters\""
+ assertEquals("error reading parameters from "
+ + "\"src/test/resources/parameters/serviceContextBadClassParams.json\""
+ + "\n(ParameterRuntimeException):failed to deserialize "
+ + "the parameters for \"contextParameters\""
+ " to parameter class \"java.lang.Integer\"\ncom.google.gson.JsonSyntaxException: "
+ "java.lang.IllegalStateException: Expected NUMBER but was BEGIN_OBJECT at path $",
e.getMessage());
@@ -253,7 +255,8 @@ public class ContextParameterTests {
} catch (final ParameterException e) {
assertEquals("error reading parameters from "
+ "\"src/test/resources/parameters/serviceContextBadClassDistParams.json\"\n"
- + "(ClassCastException):org.onap.policy.apex.context.parameters.ContextParameters cannot be cast to"
+ + "(ClassCastException):"
+ + "org.onap.policy.apex.context.parameters.ContextParameters cannot be cast to"
+ " org.onap.policy.apex.context.parameters.DistributorParameters", e.getMessage());
}
}
@@ -270,7 +273,8 @@ public class ContextParameterTests {
} catch (final ParameterException e) {
assertEquals("error reading parameters from "
+ "\"src/test/resources/parameters/serviceContextBadClassLockParams.json\"\n"
- + "(ClassCastException):org.onap.policy.apex.context.parameters.ContextParameters cannot be cast to"
+ + "(ClassCastException):"
+ + "org.onap.policy.apex.context.parameters.ContextParameters cannot be cast to"
+ " org.onap.policy.apex.context.parameters.LockManagerParameters", e.getMessage());
}
}
@@ -287,7 +291,8 @@ public class ContextParameterTests {
} catch (final ParameterException e) {
assertEquals("error reading parameters from "
+ "\"src/test/resources/parameters/serviceContextBadClassPersistParams.json\"\n"
- + "(ClassCastException):org.onap.policy.apex.context.parameters.ContextParameters cannot be cast to"
+ + "(ClassCastException):"
+ + "org.onap.policy.apex.context.parameters.ContextParameters cannot be cast to"
+ " org.onap.policy.apex.context.parameters.PersistorParameters", e.getMessage());
}
}
diff --git a/services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters/ParameterTests.java b/services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters/ParameterTests.java
index 97724becc..7b71253b0 100644
--- a/services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters/ParameterTests.java
+++ b/services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters/ParameterTests.java
@@ -156,7 +156,7 @@ public class ParameterTests {
+ "\"org.onap.policy.apex.service.parameters.eventhandler.EventHandlerParameters\" INVALID"
+ ", parameter group has status INVALID\n" + " parameter group \"FILE\" type "
+ "\"org.onap.policy.apex.service.engine.event.impl."
- + "filecarrierplugin.FILECarrierTechnologyParameters\" INVALID, "
+ + "filecarrierplugin.FileCarrierTechnologyParameters\" INVALID, "
+ "parameter group has status INVALID\n"
+ " field \"fileName\" type \"java.lang.String\" value \"null\" INVALID, "
+ "fileName not specified or is blank or null, "
@@ -166,7 +166,7 @@ public class ParameterTests {
+ "\"org.onap.policy.apex.service.parameters.eventhandler.EventHandlerParameters\" INVALID"
+ ", parameter group has status INVALID\n" + " parameter group \"FILE\" type "
+ "\"org.onap.policy.apex.service.engine.event.impl."
- + "filecarrierplugin.FILECarrierTechnologyParameters\" INVALID, "
+ + "filecarrierplugin.FileCarrierTechnologyParameters\" INVALID, "
+ "parameter group has status INVALID\n"
+ " field \"fileName\" type \"java.lang.String\" value \"null\" INVALID, "
+ "fileName not specified or is blank or null, "
@@ -241,23 +241,24 @@ public class ParameterTests {
assertEquals(345, parameters.getEngineServiceParameters().getInstanceCount());
assertEquals(65522, parameters.getEngineServiceParameters().getDeploymentPort());
- final CarrierTechnologyParameters prodCT = parameters.getEventOutputParameters().get("FirstProducer")
- .getCarrierTechnologyParameters();
- final EventProtocolParameters prodEP = parameters.getEventOutputParameters().get("FirstProducer")
+ final CarrierTechnologyParameters prodCarrierTech = parameters.getEventOutputParameters()
+ .get("FirstProducer").getCarrierTechnologyParameters();
+ final EventProtocolParameters prodEventProt = parameters.getEventOutputParameters().get("FirstProducer")
.getEventProtocolParameters();
- final CarrierTechnologyParameters consCT = parameters.getEventInputParameters()
+ final CarrierTechnologyParameters consCarrierTech = parameters.getEventInputParameters()
.get("MySuperDooperConsumer1").getCarrierTechnologyParameters();
- final EventProtocolParameters consEP = parameters.getEventInputParameters().get("MySuperDooperConsumer1")
- .getEventProtocolParameters();
+ final EventProtocolParameters consEventProt = parameters.getEventInputParameters()
+ .get("MySuperDooperConsumer1").getEventProtocolParameters();
- assertEquals("SUPER_DOOPER", prodCT.getLabel());
- assertEquals("SUPER_TOK_DEL", prodEP.getLabel());
- assertEquals("SUPER_DOOPER", consCT.getLabel());
- assertEquals("JSON", consEP.getLabel());
+ assertEquals("SUPER_DOOPER", prodCarrierTech.getLabel());
+ assertEquals("SUPER_TOK_DEL", prodEventProt.getLabel());
+ assertEquals("SUPER_DOOPER", consCarrierTech.getLabel());
+ assertEquals("JSON", consEventProt.getLabel());
- assertTrue(prodCT instanceof SuperDooperCarrierTechnologyParameters);
+ assertTrue(prodCarrierTech instanceof SuperDooperCarrierTechnologyParameters);
- final SuperDooperCarrierTechnologyParameters superDooperParameters = (SuperDooperCarrierTechnologyParameters) prodCT;
+ final SuperDooperCarrierTechnologyParameters superDooperParameters =
+ (SuperDooperCarrierTechnologyParameters) prodCarrierTech;
assertEquals("somehost:12345", superDooperParameters.getBootstrapServers());
assertEquals("0", superDooperParameters.getAcks());
assertEquals(25, superDooperParameters.getRetries());
diff --git a/services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters/ProducerConsumerTests.java b/services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters/ProducerConsumerTests.java
index 26cf09c38..374a2df14 100644
--- a/services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters/ProducerConsumerTests.java
+++ b/services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters/ProducerConsumerTests.java
@@ -24,7 +24,7 @@ import static org.junit.Assert.assertEquals;
import static org.junit.Assert.fail;
import org.junit.Test;
-import org.onap.policy.apex.service.engine.event.impl.filecarrierplugin.FILECarrierTechnologyParameters;
+import org.onap.policy.apex.service.engine.event.impl.filecarrierplugin.FileCarrierTechnologyParameters;
import org.onap.policy.apex.service.engine.main.ApexCommandLineArguments;
import org.onap.policy.apex.service.parameters.ApexParameterHandler;
import org.onap.policy.apex.service.parameters.ApexParameters;
@@ -117,7 +117,7 @@ public class ProducerConsumerTests {
+ "\"org.onap.policy.apex.service.parameters.eventhandler.EventHandlerParameters\" INVALID"
+ ", parameter group has status INVALID\n" + " parameter group \"FILE\" type "
+ "\"org.onap.policy.apex.service.engine.event.impl."
- + "filecarrierplugin.FILECarrierTechnologyParameters\" INVALID, "
+ + "filecarrierplugin.FileCarrierTechnologyParameters\" INVALID, "
+ "parameter group has status INVALID\n"
+ " field \"fileName\" type \"java.lang.String\" value \"null\" INVALID, "
+ "fileName not specified or is blank or null, "
@@ -156,8 +156,8 @@ public class ProducerConsumerTests {
+ "(ParameterRuntimeException):carrier technology \"SUPER_LOOPER\" "
+ "does not match plugin \"SUPER_DOOPER\" in \"" + "org.onap.policy.apex.service.engine."
+ "parameters.dummyclasses.SuperDooperCarrierTechnologyParameters"
- + "\", specify correct carrier technology parameter plugin in parameter \"parameterClassName\"",
- e.getMessage());
+ + "\", specify correct carrier technology parameter plugin "
+ + "in parameter \"parameterClassName\"", e.getMessage());
}
}
@@ -189,11 +189,11 @@ public class ProducerConsumerTests {
try {
final ApexParameters parameters = new ApexParameterHandler().getParameters(arguments);
- final FILECarrierTechnologyParameters fileParams = (FILECarrierTechnologyParameters) parameters
+ final FileCarrierTechnologyParameters fileParams = (FileCarrierTechnologyParameters) parameters
.getEventOutputParameters().get("aProducer").getCarrierTechnologyParameters();
assertEquals("/tmp/aaa.json", fileParams.getFileName());
assertEquals(false, fileParams.isStandardError());
- assertEquals(false, fileParams.isStandardIO());
+ assertEquals(false, fileParams.isStandardIo());
assertEquals(false, fileParams.isStreamingMode());
} catch (final ParameterException e) {
fail("This test should not throw an exception");
@@ -210,18 +210,20 @@ public class ProducerConsumerTests {
new ApexParameterHandler().getParameters(arguments);
fail("This test should throw an exception");
} catch (final ParameterException e) {
- assertEquals("validation error(s) on parameters from \"src/test/resources/parameters/prodConsBadFileName.json\"\n"
+ assertEquals("validation error(s) on parameters from "
+ + "\"src/test/resources/parameters/prodConsBadFileName.json\"\n"
+ "parameter group \"APEX_PARAMETERS\" type "
+ "\"org.onap.policy.apex.service.parameters.ApexParameters\" INVALID, "
+ "parameter group has status INVALID\n"
- + " parameter group map \"eventOutputParameters\" INVALID, parameter group has status INVALID\n"
- + " parameter group \"aProducer\" type "
- + "\"org.onap.policy.apex.service.parameters.eventhandler.EventHandlerParameters\" INVALID, "
- + "parameter group has status INVALID\n" + " parameter group \"FILE\" type "
+ + " parameter group map \"eventOutputParameters\" INVALID, "
+ + "parameter group has status INVALID\n" + " parameter group \"aProducer\" type "
+ + "\"org.onap.policy.apex.service.parameters.eventhandler.EventHandlerParameters\" "
+ + "INVALID, parameter group has status INVALID\n" + " parameter group \"FILE\" type "
+ "\"org.onap.policy.apex.service.engine.event.impl."
- + "filecarrierplugin.FILECarrierTechnologyParameters\" INVALID, "
+ + "filecarrierplugin.FileCarrierTechnologyParameters\" INVALID, "
+ "parameter group has status INVALID\n" + " field \"fileName\" type "
- + "\"java.lang.String\" value \"null\" INVALID, fileName not specified or is blank or null, "
+ + "\"java.lang.String\" value \"null\" INVALID, "
+ + "fileName not specified or is blank or null, "
+ "it must be specified as a valid file location\n", e.getMessage());
}
}
@@ -237,8 +239,9 @@ public class ProducerConsumerTests {
fail("This test should throw an exception");
} catch (final ParameterException e) {
assertEquals("error reading parameters from \"src/test/resources/parameters/prodConsBadEPParClass.json\"\n"
- + "(ParameterRuntimeException):event protocol \"SUPER_TOK_DEL\" does not match plugin \"JSON\" in "
- + "\"org.onap.policy.apex.service.engine.event.impl.jsonprotocolplugin.JSONEventProtocolParameters"
+ + "(ParameterRuntimeException):event protocol \"SUPER_TOK_DEL\" "
+ + "does not match plugin \"JSON\" in \"org.onap.policy.apex.service.engine.event.impl"
+ + ".jsonprotocolplugin.JsonEventProtocolParameters"
+ "\", specify correct event protocol parameter plugin in parameter \"parameterClassName\"",
e.getMessage());
}
@@ -270,7 +273,8 @@ public class ProducerConsumerTests {
new ApexParameterHandler().getParameters(arguments);
fail("This test should throw an exception");
} catch (final ParameterException e) {
- assertEquals("error reading parameters from \"src/test/resources/parameters/prodConsMismatchEPParClass.json\"\n"
+ assertEquals("error reading parameters from "
+ + "\"src/test/resources/parameters/prodConsMismatchEPParClass.json\"\n"
+ "(ParameterRuntimeException):event protocol \"SUPER_TOK_BEL\" "
+ "does not match plugin \"SUPER_TOK_DEL\" in "
+ "\"org.onap.policy.apex.service.engine.parameters.dummyclasses."
diff --git a/services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters/SyncParameterTests.java b/services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters/SyncParameterTests.java
index 7913af84c..8ad0654b1 100644
--- a/services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters/SyncParameterTests.java
+++ b/services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters/SyncParameterTests.java
@@ -151,8 +151,8 @@ public class SyncParameterTests {
+ "specify a non-negative timeout value in milliseconds\n"
+ " parameter group map \"eventInputParameters\" INVALID, "
+ "parameter group has status INVALID\n" + " parameter group \"SyncConsumer0\" type "
- + "\"org.onap.policy.apex.service.parameters.eventhandler.EventHandlerParameters\" INVALID, "
- + "specified peered mode \"SYNCHRONOUS\" timeout value \"-1\" is illegal, "
+ + "\"org.onap.policy.apex.service.parameters.eventhandler.EventHandlerParameters\" "
+ + "INVALID, specified peered mode \"SYNCHRONOUS\" timeout value \"-1\" is illegal, "
+ "specify a non-negative timeout value in milliseconds\n"
+ " parameter group \"SyncConsumer1\" type "
+ "\"org.onap.policy.apex.service.parameters.eventhandler.EventHandlerParameters\" INVALID,"
@@ -371,8 +371,8 @@ public class SyncParameterTests {
+ "\"org.onap.policy.apex.service.parameters.eventhandler.EventHandlerParameters\" INVALID"
+ ", peer \"SyncConsumer0 for peered mode SYNCHRONOUS, value \"SyncProducer1\" on peer "
+ "\"SyncConsumer0\" does not equal event handler \"SyncProducer0\"\n"
- + " parameter group map \"eventInputParameters\" INVALID, parameter group has status INVALID\n"
- + " parameter group \"SyncConsumer0\" type "
+ + " parameter group map \"eventInputParameters\" INVALID, parameter group has status "
+ + "INVALID\n parameter group \"SyncConsumer0\" type "
+ "\"org.onap.policy.apex.service.parameters.eventhandler.EventHandlerParameters\" INVALID"
+ ", peer \"SyncProducer1 for peered mode SYNCHRONOUS, value \"SyncConsumer1\" on peer "
+ "\"SyncProducer1\" does not equal event handler \"SyncConsumer0\"\n", e.getMessage());
@@ -454,7 +454,8 @@ public class SyncParameterTests {
assertTrue(consCT1 instanceof SuperDooperCarrierTechnologyParameters);
assertTrue(consEP1 instanceof SuperTokenDelimitedEventProtocolParameters);
- final SuperDooperCarrierTechnologyParameters superDooperParameters = (SuperDooperCarrierTechnologyParameters) consCT1;
+ final SuperDooperCarrierTechnologyParameters superDooperParameters =
+ (SuperDooperCarrierTechnologyParameters) consCT1;
assertEquals("localhost:9092", superDooperParameters.getBootstrapServers());
assertEquals("all", superDooperParameters.getAcks());
assertEquals(0, superDooperParameters.getRetries());
diff --git a/services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters/dummyclasses/SuperDooperCarrierTechnologyParameters.java b/services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters/dummyclasses/SuperDooperCarrierTechnologyParameters.java
index 7eaf4c8e1..ccde5199a 100644
--- a/services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters/dummyclasses/SuperDooperCarrierTechnologyParameters.java
+++ b/services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters/dummyclasses/SuperDooperCarrierTechnologyParameters.java
@@ -47,11 +47,12 @@ public class SuperDooperCarrierTechnologyParameters extends CarrierTechnologyPar
private static final int DEFAULT_SESSION_TIMEOUT = 30000;
private static final String DEFAULT_PRODUCER_TOPIC = "apex-out";
private static final int DEFAULT_CONSUMER_POLL_TIME = 100;
- private static final String[] DEFAULT_CONSUMER_TOPIC_LIST = { "apex-in" };
- private static final String DEFAULT_KEY_SERIALIZER = "org.apache.superDooper.common.serialization.StringSerializer";
- private static final String DEFAULT_VALUE_SERIALIZER = "org.apache.superDooper.common.serialization.StringSerializer";
- private static final String DEFAULT_KEY_DESERIALIZER = "org.apache.superDooper.common.serialization.StringDeserializer";
- private static final String DEFAULT_VALUE_DESERIALIZER = "org.apache.superDooper.common.serialization.StringDeserializer";
+ private static final String[] DEFAULT_CONSUMER_TOPIC_LIST =
+ { "apex-in" };
+ private static final String DEFAULT_KEYSERZER = "org.apache.superDooper.common.serialization.StringSerializer";
+ private static final String DEFAULT_VALSERZER = "org.apache.superDooper.common.serialization.StringSerializer";
+ private static final String DEFAULT_KEYDESZER = "org.apache.superDooper.common.serialization.StringDeserializer";
+ private static final String DEFAULT_VALDESZER = "org.apache.superDooper.common.serialization.StringDeserializer";
// Parameter property map tokens
private static final String PROPERTY_BOOTSTRAP_SERVERS = "bootstrap.servers";
@@ -83,10 +84,10 @@ public class SuperDooperCarrierTechnologyParameters extends CarrierTechnologyPar
private String producerTopic = DEFAULT_PRODUCER_TOPIC;
private int consumerPollTime = DEFAULT_CONSUMER_POLL_TIME;
private String[] consumerTopicList = DEFAULT_CONSUMER_TOPIC_LIST;
- private String keySerializer = DEFAULT_KEY_SERIALIZER;
- private String valueSerializer = DEFAULT_VALUE_SERIALIZER;
- private String keyDeserializer = DEFAULT_KEY_DESERIALIZER;
- private String valueDeserializer = DEFAULT_VALUE_DESERIALIZER;
+ private String keySerializer = DEFAULT_KEYSERZER;
+ private String valueSerializer = DEFAULT_VALSERZER;
+ private String keyDeserializer = DEFAULT_KEYDESZER;
+ private String valueDeserializer = DEFAULT_VALDESZER;
/**
* Constructor to create a file carrier technology parameters instance and register the instance with the parameter
@@ -478,19 +479,23 @@ public class SuperDooperCarrierTechnologyParameters extends CarrierTechnologyPar
}
if (retries < 0) {
- result.setResult("retries", ValidationStatus.INVALID, "[" + retries + "] invalid, must be specified as retries >= 0");
+ result.setResult("retries", ValidationStatus.INVALID,
+ "[" + retries + "] invalid, must be specified as retries >= 0");
}
if (batchSize < 0) {
- result.setResult("batchSize", ValidationStatus.INVALID, "[" + batchSize + "] invalid, must be specified as batchSize >= 0");
+ result.setResult("batchSize", ValidationStatus.INVALID,
+ "[" + batchSize + "] invalid, must be specified as batchSize >= 0");
}
if (lingerTime < 0) {
- result.setResult("lingerTime", ValidationStatus.INVALID, "[" + lingerTime + "] invalid, must be specified as lingerTime >= 0");
+ result.setResult("lingerTime", ValidationStatus.INVALID,
+ "[" + lingerTime + "] invalid, must be specified as lingerTime >= 0");
}
if (bufferMemory < 0) {
- result.setResult("bufferMemory", ValidationStatus.INVALID, "[" + bufferMemory + "] invalid, must be specified as bufferMemory >= 0");
+ result.setResult("bufferMemory", ValidationStatus.INVALID,
+ "[" + bufferMemory + "] invalid, must be specified as bufferMemory >= 0");
}
if (groupId == null || groupId.trim().length() == 0) {
@@ -498,8 +503,8 @@ public class SuperDooperCarrierTechnologyParameters extends CarrierTechnologyPar
}
if (autoCommitTime < 0) {
- result.setResult("autoCommitTime", ValidationStatus.INVALID, "[" + autoCommitTime
- + "] invalid, must be specified as autoCommitTime >= 0");
+ result.setResult("autoCommitTime", ValidationStatus.INVALID,
+ "[" + autoCommitTime + "] invalid, must be specified as autoCommitTime >= 0");
}
if (sessionTimeout < 0) {
@@ -508,16 +513,18 @@ public class SuperDooperCarrierTechnologyParameters extends CarrierTechnologyPar
}
if (producerTopic == null || producerTopic.trim().length() == 0) {
- result.setResult("producerTopic", ValidationStatus.INVALID, "producerTopic not specified, must be specified as a string");
+ result.setResult("producerTopic", ValidationStatus.INVALID,
+ "producerTopic not specified, must be specified as a string");
}
if (consumerPollTime < 0) {
- result.setResult("consumerPollTime", ValidationStatus.INVALID, "[" + consumerPollTime
- + "] invalid, must be specified as consumerPollTime >= 0");
+ result.setResult("consumerPollTime", ValidationStatus.INVALID,
+ "[" + consumerPollTime + "] invalid, must be specified as consumerPollTime >= 0");
}
if (consumerTopicList == null || consumerTopicList.length == 0) {
- result.setResult("consumerTopicList", ValidationStatus.INVALID, "not specified, must be specified as a list of strings");
+ result.setResult("consumerTopicList", ValidationStatus.INVALID,
+ "not specified, must be specified as a list of strings");
}
StringBuilder consumerTopicMessageBuilder = new StringBuilder();
@@ -527,7 +534,7 @@ public class SuperDooperCarrierTechnologyParameters extends CarrierTechnologyPar
+ "\" specified on consumerTopicList, consumer topics must be specified as strings");
}
}
-
+
if (consumerTopicMessageBuilder.length() > 0) {
result.setResult("consumerTopicList", ValidationStatus.INVALID, consumerTopicMessageBuilder.toString());
}
@@ -537,11 +544,13 @@ public class SuperDooperCarrierTechnologyParameters extends CarrierTechnologyPar
}
if (valueSerializer == null || valueSerializer.trim().length() == 0) {
- result.setResult("valueSerializer", ValidationStatus.INVALID, "not specified, must be specified as a string");
+ result.setResult("valueSerializer", ValidationStatus.INVALID,
+ "not specified, must be specified as a string");
}
if (keyDeserializer == null || keyDeserializer.trim().length() == 0) {
- result.setResult("keyDeserializer", ValidationStatus.INVALID, "not specified, must be specified as a string");
+ result.setResult("keyDeserializer", ValidationStatus.INVALID,
+ "not specified, must be specified as a string");
}
if (valueDeserializer == null || valueDeserializer.trim().length() == 0) {
diff --git a/services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters/dummyclasses/SuperDooperDistributorParameters.java b/services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters/dummyclasses/SuperDooperDistributorParameters.java
index a8d099654..0d021c919 100644
--- a/services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters/dummyclasses/SuperDooperDistributorParameters.java
+++ b/services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters/dummyclasses/SuperDooperDistributorParameters.java
@@ -74,8 +74,8 @@ public class SuperDooperDistributorParameters extends DistributorParameters {
return jgroupsBindAddress;
}
- public void setjGroupsBindAddress(final String jGroupsBindAddress) {
- this.jgroupsBindAddress = jGroupsBindAddress;
+ public void setjGroupsBindAddress(final String jgroupsBindAddress) {
+ this.jgroupsBindAddress = jgroupsBindAddress;
}
@Override
diff --git a/services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters/dummyclasses/SuperTokenDelimitedEventProtocolParameters.java b/services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters/dummyclasses/SuperTokenDelimitedEventProtocolParameters.java
index ec4f97d78..7ae403726 100644
--- a/services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters/dummyclasses/SuperTokenDelimitedEventProtocolParameters.java
+++ b/services/services-engine/src/test/java/org/onap/policy/apex/service/engine/parameters/dummyclasses/SuperTokenDelimitedEventProtocolParameters.java
@@ -20,7 +20,7 @@
package org.onap.policy.apex.service.engine.parameters.dummyclasses;
-import org.onap.policy.apex.service.engine.event.impl.jsonprotocolplugin.JSONEventProtocolParameters;
+import org.onap.policy.apex.service.engine.event.impl.jsonprotocolplugin.JsonEventProtocolParameters;
import org.onap.policy.apex.service.parameters.eventprotocol.EventProtocolTextTokenDelimitedParameters;
/**
@@ -38,7 +38,7 @@ public class SuperTokenDelimitedEventProtocolParameters extends EventProtocolTex
* the parameter service.
*/
public SuperTokenDelimitedEventProtocolParameters() {
- super(JSONEventProtocolParameters.class.getCanonicalName());
+ super(JsonEventProtocolParameters.class.getCanonicalName());
// Set the event protocol properties for the JSON carrier technology
this.setLabel(SUPER_TOKEN_EVENT_PROTOCOL_LABEL);