diff options
author | rameshiyer27 <ramesh.murugan.iyer@est.tech> | 2024-01-21 14:24:03 +0000 |
---|---|---|
committer | rameshiyer27 <ramesh.murugan.iyer@est.tech> | 2024-01-22 14:55:45 +0000 |
commit | 31c61d495474985b8cc3460464f888651d0919ed (patch) | |
tree | 72ac562f9bd64196fda57edd8ca6a62f8877b046 /csit/resources/tests/data | |
parent | caa7adc30ed054d2a5cfea4a1b9a265d5cfb6785 (diff) |
Add kafka support in K8s CSIT
Issue-ID: POLICY-4402
Signed-off-by: zrrmmua <ramesh.murugan.iyer@est.tech>
Change-Id: I29ef966ed5eb70997574269ff6180f68d754383b
Diffstat (limited to 'csit/resources/tests/data')
-rw-r--r-- | csit/resources/tests/data/AcK8s.json | 6 | ||||
-rw-r--r-- | csit/resources/tests/data/acelement-usecase.yaml | 45 |
2 files changed, 35 insertions, 16 deletions
diff --git a/csit/resources/tests/data/AcK8s.json b/csit/resources/tests/data/AcK8s.json index f9ef5b0c..3a7e3a33 100644 --- a/csit/resources/tests/data/AcK8s.json +++ b/csit/resources/tests/data/AcK8s.json @@ -129,7 +129,7 @@ }, "httpMethod": "POST", "path": "/onap/policy/clamp/acelement/v2/activate", - "body": "{ \"receiverId\": { \"name\": \"onap.policy.clamp.ac.startertobridge\", \"version\": \"1.0.0\" }, \"timerMs\": 20000, \"elementType\": \"STARTER\", \"topicParameterGroup\": { \"server\": \"message-router:3904\", \"listenerTopic\": \"POLICY_UPDATE_MSG\", \"publisherTopic\": \"AC_ELEMENT_MSG\", \"fetchTimeout\": 15000, \"topicCommInfrastructure\": \"dmaap\" } }", + "body": "{ \"receiverId\": { \"name\": \"onap.policy.clamp.ac.startertobridge\", \"version\": \"1.0.0\" }, \"timerMs\": 20000, \"elementType\": \"STARTER\", \"topicParameterGroup\": { \"server\": \"kafka:9092\", \"listenerTopic\": \"policy_update_msg\", \"publisherTopic\": \"ac_element_msg\", \"fetchTimeout\": 15000, \"topicCommInfrastructure\": \"kafka\" } }", "expectedResponse": 201 } ] @@ -164,7 +164,7 @@ }, "httpMethod": "POST", "path": "/onap/policy/clamp/acelement/v2/activate", - "body": "{ \"receiverId\": { \"name\": \"onap.policy.clamp.ac.bridgetosink\", \"version\": \"1.0.0\" }, \"timerMs\": 20000, \"elementType\": \"BRIDGE\", \"topicParameterGroup\": { \"server\": \"message-router:3904\", \"listenerTopic\": \"POLICY_UPDATE_MSG\", \"publisherTopic\": \"AC_ELEMENT_MSG\", \"fetchTimeout\": 15000, \"topicCommInfrastructure\": \"dmaap\" } }", + "body": "{ \"receiverId\": { \"name\": \"onap.policy.clamp.ac.bridgetosink\", \"version\": \"1.0.0\" }, \"timerMs\": 20000, \"elementType\": \"BRIDGE\", \"topicParameterGroup\": { \"server\": \"kafka:9092\", \"listenerTopic\": \"policy_update_msg\", \"publisherTopic\": \"ac_element_msg\", \"fetchTimeout\": 15000, \"topicCommInfrastructure\": \"kafka\" } }", "expectedResponse": 201 } ] @@ -199,7 +199,7 @@ }, "httpMethod": "POST", "path": "/onap/policy/clamp/acelement/v2/activate", - "body": "{ \"receiverId\": { \"name\": \"onap.policy.clamp.ac.sink\", \"version\": \"1.0.0\" }, \"timerMs\": 20000, \"elementType\": \"SINK\", \"topicParameterGroup\": { \"server\": \"message-router\", \"listenerTopic\": \"POLICY_UPDATE_MSG\", \"publisherTopic\": \"AC_ELEMENT_MSG\", \"fetchTimeout\": 15000, \"topicCommInfrastructure\": \"dmaap\" } }", + "body": "{ \"receiverId\": { \"name\": \"onap.policy.clamp.ac.sink\", \"version\": \"1.0.0\" }, \"timerMs\": 20000, \"elementType\": \"SINK\", \"topicParameterGroup\": { \"server\": \"kafka:9092\", \"listenerTopic\": \"policy_update_msg\", \"publisherTopic\": \"ac_element_msg\", \"fetchTimeout\": 15000, \"topicCommInfrastructure\": \"kafka\" } }", "expectedResponse": 201 } ] diff --git a/csit/resources/tests/data/acelement-usecase.yaml b/csit/resources/tests/data/acelement-usecase.yaml index 94deb943..937ed6e6 100644 --- a/csit/resources/tests/data/acelement-usecase.yaml +++ b/csit/resources/tests/data/acelement-usecase.yaml @@ -1084,14 +1084,24 @@ topology_template: eventInputParameters: DmaapConsumer: carrierTechnologyParameters: - carrierTechnology: RESTCLIENT - parameterClassName: org.onap.policy.apex.plugins.event.carrier.restclient.RestClientCarrierTechnologyParameters + carrierTechnology: KAFKA + parameterClassName: org.onap.policy.apex.plugins.event.carrier.kafka.KafkaCarrierTechnologyParameters parameters: - url: http://message-router:3904/events/AC_ELEMENT_MSG/APEX/1?timeout=30000 + bootstrapServers: kafka:9092 + groupId: clamp-grp + enableAutoCommit: true + autoCommitTime: 1000 + sessionTimeout: 30000 + consumerPollTime: 100 + consumerTopicList: + - ac_element_msg + keyDeserializer: org.apache.kafka.common.serialization.StringDeserializer + valueDeserializer: org.apache.kafka.common.serialization.StringDeserializer + kafkaProperties: [ ] eventProtocolParameters: - eventProtocol: JSON - parameters: - pojoField: DmaapResponseEvent + eventProtocol: JSON + parameters: + pojoField: DmaapResponseEvent eventName: AcElementEvent eventNameFilter: AcElementEvent eventOutputParameters: @@ -1104,14 +1114,23 @@ topology_template: eventProtocol: JSON DmaapReplyProducer: carrierTechnologyParameters: - carrierTechnology: RESTCLIENT - parameterClassName: org.onap.policy.apex.plugins.event.carrier.restclient.RestClientCarrierTechnologyParameters + carrierTechnology: KAFKA + parameterClassName: org.onap.policy.apex.plugins.event.carrier.kafka.KafkaCarrierTechnologyParameters parameters: - url: http://message-router:3904/events/POLICY_UPDATE_MSG + bootstrapServers: kafka:9092 + acks: all + retries: 0 + batchSize: 16384 + lingerTime: 1 + bufferMemory: 33554432 + producerTopic: policy_update_msg + keySerializer: org.apache.kafka.common.serialization.StringSerializer + valueSerializer: org.apache.kafka.common.serialization.StringSerializer + kafkaProperties: [ ] eventProtocolParameters: - eventProtocol: JSON - parameters: - pojoField: DmaapResponseStatusEvent - eventNameFilter: (LogEvent|DmaapResponseStatusEvent) + eventProtocol: JSON + parameters: + pojoField: DmaapResponseStatusEvent + eventNameFilter: LogEvent|DmaapResponseStatusEvent name: onap.policies.native.apex.ac.element version: 1.0.0 |