-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Remove tenant shipper after prunning #6207
Remove tenant shipper after prunning #6207
Conversation
We noticed another edge case with tenant prunning where the shipper would keep syncing blocks even after the tenant TSDB was removed. The reason for this is because the shipper runs in parallel in a different goroutine and is not stopped when the TSDB is gone. This leads to empty shipper files being created on disk once a tenant is pruned, and the orphaned TSDBs alert from the mixing starts to fire. This commit modifies the pruning logic to remove all components from a tenant once eviction conditions have been met. Signed-off-by: Filip Petkovski <filip.petkovsky@gmail.com>
Signed-off-by: Filip Petkovski <filip.petkovsky@gmail.com>
@@ -425,7 +425,7 @@ func TestMultiTSDBPrune(t *testing.T) { | |||
name: "prune tsdbs with object storage", | |||
bucket: objstore.NewInMemBucket(), | |||
expectedTenants: 2, | |||
expectedUploads: 1, | |||
expectedUploads: 2, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is now 2
because background syncs are constantly running, so the compacted tenant gets uploaded.
Signed-off-by: Filip Petkovski <filip.petkovsky@gmail.com>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👏
We noticed another edge case with tenant prunning where the shipper would keep syncing blocks even after the tenant TSDB was removed. The reason for this is because the shipper runs in parallel in a different goroutine and is not stopped when the TSDB is gone.
This leads to empty shipper files being created on disk once a tenant is pruned, and the orphaned TSDBs alert from the mixing starts to fire.
This commit modifies the pruning logic to remove all components from a tenant once eviction conditions have been met.
Changes
Verification