From: Kai Moritz Date: Fri, 18 Aug 2023 14:21:23 +0000 (+0200) Subject: NG X-Git-Tag: rebase--2023-08-18-abends~5 X-Git-Url: http://juplo.de/gitweb/?a=commitdiff_plain;h=9198979864e0ea9cda01878eb01e628d5628a448;p=demos%2Fkafka%2Fchat NG --- diff --git a/src/main/java/de/juplo/kafka/chat/backend/persistence/kafka/KafkaServicesConfiguration.java b/src/main/java/de/juplo/kafka/chat/backend/persistence/kafka/KafkaServicesConfiguration.java index 4ebed8df..4f6e918b 100644 --- a/src/main/java/de/juplo/kafka/chat/backend/persistence/kafka/KafkaServicesConfiguration.java +++ b/src/main/java/de/juplo/kafka/chat/backend/persistence/kafka/KafkaServicesConfiguration.java @@ -48,24 +48,6 @@ public class KafkaServicesConfiguration return new KafkaChatRoomFactory(chatMessageChannel); } - @Bean - Producer chatRoomChannelProducer( - Properties defaultProducerProperties, - ChatBackendProperties chatBackendProperties, - IntegerSerializer integerSerializer, - JsonSerializer chatRoomSerializer) - { - Map properties = new HashMap<>(); - defaultProducerProperties.forEach((key, value) -> properties.put(key.toString(), value)); - properties.put( - ProducerConfig.CLIENT_ID_CONFIG, - chatBackendProperties.getKafka().getClientIdPrefix() + "_CHATROOM_CHANNEL_PRODUCER"); - return new KafkaProducer<>( - properties, - integerSerializer, - chatRoomSerializer); - } - @Bean KafkaLikeShardingStrategy shardingStrategy(ChatBackendProperties properties) { diff --git a/src/test/java/de/juplo/kafka/chat/backend/persistence/kafka/CreateChatRoomRequestToTest.java b/src/test/java/de/juplo/kafka/chat/backend/persistence/kafka/CreateChatRoomRequestToTest.java index a917c9f9..c5e69353 100644 --- a/src/test/java/de/juplo/kafka/chat/backend/persistence/kafka/CreateChatRoomRequestToTest.java +++ b/src/test/java/de/juplo/kafka/chat/backend/persistence/kafka/CreateChatRoomRequestToTest.java @@ -13,7 +13,7 @@ public class CreateChatRoomRequestToTest { final String json = """ { - "name": "Foo-Room!", + "name": "Foo-Room!" }"""; ObjectMapper mapper;