summaryrefslogtreecommitdiffstats
path: root/models
diff options
context:
space:
mode:
authorSirisha_Manchikanti <sirisha.manchikanti@est.tech>2021-07-21 17:25:13 +0100
committerSirisha_Manchikanti <sirisha.manchikanti@est.tech>2021-07-23 14:32:27 +0100
commit395f61064ab29a9506a18bae505ebf1da3315e94 (patch)
tree40f1d47a68a739bd06ee073bf59559243f03e4c4 /models
parent4f3d63e2a88aa7253113aac0dac1f5041b9fc9ff (diff)
Rename ParticipantControlLoopStateChange message
This commit has no logical changes considered, except renaming ParticipantControlLoopStateChange message to ControlLoopStateChange message. According to following wiki ParticipantControlLoopStateChange message is renamed to ControlLoopStateChange message. https://wiki.onap.org/display/DW/The+CLAMP+Control+Loop+Participant+Protocol Issue-ID: POLICY-3417 Signed-off-by: Sirisha_Manchikanti <sirisha.manchikanti@est.tech> Change-Id: I7eaf89ca3fe5ab685b222b604abfd99627776b18
Diffstat (limited to 'models')
-rw-r--r--models/src/main/java/org/onap/policy/clamp/controlloop/models/messages/dmaap/participant/ControlLoopStateChange.java (renamed from models/src/main/java/org/onap/policy/clamp/controlloop/models/messages/dmaap/participant/ParticipantControlLoopStateChange.java)12
-rw-r--r--models/src/main/java/org/onap/policy/clamp/controlloop/models/messages/dmaap/participant/ControlLoopUpdate.java2
-rw-r--r--models/src/main/java/org/onap/policy/clamp/controlloop/models/messages/dmaap/participant/ParticipantMessageType.java4
-rw-r--r--models/src/test/java/org/onap/policy/clamp/controlloop/models/messages/dmaap/participant/ControlLoopStateChangeTest.java (renamed from models/src/test/java/org/onap/policy/clamp/controlloop/models/messages/dmaap/participant/ParticipantControlLoopStateChangeTest.java)10
4 files changed, 14 insertions, 14 deletions
diff --git a/models/src/main/java/org/onap/policy/clamp/controlloop/models/messages/dmaap/participant/ParticipantControlLoopStateChange.java b/models/src/main/java/org/onap/policy/clamp/controlloop/models/messages/dmaap/participant/ControlLoopStateChange.java
index 1a9a891f6..180d99439 100644
--- a/models/src/main/java/org/onap/policy/clamp/controlloop/models/messages/dmaap/participant/ParticipantControlLoopStateChange.java
+++ b/models/src/main/java/org/onap/policy/clamp/controlloop/models/messages/dmaap/participant/ControlLoopStateChange.java
@@ -26,21 +26,21 @@ import lombok.ToString;
import org.onap.policy.clamp.controlloop.models.controlloop.concepts.ControlLoopOrderedState;
/**
- * Class to represent the PARTICIPANT_CONTROL_LOOP_STATE_CHANGE message that the control loop runtime will send to
+ * Class to represent the CONTROL_LOOP_STATE_CHANGE message that the control loop runtime will send to
* participants to change the state of a control loop they are running.
*/
@Getter
@Setter
@ToString(callSuper = true)
-public class ParticipantControlLoopStateChange extends ParticipantMessage {
+public class ControlLoopStateChange extends ParticipantMessage {
private ControlLoopOrderedState orderedState;
/**
- * Constructor for instantiating ParticipantControlLoopStateChange class with message name.
+ * Constructor for instantiating ControlLoopStateChange class with message name.
*
*/
- public ParticipantControlLoopStateChange() {
- super(ParticipantMessageType.PARTICIPANT_CONTROL_LOOP_STATE_CHANGE);
+ public ControlLoopStateChange() {
+ super(ParticipantMessageType.CONTROL_LOOP_STATE_CHANGE);
}
/**
@@ -48,7 +48,7 @@ public class ParticipantControlLoopStateChange extends ParticipantMessage {
*
* @param source source from which to copy
*/
- public ParticipantControlLoopStateChange(ParticipantControlLoopStateChange source) {
+ public ControlLoopStateChange(ControlLoopStateChange source) {
super(source);
this.orderedState = source.orderedState;
diff --git a/models/src/main/java/org/onap/policy/clamp/controlloop/models/messages/dmaap/participant/ControlLoopUpdate.java b/models/src/main/java/org/onap/policy/clamp/controlloop/models/messages/dmaap/participant/ControlLoopUpdate.java
index f73adf928..876c370b4 100644
--- a/models/src/main/java/org/onap/policy/clamp/controlloop/models/messages/dmaap/participant/ControlLoopUpdate.java
+++ b/models/src/main/java/org/onap/policy/clamp/controlloop/models/messages/dmaap/participant/ControlLoopUpdate.java
@@ -29,7 +29,7 @@ import org.onap.policy.models.tosca.authorative.concepts.ToscaServiceTemplate;
/**
* Class to represent the CONTROL_LOOP_UPDATE message that the control loop runtime sends to a participant.
* When a participant receives this message, it creates the control loop elements contained in the message and sets them
- * to state PASSIVE. subsequent PARTICIPANT_CONTROL_LOOP_STATE_CHANGE messages are used to activate the control loops.
+ * to state PASSIVE. subsequent CONTROL_LOOP_STATE_CHANGE messages are used to activate the control loops.
*/
@Getter
@Setter
diff --git a/models/src/main/java/org/onap/policy/clamp/controlloop/models/messages/dmaap/participant/ParticipantMessageType.java b/models/src/main/java/org/onap/policy/clamp/controlloop/models/messages/dmaap/participant/ParticipantMessageType.java
index 22f5a1793..0c39392e0 100644
--- a/models/src/main/java/org/onap/policy/clamp/controlloop/models/messages/dmaap/participant/ParticipantMessageType.java
+++ b/models/src/main/java/org/onap/policy/clamp/controlloop/models/messages/dmaap/participant/ParticipantMessageType.java
@@ -44,9 +44,9 @@ public enum ParticipantMessageType {
/**
* Used by controlloop runtime to change the state of controlloops in participants, triggers a
- * PARTICIPANT_STATUS message with result of PARTICIPANT_CONTROL_LOOP_STATE_CHANGE operation.
+ * PARTICIPANT_STATUS message with result of CONTROL_LOOP_STATE_CHANGE operation.
*/
- PARTICIPANT_CONTROL_LOOP_STATE_CHANGE,
+ CONTROL_LOOP_STATE_CHANGE,
/**
* Used by the control loop runtime to order a health check on participants, triggers a
diff --git a/models/src/test/java/org/onap/policy/clamp/controlloop/models/messages/dmaap/participant/ParticipantControlLoopStateChangeTest.java b/models/src/test/java/org/onap/policy/clamp/controlloop/models/messages/dmaap/participant/ControlLoopStateChangeTest.java
index 789da1e64..5b7fda0c4 100644
--- a/models/src/test/java/org/onap/policy/clamp/controlloop/models/messages/dmaap/participant/ParticipantControlLoopStateChangeTest.java
+++ b/models/src/test/java/org/onap/policy/clamp/controlloop/models/messages/dmaap/participant/ControlLoopStateChangeTest.java
@@ -33,17 +33,17 @@ import org.onap.policy.models.tosca.authorative.concepts.ToscaConceptIdentifier;
/**
* Test the copy constructor and other methods.
*/
-class ParticipantControlLoopStateChangeTest {
+class ControlLoopStateChangeTest {
@Test
void testCopyConstructor() {
- assertThatThrownBy(() -> new ParticipantControlLoopStateChange(null)).isInstanceOf(NullPointerException.class);
+ assertThatThrownBy(() -> new ControlLoopStateChange(null)).isInstanceOf(NullPointerException.class);
- ParticipantControlLoopStateChange orig = new ParticipantControlLoopStateChange();
+ ControlLoopStateChange orig = new ControlLoopStateChange();
// verify with null values
assertEquals(removeVariableFields(orig.toString()),
- removeVariableFields(new ParticipantControlLoopStateChange(orig).toString()));
+ removeVariableFields(new ControlLoopStateChange(orig).toString()));
// verify with all values
ToscaConceptIdentifier id = new ToscaConceptIdentifier();
@@ -56,6 +56,6 @@ class ParticipantControlLoopStateChangeTest {
orig.setTimestamp(Instant.ofEpochMilli(3000));
assertEquals(removeVariableFields(orig.toString()),
- removeVariableFields(new ParticipantControlLoopStateChange(orig).toString()));
+ removeVariableFields(new ControlLoopStateChange(orig).toString()));
}
}