-
- Downloads
[FEATURE] Introduce RedirectWasHitEvent
A new PSR-14 based event "RedirectWasHitEvent" is introduced, allowing extension authors to further process a matched redirect and to adjust the PSR-7 Response. It's furthermore possibility to influence core functionality, e.g. the hit count increment. This is especially useful for e.g. the use of custom monitoring tools, which should not increment the hit count while testing the redirects. As a side effect, the middleware is cleaned up, since the increment task is moved into a dedicated event listener. Resolves: #96147 Releases: main Change-Id: I146b60d9a347199f7a871edca0845e7d635817df Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/72437 Tested-by:core-ci <typo3@b13.com> Tested-by:
Benni Mack <benni@typo3.org> Tested-by:
Stefan Bürk <stefan@buerk.tech> Tested-by:
Oliver Bartsch <bo@cedev.de> Reviewed-by:
Benni Mack <benni@typo3.org> Reviewed-by:
Stefan Bürk <stefan@buerk.tech> Reviewed-by:
Oliver Bartsch <bo@cedev.de>
Showing
- typo3/sysext/core/Documentation/Changelog/12.0/Feature-96147-NewPSR-14RedirectWasHitEvent.rst 82 additions, 0 deletions...gelog/12.0/Feature-96147-NewPSR-14RedirectWasHitEvent.rst
- typo3/sysext/redirects/Classes/Event/RedirectWasHitEvent.php 77 additions, 0 deletionstypo3/sysext/redirects/Classes/Event/RedirectWasHitEvent.php
- typo3/sysext/redirects/Classes/EventListener/IncrementHitCount.php 57 additions, 0 deletions...ext/redirects/Classes/EventListener/IncrementHitCount.php
- typo3/sysext/redirects/Classes/Http/Middleware/RedirectHandler.php 27 additions, 45 deletions...ext/redirects/Classes/Http/Middleware/RedirectHandler.php
- typo3/sysext/redirects/Configuration/Services.yaml 5 additions, 0 deletionstypo3/sysext/redirects/Configuration/Services.yaml
- typo3/sysext/redirects/Tests/Functional/EventListener/Fixtures/Redirects.xml 23 additions, 0 deletions...cts/Tests/Functional/EventListener/Fixtures/Redirects.xml
- typo3/sysext/redirects/Tests/Functional/EventListener/IncrementHitCountTest.php 99 additions, 0 deletions.../Tests/Functional/EventListener/IncrementHitCountTest.php
Loading
Please register or sign in to comment