Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Address frequent errors logged by compactor regarding meta not found #327

Merged
merged 6 commits into from
Nov 10, 2020

Conversation

mdisibio
Copy link
Contributor

@mdisibio mdisibio commented Nov 6, 2020

What this PR does:
The compactor can log frequent errors like the following: msg="unable to find meta during compaction. trying again on this block list". The root cause seems to be that when a block is compacted, it is updated in the storage backend, but not in the in-memory blocklist until the next polling cycle. This causes the stale entry to be considered for compaction on subsequent runs, causing the errors for several minutes (based on default timings).

This PR updates the compactor to immediately update the in-memory blocklist to be aware of changes it makes: add the new blocks created during compaction, move the old ones to the compacted section. The changes are temporary and get overwritten during the next poll cycle, but are still helpful to cut down on the noise, and additionally will prevent failing/extra calls to the storage backend to load the meta.

Which issue(s) this PR fixes:

Checklist

  • Tests updated
  • Documentation added
  • CHANGELOG.md updated - the order of entries should be [CHANGE], [FEATURE], [ENHANCEMENT], [BUGFIX]

tempodb/tempodb.go Show resolved Hide resolved
tempodb/tempodb.go Outdated Show resolved Hide resolved
tempodb/tempodb.go Outdated Show resolved Hide resolved
tempodb/tempodb.go Outdated Show resolved Hide resolved
tempodb/compactor_test.go Show resolved Hide resolved
@joe-elliott joe-elliott merged commit 78f3554 into master Nov 10, 2020
@joe-elliott joe-elliott deleted the compaction-meta-errors branch November 10, 2020 22:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants