diff --git a/hm-rapids-and-rivers-v2-micronaut/src/main/kotlin/no/nav/hm/rapids_rivers/micronaut/KafkaPushRapidService.kt b/hm-rapids-and-rivers-v2-micronaut/src/main/kotlin/no/nav/hm/rapids_rivers/micronaut/KafkaPushRapidService.kt index 984ae10..161e91b 100644 --- a/hm-rapids-and-rivers-v2-micronaut/src/main/kotlin/no/nav/hm/rapids_rivers/micronaut/KafkaPushRapidService.kt +++ b/hm-rapids-and-rivers-v2-micronaut/src/main/kotlin/no/nav/hm/rapids_rivers/micronaut/KafkaPushRapidService.kt @@ -19,9 +19,8 @@ class KafkaRapidService(private val kafkaRapid: KafkaRapid, } override fun pushToRapid(key: String?, eventName: String?, payload: T, - keyValues : Map) { - val eventId = UUID.randomUUID() - LOG.debug("push to rapid key: $key, eventId: $eventId, eventName: $eventName, " + + keyValues : Map, eventId: UUID) { + LOG.info("push to rapid with partition key: $key, eventId: $eventId, eventName: $eventName, " + "payloadType: ${payload::class.java.simpleName}") produceEvent(key, mapOf("eventId" to eventId, "eventName" to eventName, "createdTime" to LocalDateTime.now(), diff --git a/hm-rapids-and-rivers-v2-micronaut/src/main/kotlin/no/nav/hm/rapids_rivers/micronaut/RapidPushService.kt b/hm-rapids-and-rivers-v2-micronaut/src/main/kotlin/no/nav/hm/rapids_rivers/micronaut/RapidPushService.kt index 5846387..431413c 100644 --- a/hm-rapids-and-rivers-v2-micronaut/src/main/kotlin/no/nav/hm/rapids_rivers/micronaut/RapidPushService.kt +++ b/hm-rapids-and-rivers-v2-micronaut/src/main/kotlin/no/nav/hm/rapids_rivers/micronaut/RapidPushService.kt @@ -1,6 +1,8 @@ package no.nav.hm.rapids_rivers.micronaut +import java.util.UUID + interface RapidPushService { fun pushToRapid(key: String?=null, eventName: String?=null, payload: T, - keyValues : Map = emptyMap()) + keyValues : Map = emptyMap(), eventId: UUID = UUID.randomUUID()) } \ No newline at end of file