Fix: Der Rebalance-Listener wurde nie registriertgit diff
authorKai Moritz <kai@juplo.de>
Mon, 28 Oct 2024 09:50:00 +0000 (10:50 +0100)
committerKai Moritz <kai@juplo.de>
Sun, 10 Nov 2024 13:27:08 +0000 (14:27 +0100)
src/main/java/de/juplo/kafka/ExampleConsumer.java

index 8226f9f..3acaebe 100644 (file)
@@ -73,7 +73,7 @@ public class ExampleConsumer implements Runnable, ConsumerRebalanceListener
       done = new boolean[numPartitions];
 
       log.info("{} - Subscribing to topic {}", id, topic);
-      consumer.subscribe(Arrays.asList(topic));
+      consumer.subscribe(Arrays.asList(topic), this);
       running = true;
 
       while (running)