From 9198979864e0ea9cda01878eb01e628d5628a448 Mon Sep 17 00:00:00 2001 From: Kai Moritz Date: Fri, 18 Aug 2023 16:21:23 +0200 Subject: [PATCH] NG --- .../kafka/KafkaServicesConfiguration.java | 18 ------------------ .../kafka/CreateChatRoomRequestToTest.java | 2 +- 2 files changed, 1 insertion(+), 19 deletions(-) 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; -- 2.20.1