From 89710c091780bdbc2d56b4e0dc5c32fc34719efc Mon Sep 17 00:00:00 2001 From: FrancescoFioraEst Date: Fri, 27 Aug 2021 10:33:52 +0100 Subject: Fix ControlLoopAck and remove circular dependency Issue-ID: CLAMP-1028 Change-Id: I23b6806bf9a22449c7709b619a20f3412e3e3742 Signed-off-by: FrancescoFioraEst --- .../concepts/ControlLoopElementAck.java | 40 ++++++++++++++++++++++ .../messages/dmaap/participant/ControlLoopAck.java | 4 +-- 2 files changed, 42 insertions(+), 2 deletions(-) create mode 100644 models/src/main/java/org/onap/policy/clamp/controlloop/models/controlloop/concepts/ControlLoopElementAck.java (limited to 'models/src/main') diff --git a/models/src/main/java/org/onap/policy/clamp/controlloop/models/controlloop/concepts/ControlLoopElementAck.java b/models/src/main/java/org/onap/policy/clamp/controlloop/models/controlloop/concepts/ControlLoopElementAck.java new file mode 100644 index 000000000..a5918fe94 --- /dev/null +++ b/models/src/main/java/org/onap/policy/clamp/controlloop/models/controlloop/concepts/ControlLoopElementAck.java @@ -0,0 +1,40 @@ +/*- + * ============LICENSE_START======================================================= + * Copyright (C) 2021 Nordix Foundation. + * ================================================================================ + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * + * SPDX-License-Identifier: Apache-2.0 + * ============LICENSE_END========================================================= + */ + +package org.onap.policy.clamp.controlloop.models.controlloop.concepts; + +import lombok.AllArgsConstructor; +import lombok.Getter; +import lombok.Setter; +import lombok.ToString; + +@Getter +@Setter +@AllArgsConstructor +@ToString +public class ControlLoopElementAck { + + // Result: Success/Fail. + private Boolean result; + + // Message indicating reason for failure + private String message; + +} diff --git a/models/src/main/java/org/onap/policy/clamp/controlloop/models/messages/dmaap/participant/ControlLoopAck.java b/models/src/main/java/org/onap/policy/clamp/controlloop/models/messages/dmaap/participant/ControlLoopAck.java index 55ba7faf5..8e3604916 100644 --- a/models/src/main/java/org/onap/policy/clamp/controlloop/models/messages/dmaap/participant/ControlLoopAck.java +++ b/models/src/main/java/org/onap/policy/clamp/controlloop/models/messages/dmaap/participant/ControlLoopAck.java @@ -27,7 +27,7 @@ import java.util.function.UnaryOperator; import lombok.Getter; import lombok.Setter; import lombok.ToString; -import org.apache.commons.lang3.tuple.Pair; +import org.onap.policy.clamp.controlloop.models.controlloop.concepts.ControlLoopElementAck; import org.onap.policy.models.base.PfUtils; import org.onap.policy.models.tosca.authorative.concepts.ToscaConceptIdentifier; @@ -45,7 +45,7 @@ public class ControlLoopAck extends ParticipantAckMessage { // A map with ControlLoopElementID as its key, and a pair of result and message as value per // ControlLoopElement. - private Map> controlLoopResultMap = new LinkedHashMap<>(); + private Map controlLoopResultMap = new LinkedHashMap<>(); /** * Constructor for instantiating ParticipantRegisterAck class with message name. -- cgit 1.2.3-korg