Skip to content
Snippets Groups Projects
Commit b8621ebf authored by Claus Due's avatar Claus Due Committed by Georg Ringer
Browse files

[BUGFIX] Flush all cache tags in bulk when deleting records

This patch makes the TYPO3 DB cache backend capable of
flushing tags using an array of tag names that is then turned
into a CSV list and used in an `IN` query. It limits the number
of cache flushes from $numRecords to ceil($numRecords/100).

NB: the desired behavior is introduced by reviving the
flushByTags() method as API for cache frontends and backends.
The method was previously present but was dropped in order to
keep sync with Flow - which then later added the method exactly
because of performance concerns.

TYPO3 however did not revive this method and obviously the sync
with Flow is no longer a concern. So this patch restores the
full API required to flush tags in bulk, adds an implementation
for the TYPO3 DB cache backend and adds delegation to the old
flushByTag method for backends not covered by this patch.

It will be possible to improve other backends as well but this
patch focuses exclusively on the DB cache backend for *NIX,
which is...
parent e664996d
No related merge requests found
Showing
with 441 additions and 32 deletions
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment