midom@svn.wikimedia.org wrote:
- /* Array of caching hints for ParserCache */
- static public $mCacheTTLs = array (
'currentmonth' => 86400,
'currentmonthname' => 86400,
'currentmonthnamegen' => 86400,
'currentmonthabbrev' => 86400,
A clever hack for some of these might be to have the expiry vary based on the expected change, where it's predictable.
For instance if we're dependent on a month change, and it's 18:00 on the 31st of the month, the value will change in just 21600 seconds. A "smarter" cache could then expire it early, so the date flips over on time instead of 18 hours late.
(In theory it should be possible to have the HTTP caching expiry match this too, though I'm not sure if that'll interact properly with our current cache header rewrites.)
-- brion vibber (brion @ wikimedia.org)