Review main Ready for review Quiet

96668[BUGFIX] Resolve live search page access in SQL

Wolfgang Klinger CR 0 V 0 Hard +552 −74 updated 10/20/26, 16:31

Commit message

For non-admin users, both live search providers load the whole
page tree below the web mounts in PHP, one query per level, and
put every page uid into the IN() clause of each count and find
query. With large page trees each keystroke takes seconds.

The pages below the mounts are now resolved by a recursive common
table expression that PageTreeRepository adds to the search query.
It applies the same rules as the PHP walk, including workspaces.
No page uid list is built anymore, unless a listener of
BeforeSearchInDatabaseRecordProviderEvent reads it, or the searched
table lives on another database connection.

The repository now uses the workspace of the user, so records on
pages that only exist in that workspace are found.

In a test with 50,000 pages below the mount, a search went from
about 2.8 s to about 0.5 s.

Test this change

Run a command in your clone of the TYPO3 Core. Then try what the change does and vote on Verified in Gerrit. How to review a patch

Check out patch set 2
git fetch https://review.typo3.org/Packages/TYPO3.CMS refs/changes/68/96668/2 && git checkout FETCH_HEAD
Cherry-pick onto main
git fetch https://review.typo3.org/Packages/TYPO3.CMS refs/changes/68/96668/2 && git cherry-pick FETCH_HEAD

Review

  • Code review CR 0 Needs a vote
  • Verified V 0 Needs a vote
    • core-ci +1 CI

Merge conflicts 3

Issues 1

Files 11

Review log 24

  1. Wolfgang Klinger uploaded patch set 1 10/13/26, 10:01

  2. core-ci voted on patch set 1 V +1 10/13/26, 10:11 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/110997

  3. Benni Mack updated the commit message in patch set 2 V +1 10/20/26, 16:14

  4. core-ci voted on patch set 2 V +1 10/20/26, 16:31 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/111884