From 14d6bfebdd4a8873084e4f1fcbdeb6453fdd4bca Mon Sep 17 00:00:00 2001 From: rameshiyer27 Date: Mon, 22 Jan 2024 18:54:28 +0000 Subject: Remove Dmaap references from CLAMP Issue-ID:POLICY-4881 Signed-off-by: zrrmmua Change-Id: Id305f7538ebc9822f121a868126e188d426c18f6 --- .../intermediary/comm/ParticipantCommTest.java | 18 ++++++------ .../handler/AutomationCompositionHandlerTest.java | 13 ++++----- .../AutomationCompositionOutHandlerTest.java | 8 +++--- .../handler/IntermediaryActivatorTest.java | 4 +-- .../handler/ParticipantHandlerTest.java | 32 +++++++++++----------- .../main/parameters/CommonTestData.java | 6 ++-- 6 files changed, 40 insertions(+), 41 deletions(-) (limited to 'participant/participant-intermediary/src/test/java') diff --git a/participant/participant-intermediary/src/test/java/org/onap/policy/clamp/acm/participant/intermediary/comm/ParticipantCommTest.java b/participant/participant-intermediary/src/test/java/org/onap/policy/clamp/acm/participant/intermediary/comm/ParticipantCommTest.java index de948209f..754fc6522 100755 --- a/participant/participant-intermediary/src/test/java/org/onap/policy/clamp/acm/participant/intermediary/comm/ParticipantCommTest.java +++ b/participant/participant-intermediary/src/test/java/org/onap/policy/clamp/acm/participant/intermediary/comm/ParticipantCommTest.java @@ -1,6 +1,6 @@ /*- * ============LICENSE_START======================================================= - * Copyright (C) 2021-2023 Nordix Foundation. + * Copyright (C) 2021-2024 Nordix Foundation. * ================================================================================ * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -33,14 +33,14 @@ import org.mockito.Mockito; import org.onap.policy.clamp.acm.participant.intermediary.handler.ParticipantHandler; import org.onap.policy.clamp.acm.participant.intermediary.main.parameters.CommonTestData; import org.onap.policy.clamp.common.acm.exception.AutomationCompositionRuntimeException; -import org.onap.policy.clamp.models.acm.messages.dmaap.participant.AutomationCompositionDeployAck; -import org.onap.policy.clamp.models.acm.messages.dmaap.participant.ParticipantDeregister; -import org.onap.policy.clamp.models.acm.messages.dmaap.participant.ParticipantMessageType; -import org.onap.policy.clamp.models.acm.messages.dmaap.participant.ParticipantPrimeAck; -import org.onap.policy.clamp.models.acm.messages.dmaap.participant.ParticipantRegister; -import org.onap.policy.clamp.models.acm.messages.dmaap.participant.ParticipantRegisterAck; -import org.onap.policy.clamp.models.acm.messages.dmaap.participant.ParticipantStatus; -import org.onap.policy.clamp.models.acm.messages.dmaap.participant.ParticipantStatusReq; +import org.onap.policy.clamp.models.acm.messages.kafka.participant.AutomationCompositionDeployAck; +import org.onap.policy.clamp.models.acm.messages.kafka.participant.ParticipantDeregister; +import org.onap.policy.clamp.models.acm.messages.kafka.participant.ParticipantMessageType; +import org.onap.policy.clamp.models.acm.messages.kafka.participant.ParticipantPrimeAck; +import org.onap.policy.clamp.models.acm.messages.kafka.participant.ParticipantRegister; +import org.onap.policy.clamp.models.acm.messages.kafka.participant.ParticipantRegisterAck; +import org.onap.policy.clamp.models.acm.messages.kafka.participant.ParticipantStatus; +import org.onap.policy.clamp.models.acm.messages.kafka.participant.ParticipantStatusReq; import org.onap.policy.common.endpoints.event.comm.TopicSink; import org.onap.policy.common.utils.coder.CoderException; diff --git a/participant/participant-intermediary/src/test/java/org/onap/policy/clamp/acm/participant/intermediary/handler/AutomationCompositionHandlerTest.java b/participant/participant-intermediary/src/test/java/org/onap/policy/clamp/acm/participant/intermediary/handler/AutomationCompositionHandlerTest.java index 5f7d71e6f..6a00d8cf6 100755 --- a/participant/participant-intermediary/src/test/java/org/onap/policy/clamp/acm/participant/intermediary/handler/AutomationCompositionHandlerTest.java +++ b/participant/participant-intermediary/src/test/java/org/onap/policy/clamp/acm/participant/intermediary/handler/AutomationCompositionHandlerTest.java @@ -1,6 +1,6 @@ /*- * ============LICENSE_START======================================================= - * Copyright (C) 2021-2023 Nordix Foundation. + * Copyright (C) 2021-2024 Nordix Foundation. * ================================================================================ * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -23,7 +23,6 @@ package org.onap.policy.clamp.acm.participant.intermediary.handler; import static org.junit.jupiter.api.Assertions.assertDoesNotThrow; import static org.junit.jupiter.api.Assertions.assertEquals; import static org.mockito.ArgumentMatchers.any; -import static org.mockito.ArgumentMatchers.anyBoolean; import static org.mockito.Mockito.mock; import static org.mockito.Mockito.times; import static org.mockito.Mockito.verify; @@ -42,11 +41,11 @@ import org.onap.policy.clamp.models.acm.concepts.AutomationCompositionElementDef import org.onap.policy.clamp.models.acm.concepts.DeployState; import org.onap.policy.clamp.models.acm.concepts.LockState; import org.onap.policy.clamp.models.acm.concepts.ParticipantDeploy; -import org.onap.policy.clamp.models.acm.messages.dmaap.participant.AutomationCompositionDeploy; -import org.onap.policy.clamp.models.acm.messages.dmaap.participant.AutomationCompositionDeployAck; -import org.onap.policy.clamp.models.acm.messages.dmaap.participant.AutomationCompositionMigration; -import org.onap.policy.clamp.models.acm.messages.dmaap.participant.AutomationCompositionStateChange; -import org.onap.policy.clamp.models.acm.messages.dmaap.participant.PropertiesUpdate; +import org.onap.policy.clamp.models.acm.messages.kafka.participant.AutomationCompositionDeploy; +import org.onap.policy.clamp.models.acm.messages.kafka.participant.AutomationCompositionDeployAck; +import org.onap.policy.clamp.models.acm.messages.kafka.participant.AutomationCompositionMigration; +import org.onap.policy.clamp.models.acm.messages.kafka.participant.AutomationCompositionStateChange; +import org.onap.policy.clamp.models.acm.messages.kafka.participant.PropertiesUpdate; import org.onap.policy.clamp.models.acm.messages.rest.instantiation.DeployOrder; import org.onap.policy.clamp.models.acm.messages.rest.instantiation.LockOrder; import org.springframework.test.context.junit.jupiter.SpringExtension; diff --git a/participant/participant-intermediary/src/test/java/org/onap/policy/clamp/acm/participant/intermediary/handler/AutomationCompositionOutHandlerTest.java b/participant/participant-intermediary/src/test/java/org/onap/policy/clamp/acm/participant/intermediary/handler/AutomationCompositionOutHandlerTest.java index a04f9079c..76fbd068f 100755 --- a/participant/participant-intermediary/src/test/java/org/onap/policy/clamp/acm/participant/intermediary/handler/AutomationCompositionOutHandlerTest.java +++ b/participant/participant-intermediary/src/test/java/org/onap/policy/clamp/acm/participant/intermediary/handler/AutomationCompositionOutHandlerTest.java @@ -1,6 +1,6 @@ /*- * ============LICENSE_START======================================================= - * Copyright (C) 2023 Nordix Foundation. + * Copyright (C) 2023-2024 Nordix Foundation. * ================================================================================ * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -39,9 +39,9 @@ import org.onap.policy.clamp.models.acm.concepts.AutomationCompositionElementDef import org.onap.policy.clamp.models.acm.concepts.DeployState; import org.onap.policy.clamp.models.acm.concepts.LockState; import org.onap.policy.clamp.models.acm.concepts.StateChangeResult; -import org.onap.policy.clamp.models.acm.messages.dmaap.participant.AutomationCompositionDeployAck; -import org.onap.policy.clamp.models.acm.messages.dmaap.participant.ParticipantPrimeAck; -import org.onap.policy.clamp.models.acm.messages.dmaap.participant.ParticipantStatus; +import org.onap.policy.clamp.models.acm.messages.kafka.participant.AutomationCompositionDeployAck; +import org.onap.policy.clamp.models.acm.messages.kafka.participant.ParticipantPrimeAck; +import org.onap.policy.clamp.models.acm.messages.kafka.participant.ParticipantStatus; import org.onap.policy.models.tosca.authorative.concepts.ToscaConceptIdentifier; class AutomationCompositionOutHandlerTest { diff --git a/participant/participant-intermediary/src/test/java/org/onap/policy/clamp/acm/participant/intermediary/handler/IntermediaryActivatorTest.java b/participant/participant-intermediary/src/test/java/org/onap/policy/clamp/acm/participant/intermediary/handler/IntermediaryActivatorTest.java index 559eda5f7..ac9cbfad7 100644 --- a/participant/participant-intermediary/src/test/java/org/onap/policy/clamp/acm/participant/intermediary/handler/IntermediaryActivatorTest.java +++ b/participant/participant-intermediary/src/test/java/org/onap/policy/clamp/acm/participant/intermediary/handler/IntermediaryActivatorTest.java @@ -1,6 +1,6 @@ /*- * ============LICENSE_START======================================================= - * Copyright (C) 2021-2023 Nordix Foundation. + * Copyright (C) 2021-2024 Nordix Foundation. * ================================================================================ * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -35,7 +35,7 @@ import java.util.List; import org.junit.jupiter.api.Test; import org.onap.policy.clamp.acm.participant.intermediary.comm.ParticipantStatusReqListener; import org.onap.policy.clamp.acm.participant.intermediary.main.parameters.CommonTestData; -import org.onap.policy.clamp.models.acm.messages.dmaap.participant.ParticipantStatusReq; +import org.onap.policy.clamp.models.acm.messages.kafka.participant.ParticipantStatusReq; import org.onap.policy.common.utils.coder.Coder; import org.onap.policy.common.utils.coder.StandardCoder; import org.onap.policy.common.utils.coder.StandardCoderObject; diff --git a/participant/participant-intermediary/src/test/java/org/onap/policy/clamp/acm/participant/intermediary/handler/ParticipantHandlerTest.java b/participant/participant-intermediary/src/test/java/org/onap/policy/clamp/acm/participant/intermediary/handler/ParticipantHandlerTest.java index 7a0b048ff..8be19f749 100755 --- a/participant/participant-intermediary/src/test/java/org/onap/policy/clamp/acm/participant/intermediary/handler/ParticipantHandlerTest.java +++ b/participant/participant-intermediary/src/test/java/org/onap/policy/clamp/acm/participant/intermediary/handler/ParticipantHandlerTest.java @@ -1,6 +1,6 @@ /*- * ============LICENSE_START======================================================= - * Copyright (C) 2021-2023 Nordix Foundation. + * Copyright (C) 2021-2024 Nordix Foundation. * ================================================================================ * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -36,21 +36,21 @@ import org.onap.policy.clamp.acm.participant.intermediary.main.parameters.Common import org.onap.policy.clamp.models.acm.concepts.AcTypeState; import org.onap.policy.clamp.models.acm.concepts.ParticipantDefinition; import org.onap.policy.clamp.models.acm.concepts.ParticipantSupportedElementType; -import org.onap.policy.clamp.models.acm.messages.dmaap.participant.AutomationCompositionDeploy; -import org.onap.policy.clamp.models.acm.messages.dmaap.participant.AutomationCompositionMigration; -import org.onap.policy.clamp.models.acm.messages.dmaap.participant.AutomationCompositionStateChange; -import org.onap.policy.clamp.models.acm.messages.dmaap.participant.ParticipantAckMessage; -import org.onap.policy.clamp.models.acm.messages.dmaap.participant.ParticipantDeregister; -import org.onap.policy.clamp.models.acm.messages.dmaap.participant.ParticipantDeregisterAck; -import org.onap.policy.clamp.models.acm.messages.dmaap.participant.ParticipantMessage; -import org.onap.policy.clamp.models.acm.messages.dmaap.participant.ParticipantMessageType; -import org.onap.policy.clamp.models.acm.messages.dmaap.participant.ParticipantPrime; -import org.onap.policy.clamp.models.acm.messages.dmaap.participant.ParticipantRegister; -import org.onap.policy.clamp.models.acm.messages.dmaap.participant.ParticipantRegisterAck; -import org.onap.policy.clamp.models.acm.messages.dmaap.participant.ParticipantRestart; -import org.onap.policy.clamp.models.acm.messages.dmaap.participant.ParticipantStatus; -import org.onap.policy.clamp.models.acm.messages.dmaap.participant.ParticipantStatusReq; -import org.onap.policy.clamp.models.acm.messages.dmaap.participant.PropertiesUpdate; +import org.onap.policy.clamp.models.acm.messages.kafka.participant.AutomationCompositionDeploy; +import org.onap.policy.clamp.models.acm.messages.kafka.participant.AutomationCompositionMigration; +import org.onap.policy.clamp.models.acm.messages.kafka.participant.AutomationCompositionStateChange; +import org.onap.policy.clamp.models.acm.messages.kafka.participant.ParticipantAckMessage; +import org.onap.policy.clamp.models.acm.messages.kafka.participant.ParticipantDeregister; +import org.onap.policy.clamp.models.acm.messages.kafka.participant.ParticipantDeregisterAck; +import org.onap.policy.clamp.models.acm.messages.kafka.participant.ParticipantMessage; +import org.onap.policy.clamp.models.acm.messages.kafka.participant.ParticipantMessageType; +import org.onap.policy.clamp.models.acm.messages.kafka.participant.ParticipantPrime; +import org.onap.policy.clamp.models.acm.messages.kafka.participant.ParticipantRegister; +import org.onap.policy.clamp.models.acm.messages.kafka.participant.ParticipantRegisterAck; +import org.onap.policy.clamp.models.acm.messages.kafka.participant.ParticipantRestart; +import org.onap.policy.clamp.models.acm.messages.kafka.participant.ParticipantStatus; +import org.onap.policy.clamp.models.acm.messages.kafka.participant.ParticipantStatusReq; +import org.onap.policy.clamp.models.acm.messages.kafka.participant.PropertiesUpdate; class ParticipantHandlerTest { diff --git a/participant/participant-intermediary/src/test/java/org/onap/policy/clamp/acm/participant/intermediary/main/parameters/CommonTestData.java b/participant/participant-intermediary/src/test/java/org/onap/policy/clamp/acm/participant/intermediary/main/parameters/CommonTestData.java index 4345d48c4..168bfaf83 100644 --- a/participant/participant-intermediary/src/test/java/org/onap/policy/clamp/acm/participant/intermediary/main/parameters/CommonTestData.java +++ b/participant/participant-intermediary/src/test/java/org/onap/policy/clamp/acm/participant/intermediary/main/parameters/CommonTestData.java @@ -40,7 +40,7 @@ import org.onap.policy.clamp.models.acm.concepts.LockState; import org.onap.policy.clamp.models.acm.concepts.ParticipantDeploy; import org.onap.policy.clamp.models.acm.concepts.ParticipantRestartAc; import org.onap.policy.clamp.models.acm.concepts.ParticipantSupportedElementType; -import org.onap.policy.clamp.models.acm.messages.dmaap.participant.AutomationCompositionStateChange; +import org.onap.policy.clamp.models.acm.messages.kafka.participant.AutomationCompositionStateChange; import org.onap.policy.clamp.models.acm.messages.rest.instantiation.DeployOrder; import org.onap.policy.clamp.models.acm.messages.rest.instantiation.LockOrder; import org.onap.policy.common.endpoints.parameters.TopicParameters; @@ -145,8 +145,8 @@ public class CommonTestData { */ public static TopicParameters getTopicParams() { final var topicParams = new TopicParameters(); - topicParams.setTopic("POLICY-ACRUNTIME-PARTICIPANT"); - topicParams.setTopicCommInfrastructure("dmaap"); + topicParams.setTopic("policy-acruntime-participant"); + topicParams.setTopicCommInfrastructure("NOOP"); topicParams.setServers(List.of("localhost")); return topicParams; } -- cgit 1.2.3-korg