Skip to content

Commit a92d7c9

Browse files
committed
Justerte max poll records og poll timeout for key maintenance
1 parent a098d6b commit a92d7c9

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

apps/kafka-key-maintenance/src/main/kotlin/no/nav/paw/kafkakeymaintenance/InitPeriodeConsumer.kt

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -19,13 +19,14 @@ fun KafkaFactory.initPeriodeConsumer(
1919
keyDeserializer = LongDeserializer::class,
2020
valueDeserializer = PeriodeDeserializer::class,
2121
autoCommit = false,
22-
autoOffsetReset = "earliest"
22+
autoOffsetReset = "earliest",
23+
maxPollrecords = 1000
2324
)
2425
val reblancingListener = HwmRebalanceListener(applicationContext, periodeConsumer)
2526
periodeConsumer.subscribe(listOf(periodeTopic))
2627
return reblancingListener to periodeConsumer.asSequence(
2728
stop = applicationContext.shutdownCalled,
28-
pollTimeout = Duration.ofMillis(500),
29+
pollTimeout = Duration.ofMillis(1000),
2930
closeTimeout = Duration.ofSeconds(1)
3031
)
3132
}

0 commit comments

Comments
 (0)