Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -468,6 +468,8 @@ public void testDeleteBlockCommandHandleWhenDeleteCommandQueuesFull()
dnConf.setBlockDeleteQueueLimit(blockDeleteQueueLimit);
handler = new DeleteBlocksCommandHandler(
container, configuration, dnConf, "");
// Stop the worker so that handle() can fill the queue without commands being consumed.
handler.stop();

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just an observation: I found it interesting that handle() still queues after stop(). 🙂 This looks fine given the production shutdown flow, but if production later rejects commands after shutdown, we’ll need to adjust the test setup.

@rich7420 rich7420 Oct 10, 2026 •

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the review! Agreed!


// Check if the command status is as expected: PENDING when queue is not full, FAILED when queue is full
for (int i = 0; i < blockDeleteQueueLimit + 2; i++) {
Expand All @@ -482,6 +484,7 @@ public void testDeleteBlockCommandHandleWhenDeleteCommandQueuesFull()
assertEquals(cmdStatus.getProtoBufMessage().getBlockDeletionAck().getResultsCount(), 0);
}
}
assertEquals(blockDeleteQueueLimit, handler.getQueuedCount());
}

@ContainerTestVersionInfo.ContainerTest
Expand Down
Loading