From 2f1292e34d007a826de38e1735e7b55c5864c328 Mon Sep 17 00:00:00 2001 From: Kai Moritz Date: Sun, 26 Feb 2023 14:28:47 +0100 Subject: [PATCH] WIP:sharding-in-implementation --- .../chat/backend/persistence/kafka/KafkaChatHomeService.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/main/java/de/juplo/kafka/chat/backend/persistence/kafka/KafkaChatHomeService.java b/src/main/java/de/juplo/kafka/chat/backend/persistence/kafka/KafkaChatHomeService.java index 2e3b42f6..7f36024d 100644 --- a/src/main/java/de/juplo/kafka/chat/backend/persistence/kafka/KafkaChatHomeService.java +++ b/src/main/java/de/juplo/kafka/chat/backend/persistence/kafka/KafkaChatHomeService.java @@ -124,13 +124,13 @@ public class KafkaChatHomeService implements ChatHomeService, ConsumerRebalanceL } @Override - public Mono getChatRoom(int shard, UUID id) + public Mono getChatRoom(UUID id) { return Mono.justOrEmpty(chatrooms[shard].get(id)); } @Override - public Flux getChatRooms(int shard) + public Flux getChatRooms() { return Flux.fromStream(chatrooms[shard].values().stream()); } -- 2.20.1