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

Negative Response Caching with Proxy.config.http.negative_caching_lifetime vs TTL-in-Cache #11854

Open
incheoloh opened this issue Nov 12, 2024 · 0 comments
Labels

Comments

@incheoloh
Copy link

cache.config

url_regex=.*    ttl-in-cache=20s

records.yaml

records:
  http:
    negative_caching_enabled: 1
    negative_caching_lifetime: 5

ttl-in-cache in cache.config sets a default TTL, applying this duration to cached responses regardless of the response code.
proxy.config.http.negative_caching_lifetime in records.yaml is intended to set the TTL for negative responses (e.g., 403, 404). However, if ttl-in-cache is defined in cache.config, it takes precedence and applies a TTL of 20 seconds to all responses, including 403.

Is there any way to use the value set by proxy.config.http.negative_caching_lifetime instead of the ttl set by ttl-in-cache for negative responses?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants