tests: fix a flake in test_sharding_split_compaction #8136
Merged
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
This test could occasionally trigger a "removing local file ... because it has unexpected length log" when using the
compact-shard-ancestors-persistent
failpoint is in use, which is unexpected because that failpoint stops the process when the remote metadata is in sync with local files.It was because there are two shards on the same pageserver, and while the one being compacted explicitly stops at the failpoint, another shard was compacting in the background and failing at an unclean point. The test intends to disable background compaction, but was mistakenly revoking the value of
compaction_period
when it updatedpitr_interval
.Example failure:
https://neon-github-public-dev.s3.amazonaws.com/reports/pr-8123/9602976462/index.html#/testresult/7dd6165da7daef40
Summary of changes
TENANT_CONF
in the test to use properly typed values, so that it is usable in pageserver APIs as well as via neon_local.pitr_interval
, retain the overrides from the start of the test, so that there won't be any background compaction going on during the test.Checklist before requesting a review
Checklist before merging