Ema has submitted this change and it was merged.
Change subject: RESTBase caching: Force clients to revalidate purged end points
......................................................................
RESTBase caching: Force clients to revalidate purged end points
Most of our purged end points should be re-validated by clients on each view,
so that they make sure to have the latest version before reusing content. This
forces clients to re-validate by setting max-age to 0, and adding
must-revalidate.
This patch also reduces max-age for the related end point to one hour, while
leaving s-maxage at a day. This makes sure that clients get the latest copy
from the CDN every now & then, and reduces the time to clear caches in
emergencies.
Change-Id: I16c494b2178e82364bda763662d604c49641efa1
---
M modules/restbase/templates/config.yaml.erb
1 file changed, 2 insertions(+), 2 deletions(-)
Approvals:
Ema: Verified; Looks good to me, approved
jenkins-bot: Verified
diff --git a/modules/restbase/templates/config.yaml.erb
b/modules/restbase/templates/config.yaml.erb
index a060acb..5a4ebc7 100644
--- a/modules/restbase/templates/config.yaml.erb
+++ b/modules/restbase/templates/config.yaml.erb
@@ -59,9 +59,9 @@
host: <%= @purge_host %>
port: <%= @purge_port %>
related:
- cache_control: s-maxage=86400, max-age=86400
+ cache_control: s-maxage=86400, max-age=3600
# Cache headers for purged end points.
- purged_cache_control: s-maxage=43200, max-age=43200
+ purged_cache_control: s-maxage=43200, max-age=0, must-revalidate
# A different project template, sharing configuration options.
wikimedia.org: &wikimedia.org
--
To view, visit https://gerrit.wikimedia.org/r/277056
To unsubscribe, visit https://gerrit.wikimedia.org/r/settings
Gerrit-MessageType: merged
Gerrit-Change-Id: I16c494b2178e82364bda763662d604c49641efa1
Gerrit-PatchSet: 2
Gerrit-Project: operations/puppet
Gerrit-Branch: production
Gerrit-Owner: GWicke <[email protected]>
Gerrit-Reviewer: BBlack <[email protected]>
Gerrit-Reviewer: Eevans <[email protected]>
Gerrit-Reviewer: Ema <[email protected]>
Gerrit-Reviewer: Filippo Giunchedi <[email protected]>
Gerrit-Reviewer: Giuseppe Lavagetto <[email protected]>
Gerrit-Reviewer: Mobrovac <[email protected]>
Gerrit-Reviewer: Ppchelko <[email protected]>
Gerrit-Reviewer: jenkins-bot <>
_______________________________________________
MediaWiki-commits mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/mediawiki-commits