Review main Ready for review Stale

93323[FEATURE] Introduce AfterHistoryDataCollectedForRecordEvent in RecordHistory

Amir Arends CR -1 V 0 Normal +190 −0 updated 09/15/26, 20:58

Commit message

Introduce a PSR-14 event AfterHistoryDataCollectedForRecordEvent dispatched at the end of RecordHistory::getHistoryDataForRecord(). The event allows listeners to augment history data with additional related records, providing a clean extension point without requiring Xclass overrides.

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

Review

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

Merge conflicts 1

Issues 1

Files 3

Review log 46

  1. Amir Arends uploaded patch set 1 03/24/26, 07:59

  2. Amir Arends uploaded patch set 2 03/24/26, 08:09

  3. core-ci voted on patch set 2 V +1 03/24/26, 08:23 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/98544

  4. core-ci voted on patch set 1 V +1 03/24/26, 08:36 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/98540

  5. Garvin Hicking commented on patch set 2 CR -1 03/24/26, 08:46

    Thanks a lot for contributing this! However, I think we should not monkeypatch one singular PSR-14 event for this, but rather see the bigger scope, and think about where else we would logically need dispatches: - Before Persisting data - After accessing persisted data - After modifying/deleting persisted data - Before/after undo/restore Basically, all RecordHistoryStore methods. Generally I think more data evaluation would need to be moved from RecordHistory to RecordHistoryStore, because we have repository methods in there that don't logically fit there. This would require deprecations and breaking changes. So IMO we should not open that floodgate at this point which would not allow us to do these moves, when we introduce PSR-14 events like this.
  6. Benni Mack commented on patch set 2 09/15/26, 20:58

    Reply Unresolved

    good point. Amir, any chances we can make Core part better (using objects instead of a nested array) or add features you want to add?