Page MenuHomePhabricator

Replace transcache table with objectcache backend
Closed, ResolvedPublic

Description

Currently, interwiki template transclusions are cached in the transcache table. This implementation has several drawbacks:

  • There is no garbage collection logic - the transcache table will continue to grow in size as the wiki evolves
  • Large templates can cause a database error depending on settings, if they do not fit into the transcache table
  • In a multi-wiki environment, responses for the same template are cached and duplicated on each wiki

I'd like to propose to generify caching of interwiki transclusion logic, and provide an alternative backend, such as one based on the ObjectCache implementation configured for the wiki (while keeping the original implementation available). Having an ObjectCache based transclusion cache fits the purpose of the transclusion cache being an actual cache, and will solve the aforementioned issues with cache garbage collection and duplicate entries.

Event Timeline

TK-999 created this task.Mar 14 2018, 4:38 PM
Restricted Application added a subscriber: Aklapper. · View Herald TranscriptMar 14 2018, 4:38 PM

I'll gladly work on this if it is deemed to be acceptable.

Yeah, the only reason created this separate ticket since it represents an improvement that can be done within the bounds of the existing interwiki transclusion system without requiring an extensive overhaul or migration process.

I'll gladly work on this if it is deemed to be acceptable.

@TK-999: Thanks for your interest!
CC'ing @aaron as he's listed for Cache on mw:Developers/Maintainers.
@aaron: Any input / guidance / opinions (or an idea who could provide them)?

Change 439316 had a related patch set uploaded (by Aaron Schulz; owner: Aaron Schulz):
[mediawiki/core@master] [WIP] Make interwiki transclusion use the WAN cache

https://gerrit.wikimedia.org/r/439316

Krinkle renamed this task from Provide alternative interwiki transclusion cache backends to Replace transcache table with objectcache backend.Jul 28 2018, 8:42 PM
Krinkle assigned this task to aaron.
Krinkle removed a project: MediaWiki-Cache.
aaron triaged this task as Low priority.Jul 30 2018, 8:12 PM
aaron moved this task from Inbox to Blocked or Needs-CR on the Performance-Team board.
Nemo_bis added a subscriber: Nemo_bis.

Change 439316 merged by jenkins-bot:
[mediawiki/core@master] Make interwiki transclusion use the WAN cache

https://gerrit.wikimedia.org/r/439316

Change 455875 had a related patch set uploaded (by Aaron Schulz; owner: Aaron Schulz):
[mediawiki/core@master] Drop the transcache table from the schema

https://gerrit.wikimedia.org/r/455875

Krinkle moved this task from Untriaged to Schema changes on the Wikimedia-Rdbms board.

Change 455875 merged by jenkins-bot:
[mediawiki/core@master] Drop the transcache table from the schema

https://gerrit.wikimedia.org/r/455875

aaron closed this task as Resolved.Sep 2 2018, 9:26 PM