Skip to content

Commit

Permalink
Merge branch 'task/improve-cache-handling' into develop
Browse files Browse the repository at this point in the history
  • Loading branch information
dhoffmann1979 committed Dec 9, 2024
2 parents 4b728c8 + f7bed55 commit f6612b8
Showing 1 changed file with 16 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,22 @@ protected function executeTask(): bool
$dataHandler = $this->getDataHandler();
$commands = GeneralUtility::trimExplode(',', $this->configuration['pid'], true);
foreach ($commands as $command) {
$dataHandler->clear_cacheCmd($command);
// This is the same method ultimately called as if we changed the
// DataBase via DataHandler. This means it is also the same logic
// used as the backend.
// This is @internal. However, it does more processing than
// any public api.
$dataHandler->registerRecordIdForPageCacheClearing(
'pages',
$command,
);
}

// We want to call $dataHandler->processClearCacheQueue().
// That function is protected, so we have to do it indirectly.
$dataHandler->process_cmdmap();

foreach ($commands as $command) {
$this->addMessage('Cleared frontend cache with configuration clearCacheCmd=' . $command);
}
return true;
Expand Down

0 comments on commit f6612b8

Please sign in to comment.