Repository navigation
Tests make the bucket once per process; app job prints RustFS's log on failure - #225
Open
ndbroadbent wants to merge 1 commit into
Open
ndbroadbent wants to merge 1 commit into
ndbroadbent wants to merge 1 commit into
Conversation
…og when it fails #217 didn't end the baselines flake: run 47389263799 (#222) still got NoSuchBucket on first uploads, after HEAD bucket had answered. Every failure was in the burst of concurrent creates as the one test binary starts, so the fixture now creates the bucket once per process (a tokio OnceCell), and a failed app job prints the store's log.
This branch has not been deployed
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.
The baselines flake survived #217. In run 47389263799 (#222, which includes #217), three baselines tests still got HTTP 404 NoSuchBucket on their first upload, about a second into the test binary. So
ensure_bucketsaw the bucket answer to HEAD, and the upload straight after was told it doesn't exist. The bucket existed, then went missing.I can't reproduce it. On fresh RustFS 1.0.6 containers on agents-box-2, none of these failed:
So this PR does two things.
1. Once per process.
fixtures::blob_store()creates the bucket once per test process, in a process-widetokio::sync::OnceCell, instead of every test creating it. The tests in the one binary start together, and every observed failure was during that burst of concurrent creates on a fresh store. With this change, nothing in the process can create the bucket concurrently any more.syncfeature, forOnceCell. Other crates already compile it, so Cargo.lock doesn't change.2. Evidence if it recurs. When the app job fails, it prints the last 300 lines of the RustFS container's log. If the bucket still goes missing, the store's own account will be in the run.
Locally, on fresh Postgres and RustFS: the full app test binary passes (367), clippy is clean, and actionlint is clean.
Open in [code]smith · Need help on this PR? Tag
@codesmith-botwith what you need.