Review main Merged

90048[BUGFIX] Optimize queries in RootlineUtility

Benni Mack CR +2 V +2 Easy +15 −11 updated 07/29/25, 17:58

Commit message

When deploying a v13 project into real-life,
one quickly notices empty rootline caches and
the limitations of the database on
enterprise-level projects.

This is partially due to some limitations of
current Doctrine DBAL 4.2 (4.3 is much better),
but a runtime cache for the DB fields is much
better and faster due to unneeded quoting.

Review

  • Code review CR +2 Done
    • Benni Mack +2
    • Stefan Bürk +1
    • Christian Kuhn +1
  • Verified V +2 Done
    • Benni Mack +2
    • Stefan Bürk +1
    • Christian Kuhn +1
    • core-ci +1 CI

Issues 1

Files 1

Review log 1925

  1. Benni Mack uploaded patch set 1 07/10/25, 14:51

  2. Christian Kuhn commented on patch set 1 CR -1 07/10/25, 14:53

    will review & fine-tune soon.
  3. Benni Mack uploaded patch set 2 CR -1 07/10/25, 14:53

  4. core-ci voted on patch set 1 V +1 07/10/25, 15:04 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/81566

  5. core-ci voted on patch set 2 V +1 07/10/25, 15:11 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/81569

  6. Andreas Kienast commented on patch set 2 07/11/25, 09:52

    RootlineUtility.php:1417

    From my understanding: this cache is only filled if the schema cache `pages-fields` is considered invalid. Once something valid is available, this runtime cache is always empty. Isn't this additional cache layer superfluous then? Shouldn't the runtime cache be filled anytime (by moving this call outside the `if()`)?
  7. Benni Mack uploaded patch set 3 V +1 07/11/25, 11:18

  8. core-ci voted on patch set 3 V +1 07/11/25, 11:25 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/81610

  9. Andreas Kienast commented on patch set 3 07/11/25, 11:44

    RootlineUtility.php:1417 Reply

    Done
  10. Benni Mack marked it work in progress 07/11/25, 15:58

  11. Christian Kuhn commented on patch set 3 07/11/25, 23:41

    RootlineUtility.php:1406

    it looks to me as if we should use Core\Database\Schema\SchemaInformation->introspectTable() (which does the caching in filesystem internally), to then store the getColumns result into "our" runtimeCache.
  12. Benni Mack uploaded patch set 4 V +1 07/15/25, 07:17

  13. core-ci voted on patch set 4 V +1 07/15/25, 07:25 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/81721

  14. Benjamin Franzke commented on patch set 4 07/23/25, 08:35

    The database `SchemaInformation` uses a file-cache `database_schema` https://github.com/TYPO3/typo3/blob/main/typo3/sysext/core/Classes/Database/Connection.php#L440-L446 https://github.com/TYPO3/typo3/blob/main/typo3/sysext/core/Configuration/DefaultConfiguration.php#L256-L258 Are we sure this statement is actually true or maybe a system (mis)configuration issue? The introspection is meant to be done once and cached afterwards. (but I definitely see room for improvement there, it should be hookued up to the `CacheWarmupEvent`)
  15. Benni Mack uploaded patch set 5 V +1 07/23/25, 13:55

  16. Benni Mack commented on patch set 5 07/23/25, 13:56

    RootlineUtility.php:1406 Reply

    Done
  17. core-ci voted on patch set 5 V +1 07/23/25, 14:03 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/82187

  18. Benni Mack updated the commit message in patch set 6 V +1 07/25/25, 19:34

  19. Benni Mack marked it ready for review 07/25/25, 19:34

  20. core-ci voted on patch set 6 V +1 07/25/25, 19:42 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/82332

  21. Benni Mack commented on patch set 6 07/28/25, 06:23

    Reply

    debugged this - that was not the underlying root cause.
  22. Stefan Bürk voted on patch set 6 CR +1 V +1 07/28/25, 16:15

  23. Christian Kuhn commented on patch set 6 CR +1 V +1 07/28/25, 17:49

    Reply

    Done
  24. Benni Mack voted on patch set 6 CR +2 V +2 07/29/25, 17:58

  25. Benni Mack merged patch set 7 07/29/25, 17:58