Review main Merged

65401[TASK] Migrate RecordListController hooks to an PSR-14 event

Daniel Windloff CR +2 V +2 Hard +260 −81 updated 08/30/20, 15:29

Commit message

The following hooks in the RecordListController are used to add
additional content above or below the main controller content:

*  $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']
   ['recordlist/Modules/Recordlist/index.php']['drawHeaderHook']
*  $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']
   ['recordlist/Modules/Recordlist/index.php']['drawFooterHook']

As this functionality could be useful, it should be migrated to a
PSR-14 event. Both hook implementations use a meaningful parameter
set (the request object) and return the additional content as string.
As there is no dependency to the parent object (the class instance of
the class where the hooks are placed), they could be migrated to a
psr-14 event without a breaking change.
Therefore, a PSR-14 event has been implemented to replace the hook
functionality. An event listener has been created to provide a
compatibility layer for both hooks. This allows a proper deprecation
without breaking the hooks.
The event listener (compatibility layer) could be removed in later
versions without any changes in the controller class.

Review

  • Code review CR +2 Done
    • Anja Leichsenring +2
    • Christian Kuhn +1
  • Verified V +2 Done
    • Anja Leichsenring +2
    • Christian Kuhn +1
    • TYPO3com +1 CI

Issues 1

Files 10

Review log 1217

  1. Daniel Windloff uploaded patch set 1 08/21/20, 07:02

  2. TYPO3com voted on patch set 1 V +1 08/21/20, 07:13 Completed build in 10m 32s on Fri, 21 Aug, 07:13 AM Test Summary: 72996 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-4790

  3. Christian Kuhn commented on patch set 1 08/21/20, 11:11

    I like that on reading already but would love to have an opinion on the strategy by benni, too.
  4. Christian Kuhn commented on patch set 1 CR -1 08/21/20, 11:14

    -1 for now, will take care to get more feedback.
  5. Daniel Windloff uploaded patch set 2 08/26/20, 06:48

  6. TYPO3com voted on patch set 2 V +1 08/26/20, 06:59 Completed build in 11m 01s on Wed, 26 Aug, 06:59 AM Test Summary: 73092 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-4971

  7. Christian Kuhn commented on patch set 2 08/29/20, 11:41

    General +1, one detail: The ArrayDimensionMatcher of the extension scanner could look for the hook array to find usages. This can be mentioned in the .rst file.
  8. Daniel Windloff uploaded patch set 3 08/30/20, 08:27

  9. TYPO3com voted on patch set 3 V +1 08/30/20, 08:40 Completed build in 12m 07s on Sun, 30 Aug, 08:40 AM Test Summary: 73092 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-5049

  10. Christian Kuhn voted on patch set 3 V +1 CR +1 08/30/20, 10:45

  11. Christian Kuhn uploaded patch set 4 08/30/20, 15:01

  12. TYPO3com voted on patch set 4 V -1 08/30/20, 15:03 Completed build in 22s on Sun, 30 Aug, 03:03 PM Test Summary: No tests found Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-5060

  13. Christian Kuhn uploaded patch set 5 08/30/20, 15:08

  14. Christian Kuhn voted on patch set 5 V +1 CR +1 08/30/20, 15:11

  15. TYPO3com voted on patch set 5 V +1 08/30/20, 15:25 Completed build in 13m 59s on Sun, 30 Aug, 03:25 PM Test Summary: 73146 passed Find logs and detail information at https://bamboo.typo3.com/browse/CORE-GTC-5062

  16. Anja Leichsenring voted on patch set 5 V +2 CR +2 08/30/20, 15:29

  17. Anja Leichsenring merged patch set 6 08/30/20, 15:29