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

[v23.2.x] cloud: Add config options to trigger cache trim #19629

Open
wants to merge 1 commit into
base: v23.2.x
Choose a base branch
from

Conversation

jcipar
Copy link
Contributor

@jcipar jcipar commented Jun 11, 2024

Backport of #18756

Backports Required

  • none - not a bug fix
  • none - this is a backport
  • none - issue does not exist in previous branches
  • none - papercut/not impactful enough to backport
  • v24.1.x
  • v23.3.x
  • v23.2.x

When the cloud storage cache is completely filled, puts to the cache
are blocked. This prevents readers from progressing. In some clusters
the trim operation can take a long time, up to hours. When this happens,
readers will time out, generating errors.

This commit adds two configuration options that control when the trim
is triggered. By setting these lower than the caches maximum size,
cloud storage can begin a trim operation before the cache is completely
filled, allowing readers to progress as the trim is going on in the
background.
- cloud_storage_cache_trim_threshold_size
- cloud_storage_cache_trim_threshold_objects

When a put occurs, if the cache is over these limits it triggers a trim
in the background.

(cherry picked from commit 027632c)
@jcipar jcipar force-pushed the backport-pr-18756-v23.2.x-768 branch from 9b241c6 to 167c443 Compare June 26, 2024 17:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants