Fix autoCompact intermittent busy error#689
Merged
Merged
Conversation
Signed-off-by: Daniel Frankcom <frankcom@amazon.com>
|
🤖 Auto-triaged by documentdb-triage-tool. Applied: Reasoningcomponent from path globs (test-coverage, test-framework); effort from diff stats (52+38 LOC, 6 files); LLM: Fixes a flaky/intermittent test failure in the autoCompact suite by switching to retry-aware command execution, a small targeted fix within test code. If a label is wrong, remove it manually and ping |
eerxuan
approved these changes
Jul 15, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This change fixes a flaky failure in the
autoCompacttest suite, which can be triggered by asynchronous background processing.autoCompactschedules a background task that winds down asynchronously. While it's winding down, anyautoCompactcall can be transiently rejected as busy.Previously we attempted to work around this by ensuring an idle state at the start of each run, but it is not possible to reliably detect this without delving into engine internals. To work around this, each command execution has been modified to use the
execute_admin_with_retry_commandmethod, which allows the tests to tolerate this background task condition. The outcomes remain the same and will be eventually consistent, we just can't reliably get the engine into a clean starting state due to lack of engine-agnostic observability.