filter out blocks marked for deletion in the bucket index ids fetcher… #5712
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.
filter out blocks marked for deletion in the bucket index ids fetcher, so we are protected even when apply ignoreDeletionMarkerFilter the block has been deleted.
What this PR does:
Previously in this pr #5681
we introduced bucketindex BlockIDsFetcher.
In that IDs fetcher, we just send all blocks to the chan, and didn't filter out the blocks that are marked for deletion.
During compaction run, when we try to apply the ignoreDeletionMarkerFilter, because some blocks marked for deletion are already deleted by the cleaner. Then the we failed to filter out those blocks.
Then during compaction, when we try to download the meta.json from those blocks, we get an error, because there is no meta.json in the block. The block is already deleted.
This PR try to fix the problem by filtering out the blocks marked for deletion in the bucket-index ids fetcher. Then apply the ignoreDeletionMarkerFilter again outside.
Which issue(s) this PR fixes:
Fixes #
Checklist
CHANGELOG.md
updated - the order of entries should be[CHANGE]
,[FEATURE]
,[ENHANCEMENT]
,[BUGFIX]