From b48309fdbe0cc14f0b4800d885eeae2990fc91dc Mon Sep 17 00:00:00 2001 From: Kai Moritz Date: Tue, 29 Aug 2023 20:33:37 +0200 Subject: [PATCH] LoadInProgressException - ALIGN --- .../kafka/chat/backend/domain/LoadInProgressException.java | 2 +- .../chat/backend/persistence/kafka/ChatRoomChannel.java | 7 ++----- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/src/main/java/de/juplo/kafka/chat/backend/domain/LoadInProgressException.java b/src/main/java/de/juplo/kafka/chat/backend/domain/LoadInProgressException.java index 099dbb81..d87e76d3 100644 --- a/src/main/java/de/juplo/kafka/chat/backend/domain/LoadInProgressException.java +++ b/src/main/java/de/juplo/kafka/chat/backend/domain/LoadInProgressException.java @@ -1,4 +1,4 @@ -package de.juplo.kafka.chat.backend.persistence.kafka; +package de.juplo.kafka.chat.backend.domain; public class LoadInProgressException extends IllegalStateException diff --git a/src/main/java/de/juplo/kafka/chat/backend/persistence/kafka/ChatRoomChannel.java b/src/main/java/de/juplo/kafka/chat/backend/persistence/kafka/ChatRoomChannel.java index 10d26baa..234554eb 100644 --- a/src/main/java/de/juplo/kafka/chat/backend/persistence/kafka/ChatRoomChannel.java +++ b/src/main/java/de/juplo/kafka/chat/backend/persistence/kafka/ChatRoomChannel.java @@ -1,9 +1,6 @@ package de.juplo.kafka.chat.backend.persistence.kafka; -import de.juplo.kafka.chat.backend.domain.ChatRoom; -import de.juplo.kafka.chat.backend.domain.ChatRoomInfo; -import de.juplo.kafka.chat.backend.domain.Message; -import de.juplo.kafka.chat.backend.domain.ShardNotOwnedException; +import de.juplo.kafka.chat.backend.domain.*; import de.juplo.kafka.chat.backend.persistence.kafka.messages.AbstractMessageTo; import de.juplo.kafka.chat.backend.persistence.kafka.messages.CommandCreateChatRoomTo; import de.juplo.kafka.chat.backend.persistence.kafka.messages.EventChatMessageReceivedTo; @@ -372,7 +369,7 @@ public class ChatRoomChannel implements Runnable, ConsumerRebalanceListener { if (loadInProgress) { - return Mono.error(new LoadInProgressException(shard)); + return Mono.error(new LoadInProgressException()); } if (!isShardOwned[shard]) -- 2.20.1