aboutsummaryrefslogtreecommitdiffstats
path: root/participant/participant-intermediary/src/main
diff options
context:
space:
mode:
authorJim Hahn <jrh3@att.com>2021-09-02 14:28:06 +0000
committerGerrit Code Review <gerrit@onap.org>2021-09-02 14:28:06 +0000
commitadb8255b9706e09127d77bc072bef4e8b3a27cf1 (patch)
tree418b8507a1a30baa3b8167b4a0a2ca1d90df2683 /participant/participant-intermediary/src/main
parent83b5318e545fbc72e3612c4300c4d738b0b577de (diff)
parent466783f7638c9173f08a63d51af2c799c0a63598 (diff)
Merge "Verify alignment with Definition of TOSCA Control Loop Types"
Diffstat (limited to 'participant/participant-intermediary/src/main')
-rw-r--r--participant/participant-intermediary/src/main/java/org/onap/policy/clamp/controlloop/participant/intermediary/handler/ParticipantHandler.java7
1 files changed, 3 insertions, 4 deletions
diff --git a/participant/participant-intermediary/src/main/java/org/onap/policy/clamp/controlloop/participant/intermediary/handler/ParticipantHandler.java b/participant/participant-intermediary/src/main/java/org/onap/policy/clamp/controlloop/participant/intermediary/handler/ParticipantHandler.java
index 56fddd6ff..072a2ebc1 100644
--- a/participant/participant-intermediary/src/main/java/org/onap/policy/clamp/controlloop/participant/intermediary/handler/ParticipantHandler.java
+++ b/participant/participant-intermediary/src/main/java/org/onap/policy/clamp/controlloop/participant/intermediary/handler/ParticipantHandler.java
@@ -292,7 +292,7 @@ public class ParticipantHandler {
if (!participantUpdateMsg.getParticipantDefinitionUpdates().isEmpty()) {
// This message is to commission the controlloop
for (ParticipantDefinition participantDefinition : participantUpdateMsg.getParticipantDefinitionUpdates()) {
- if (participantDefinition.getParticipantId().equals(participantType)) {
+ if (participantDefinition.getParticipantType().equals(participantType)) {
clElementDefsOnThisParticipant.clear();
clElementDefsOnThisParticipant.addAll(participantDefinition.getControlLoopElementDefinitionList());
break;
@@ -343,12 +343,11 @@ public class ParticipantHandler {
heartbeat.setControlLoopInfoList(getControlLoopInfoList());
if (responseToParticipantStatusReq) {
- List<ParticipantDefinition> participantDefinitionUpdates = new ArrayList<>();
ParticipantDefinition participantDefinition = new ParticipantDefinition();
participantDefinition.setParticipantId(participantId);
+ participantDefinition.setParticipantType(participantType);
participantDefinition.setControlLoopElementDefinitionList(clElementDefsOnThisParticipant);
- participantDefinitionUpdates.add(participantDefinition);
- heartbeat.setParticipantDefinitionUpdates(participantDefinitionUpdates);
+ heartbeat.setParticipantDefinitionUpdates(List.of(participantDefinition));
}
return heartbeat;