aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--RELEASE-NOTES-1.231
-rw-r--r--includes/api/ApiFeedRecentChanges.php6
2 files changed, 7 insertions, 0 deletions
diff --git a/RELEASE-NOTES-1.23 b/RELEASE-NOTES-1.23
index ce3168ef9a0d..754c177002f3 100644
--- a/RELEASE-NOTES-1.23
+++ b/RELEASE-NOTES-1.23
@@ -249,6 +249,7 @@ production.
* Added list=prefixsearch that works like action=opensearch but can be used as
a generator.
* (bug 24782) Various modules will now use unique continuation parameters.
+* (bug 63249) Cache RecentChanges Atom feed in varnish for 15 seconds.
=== Languages updated in 1.23 ===
diff --git a/includes/api/ApiFeedRecentChanges.php b/includes/api/ApiFeedRecentChanges.php
index 9062ad92415c..a2641ee646c9 100644
--- a/includes/api/ApiFeedRecentChanges.php
+++ b/includes/api/ApiFeedRecentChanges.php
@@ -52,6 +52,12 @@ class ApiFeedRecentChanges extends ApiBase {
$this->dieUsage( 'Invalid subscription feed type', 'feed-invalid' );
}
+ $this->getMain()->setCacheMode( 'public' );
+ if ( !$this->getMain()->getParameter( 'smaxage' ) ) {
+ // bug 63249: This page gets hit a lot, cache at least 15 seconds.
+ $this->getMain()->setCacheMaxAge( 15 );
+ }
+
$feedFormat = $this->params['feedformat'];
$specialClass = $this->params['target'] !== null
? 'SpecialRecentchangeslinked'