Review main Merged

70834[FEATURE] Add BootCompletedEvent

Benni Mack CR +2 V +2 Normal +140 −1 updated 09/02/21, 11:11

Commit message

This change adds a new PSR-14 based event to hook into
the booting process after all configuration has been set up
and TYPO3 has fully booted.

This event replaces the existing
$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['GLOBAL']['extTablesInclusion-PostProcessing']
hook and its interface
TYPO3\CMS\Core\Database\TableConfigurationPostProcessingHookInterface

Review

  • Code review CR +2 Done
    • Benjamin Franzke +2
    • Oli Bartsch +1
  • Verified V +2 Done
    • Benjamin Franzke +2
    • Oli Bartsch +1
    • core-ci +1 CI

Issues 1

Files 8

Review log 1014

  1. Benni Mack uploaded patch set 1 08/31/21, 12:02

  2. Benjamin Franzke commented on patch set 1 08/31/21, 12:10

    Bootstrap.php:546

    Sounds like we should rather put this into Bootstrap::init() and BootService. At that point where we also set $bootState->complete = true; Nice thing is: That avoids the ugly call to GeneralUtility::getContainer().
  3. core-ci voted on patch set 1 V +1 08/31/21, 12:16 Core CI is happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/15926

  4. Benni Mack commented on patch set 1 08/31/21, 13:19

    Bootstrap.php:546 Reply

    I'm very much in favor of this, however this wouldn't be a 1:1 replacement for the existing hook, I guess.
  5. Helmut Hummel commented on patch set 1 08/31/21, 15:55

    Bootstrap.php:546 Reply

    I think the question here is: what exactly does "boot completed" mean on the one hand, and what should one be able to accomplish with the ext tables processing hook?
  6. Benni Mack commented on patch set 1 09/01/21, 07:16

    Bootstrap.php:546 Reply Unresolved

    Yes. I found 72 extensions in TER using this hook. Most want to modify TCA after it has been compiled, some want to add more things after all ext_tables.php files have been processed. Comment from Flux: // The following is a dual registration of the same TCA-manipulating hook; the reason for registering it twice for two // different hooks is that extTablesInclusion-PostProcessing does not get executed in FE, resulting in errors due to // features provided by this hook subscriber not being loaded. The reason for this hook to manipulate TCA was that there wasn't a proper hook for extensions after TCA compilation (as ext_tables.php could manipulate TCA as well). I think we should go with "put this after boot.complete" and also reference the "AfterTcaCompilationEvent" which is the one for people should use for TCA changes.
  7. Benni Mack uploaded patch set 2 09/01/21, 09:04

  8. core-ci voted on patch set 2 V -1 09/01/21, 09:18 Core CI is not happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/15993

  9. core-ci voted on patch set 2 V +1 09/02/21, 09:54 Core CI is happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/15993

  10. Benjamin Franzke uploaded patch set 3 09/02/21, 10:51

  11. core-ci voted on patch set 3 V +1 09/02/21, 11:04 Core CI is happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/16065

  12. Oli Bartsch voted on patch set 3 V +1 CR +1 09/02/21, 11:06

  13. Benjamin Franzke voted on patch set 3 V +2 CR +2 09/02/21, 11:11

  14. Benjamin Franzke merged patch set 4 09/02/21, 11:11