From f72ff0cff34d17147a5142eb57987b1515b80580 Mon Sep 17 00:00:00 2001 From: Julien Fontaine Date: Tue, 4 Aug 2020 11:57:56 -0400 Subject: Make use of Kafka Key for Audit service and Kafka listener * When message is sent by audit service, key will be the CBA name * When sent by kafka listener (self-service api), key is the same as the request message key consumed. If not specified, a random UUID * MessageProducer interface refactoring : * add 'key' parameter to specify a key * add default value null to paramater 'headers' to remove some unnecessary method Issue-ID: CCSDK-2628 Signed-off-by: Julien Fontaine Change-Id: I68580151184c87104c07037f379276dd8c8c71c7 --- .../message/prioritization/MessagePrioritizationConsumerTest.kt | 3 +++ 1 file changed, 3 insertions(+) (limited to 'ms/blueprintsprocessor/functions/message-prioritizaion') diff --git a/ms/blueprintsprocessor/functions/message-prioritizaion/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/message/prioritization/MessagePrioritizationConsumerTest.kt b/ms/blueprintsprocessor/functions/message-prioritizaion/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/message/prioritization/MessagePrioritizationConsumerTest.kt index 7e6bf68be..af8d902cd 100644 --- a/ms/blueprintsprocessor/functions/message-prioritizaion/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/message/prioritization/MessagePrioritizationConsumerTest.kt +++ b/ms/blueprintsprocessor/functions/message-prioritizaion/src/test/kotlin/org/onap/ccsdk/cds/blueprintsprocessor/functions/message/prioritization/MessagePrioritizationConsumerTest.kt @@ -260,6 +260,7 @@ open class MessagePrioritizationConsumerTest { val headers: MutableMap = hashMapOf() headers["id"] = it.id blueprintMessageProducerService.sendMessageNB( + key = "mykey", message = it.asJsonString(false), headers = headers ) @@ -272,6 +273,7 @@ open class MessagePrioritizationConsumerTest { val headers: MutableMap = hashMapOf() headers["id"] = it.id blueprintMessageProducerService.sendMessageNB( + key = "mykey", message = it.asJsonString(false), headers = headers ) @@ -284,6 +286,7 @@ open class MessagePrioritizationConsumerTest { val headers: MutableMap = hashMapOf() headers["id"] = it.id blueprintMessageProducerService.sendMessageNB( + key = "mykey", message = it.asJsonString(false), headers = headers ) -- cgit 1.2.3-korg