HomePhabricator

Cache revision ID to page ID mappings

Tags
None
Referenced Files
None
Subscribers
None

Description

Cache revision ID to page ID mappings

When we retrieve unpatrolled recent changes, MediaWiki already gives us
the page ID corresponding to each revision ID, so we can store it in a
cache at that point and then use that cache so we don’t have to look up
the page ID via the API explicitly. The only case where that API lookup
is still necessary is when a user manually navigates to /diff/<id>
without going via the any_diff() endpoint.

A cache size of 1024*1024 elements seems to correspond to an internal
size of the underlying store of some 84 million bytes, which should be
totally acceptable on Toolforge.

Details

Provenance
LucasWerkmeisterAuthored on Feb 2 2019, 5:18 PM
Parents
R2469:a9563a4d6082: Move unpatrolled_changes() to ids module
Branches
Unknown
Tags
Unknown
ChangeId
None