Review main Ready for review

98081[FEATURE] Capture log records for a scoped part of a request

Benni Mack CR 0 V 0 Expert +1007 −431 updated 11/26/26, 19:24

Commit message

LogManager::startCapture() collects the log records of all loggers
until the returned LogCapture is stopped, independent of the
configured writers and including loggers created before. Without an
active capture, the overhead is a single level comparison.
Logger::isHandling() tells whether a record of a level is handled at
all, so expensive log data can be skipped.

The admin panel uses one capture per request for its debug modules.
SQL queries and dispatched PSR-14 events are logged as debug records
and read from the capture by the "Query information" and "Events"
modules. This replaces the InMemoryLogWriter registered globally for
debug records, the recursive rewrite of the logging configuration,
the stateful SQL logger with its middleware and the event counter.
Nothing of a request is kept in shared services anymore, which makes
the admin panel safe for long-running PHP processes.

Functional tests reading log records use a capture instead of a
static writer fixture.
Show more Show less

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/81/98081/2 && git checkout FETCH_HEAD
Cherry-pick onto main
git fetch https://review.typo3.org/Packages/TYPO3.CMS refs/changes/81/98081/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 30

Show 10 more files Show less

Review log 35

  1. Benni Mack uploaded patch set 1 11/26/26, 19:13

  2. Benni Mack uploaded patch set 2 11/26/26, 19:15

  3. core-ci voted on patch set 1 V +1 11/26/26, 19:20 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/115606

  4. core-ci voted on patch set 2 V +1 11/26/26, 19:24 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/115607

  5. Benni Mack marked it ready for review 11/26/26, 19:24