WIP:StringDeserializer
authorKai Moritz <kai@juplo.de>
Wed, 2 Nov 2022 17:55:37 +0000 (18:55 +0100)
committerKai Moritz <kai@juplo.de>
Fri, 4 Nov 2022 11:52:13 +0000 (12:52 +0100)
src/main/java/de/juplo/kafka/SimpleConsumer.java

index 49eca1a..d53f5e5 100644 (file)
@@ -19,7 +19,7 @@ public class SimpleConsumer implements Runnable
   private final ExecutorService executor;
   private final String id;
   private final String topic;
-  private final Consumer<String, Message> consumer;
+  private final Consumer<String, String> consumer;
 
   private long consumed = 0;
 
@@ -34,11 +34,11 @@ public class SimpleConsumer implements Runnable
 
       while (true)
       {
-        ConsumerRecords<String, Message> records =
+        ConsumerRecords<String, String> records =
             consumer.poll(Duration.ofSeconds(1));
 
         log.info("{} - Received {} messages", id, records.count());
-        for (ConsumerRecord<String, Message> record : records)
+        for (ConsumerRecord<String, String> record : records)
         {
           consumed++;
           log.info(