apoorvmittal10 commented on code in PR #22635:
URL: https://github.com/apache/kafka/pull/22635#discussion_r3451055033
##########
server/src/main/java/org/apache/kafka/server/share/dlq/ShareGroupDLQStateManager.java:
##########
@@ -185,6 +185,9 @@ public CompletableFuture<Void>
dlq(ShareGroupDLQRecordParameter param) {
// Visibility for tests
CompletableFuture<Void> dlq(ShareGroupDLQRecordParameter param, long
requestBackoffMs, long requestBackoffMaxMs, int maxRequestAttempts) {
+ if (!this.isStarted.get()) {
+ return CompletableFuture.failedFuture(new
IllegalStateException("ShareGroupDLQStateManager is not started."));
+ }
Review Comment:
So shouldn't we also make sure always the DLQStateManager is close after
SharePartition and SharePartitionManager so we never receive the calls here as
well? If it's already happening then can we write the code comments please so
we do not change the order in future.
The current code in PR can always exist as safe check.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]