Skip to content
Snippets Groups Projects
Commit e8a8c2e1 authored by Benni Mack's avatar Benni Mack
Browse files

[!!!][FEATURE] Introduce PSR-14 events when storing cached content in frontend

This change adds two new PSR-14 Events

* \TYPO3\CMS\Frontend\Event\AfterCacheableContentIsGeneratedEvent
* \TYPO3\CMS\Frontend\Event\AfterCachedPageIsPersistedEvent

which replace
$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['tslib/class.tslib_fe.php']['contentPostProc-cached']
$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['tslib/class.tslib_fe.php']['contentPostProc-all']
and
$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['tslib/class.tslib_fe.php']['usePageCache']
$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['tslib/class.tslib_fe.php']['insertPageIncache']
hooks.

Those hooks were much important and powerful, receiving
even more power by the new Events, which allow manipulating
content stored in cache, or when a page was cached in the
Frontend.

Additionally, the TSFE->generatePage_postProcessing() method
does now require a ServerRequestInterface as first paramter,
to be able to pass the current request to the new events.

Resolves: #97862
Releases: main
Change-Id: Ibd97d22ec1c4a726a78164b234bf8b4ce41f9dca
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/75039


Tested-by: default avatarOliver Bartsch <bo@cedev.de>
Tested-by: default avatarcore-ci <typo3@b13.com>
Tested-by: default avatarStefan Bürk <stefan@buerk.tech>
Tested-by: default avatarBenni Mack <benni@typo3.org>
Reviewed-by: default avatarOliver Bartsch <bo@cedev.de>
Reviewed-by: default avatarStefan Bürk <stefan@buerk.tech>
Reviewed-by: default avatarNikita Hovratov <nikita.h@live.de>
Reviewed-by: default avatarBenni Mack <benni@typo3.org>
parent c86acfb2
No related merge requests found
Showing
with 394 additions and 84 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