blockstore: Update flaky compaction test #5131
Open
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.
Problem
See #4188 for more context, but the TLDR:
Summary of Changes
Update the compaction call to NOT take start/end keys, which results in the entire column being considered for compaction. This results in a different call path in rocksdb being used which picks up the overlapping data (which signals to run a compaction) every time.
Previously, I could run the failing unit test in a loop and see a failure within ~20 iterations, often times fewer. With this PR, I have run > 500 iterations without failure
This isn't necessarily a perfect solution; however, I think it is a "good enough" solution for now so our team can get back time from flaky CI. RPC will call blockstore functions that check the value of the atomic before proceeding; we could possibly go that route but then this test isn't exercising much more than setting and reading an integer