Review main Ready for review Quiet

89993[TASK] Configure selectFields in RecordsXmlSitemapDataProvider

Georg Ringer CR 0 V 0 Hard +311 −2 updated 11/03/26, 20:07

Commit message

To avoid performance issues with tables having many columns, it is now
possible to define the selectFields using:

`plugin.tx_seo.config.xmlSitemap.sitemaps.mySitemap.config.selectFields
= uid,pid,tstamp`.

The fallback value is still `*`.

Fields the sitemap generation relies on are always selected in
addition: uid, pid, language and system fields of the TCA ctrl
section, the last modified, change frequency and priority fields and
all fields used in url.fieldToParameterMap. For workspace aware tables
t3ver_oid and t3ver_state are selected as well.

Records are now overlaid with their workspace version via
PageRepository->versionOL() before the sitemap entries are built.

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 13
git fetch https://review.typo3.org/Packages/TYPO3.CMS refs/changes/93/89993/13 && git checkout FETCH_HEAD
Cherry-pick onto main
git fetch https://review.typo3.org/Packages/TYPO3.CMS refs/changes/93/89993/13 && 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 1

Issues 1

Files 6

Review log 4052

Show 2227 earlier messages
  1. Georg Ringer uploaded patch set 1 07/06/25, 08:17

  2. Georg Ringer commented on patch set 1 07/06/25, 08:18

    This change is ready for review.
  3. core-ci voted on patch set 1 V +1 07/06/25, 08:25 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/81358

  4. Garvin Hicking commented on patch set 1 CR +1 V +1 07/29/25, 06:29

    we would need a docs PR to be able to document this. I think having this a task instead of feature is fair given the scope.
  5. Garvin Hicking commented on patch set 1 09/18/25, 18:52

    bump?
  6. Andreas Kienast voted on patch set 1 CR +1 V +1 09/19/25, 08:48

  7. Oli Bartsch commented on patch set 1 09/19/25, 09:20

    I think this might be a feature. However I'm fine with TASK for the time being but please let's add at least a Important.rst to document the new config option.
  8. Oli Bartsch uploaded patch set 2 CR +1 V +1 09/22/25, 20:09

  9. Oli Bartsch commented on patch set 2 CR +1 V +1 09/22/25, 20:10

    Reply

    Done
  10. Oli Bartsch uploaded patch set 3 CR +1 V +1 09/22/25, 20:13

  11. Oli Bartsch voted on patch set 3 CR +1 V +1 09/22/25, 20:13

  12. core-ci voted on patch set 2 V +1 09/22/25, 20:17 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/85346

  13. Georg Ringer voted on patch set 3 CR +1 V +1 09/22/25, 20:19

  14. core-ci voted on patch set 3 V +1 09/22/25, 20:20 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/85347

  15. Garvin Hicking voted on patch set 3 CR +1 V +1 09/23/25, 05:11

  16. Benni Mack commented on patch set 3 09/23/25, 05:44

    RecordsXmlSitemapDataProvider.php:66

    don't we need to do a explode on this?
  17. Guido Schmechel commented on patch set 3 09/23/25, 06:44

    RecordsXmlSitemapDataProvider.php:66 Reply

    Good point. We could use trimExplode for reasons, in case someone saves fields with spaces. It should be more intuitive. I'll test it later.
  18. Garvin Hicking voted on patch set 3 CR 0 V 0 09/24/25, 07:04

  19. Oli Bartsch uploaded patch set 4 CR +1 V +1 09/24/25, 07:15

  20. Oli Bartsch commented on patch set 4 CR +1 V +1 09/24/25, 07:15

    RecordsXmlSitemapDataProvider.php:66 Reply

    Done
  21. core-ci voted on patch set 4 V +1 09/24/25, 07:22 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/85431

  22. Oli Bartsch commented on patch set 4 CR 0 V 0 09/24/25, 07:29

    I think we should check this in more detail. Also add some test to ensure this is working as expected and no injection is possible.
  23. Garvin Hicking commented on patch set 4 CR -1 09/24/25, 07:31

    RecordsXmlSitemapDataProvider.php:102

    This should be an array-spread to string actually ```suggestion $queryBuilder->select(...$selectFields) ``` ? Then we also would need to do `$selectFields = ['*']` though, so that the spread properly works... (identifier quoting will be applied by that method, trimExplode() wouldn't need it) I think we should cover this functionality with a test, it's odd that this does not create failures. Or the failure is my brain, in which case I'd be happily corrected :D
  24. Guido Schmechel commented on patch set 4 01/10/26, 16:30

    Ping :-)
  25. Benni Mack wrote 04/21/26, 14:57

    Removed cc Benni Mack.
  26. Benni Mack updated the commit message in patch set 5 CR -1 V +1 04/22/26, 06:48

  27. core-ci voted on patch set 5 V -1 04/22/26, 11:28 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/100802

  1. Simon Schaufelberger uploaded patch set 6 V -1 07/10/26, 21:04

  2. Simon Schaufelberger uploaded patch set 7 07/10/26, 21:07

  3. core-ci voted on patch set 7 V -1 07/10/26, 21:20 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/104645

  4. Simon Schaufelberger rebased onto patch set 8 V -1 07/17/26, 15:01

  5. core-ci voted on patch set 8 V -1 07/17/26, 15:19 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/104893

  6. Georg Ringer uploaded patch set 9 V -1 09/01/26, 19:14

  7. core-ci voted on patch set 9 V +1 09/01/26, 19:24 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/107506

  8. Garvin Hicking commented on patch set 9 CR +1 V +1 09/02/26, 09:31

    RecordsXmlSitemapDataProvider.php:102 Reply

    Done
  9. Benni Mack commented on patch set 9 09/02/26, 12:19

    Reply

    @bo@cedev.de what exactly should we check in more detail? We can add tests, ofc - but anything else?
  10. Oli Bartsch commented on patch set 9 09/02/26, 21:16

    Reply

    tbh, my comment is nearly a year old, I don't remember and also don't see injection possibilities.
  11. Simon Schaufelberger voted on patch set 9 CR +1 V +1 09/03/26, 14:42

  12. Stefan Bürk voted on patch set 9 CR -2 09/04/26, 12:31

  13. Stefan Bürk commented on patch set 9 09/04/26, 12:38

    RecordsXmlSitemapDataProvider.php:72

    Sorry, but we should ensure that at least absolutly mandantory fields are always selected (not duplicated): * `uid` * `pid` * (enabled fields based on tca) * language field (if table is language aware) / language parent and similar * disabled field (aka hidden) * slug (configured slug field) ... * (possibly type field if type feature is enabled/used) .... * access fields (`fe_user/group thingy`) ... there may be more specific must have fields for tables we do not know, but at least bare minimum fields for link generation. I would really not want to leave the must Or am I wrong here ?
  14. Stefan Bürk voted on patch set 9 CR -1 09/04/26, 13:16

  15. Georg Ringer uploaded patch set 10 CR +1 V +1 09/05/26, 06:59

  16. core-ci voted on patch set 10 V +1 09/05/26, 07:07 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/107929

  17. Georg Ringer rebased onto patch set 11 V +1 09/22/26, 17:40

  18. core-ci voted on patch set 11 V -1 09/22/26, 17:56 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/109001

  19. Georg Ringer rebased onto patch set 12 V -1 09/23/26, 15:49

  20. core-ci voted on patch set 12 V +1 09/23/26, 16:31 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/109082

  21. Benni Mack commented on patch set 12 09/30/26, 13:29

    RecordsXmlSitemapDataProvider.php:153

    we also include Workspace Fields, also, we don't do WS overlays anymore - so we should actually consider the pageRepository->versionOL()
  22. Georg Ringer uploaded patch set 13 V +1 11/03/26, 19:59

  23. Georg Ringer commented on patch set 13 11/03/26, 19:59

    RecordsXmlSitemapDataProvider.php:153 Reply

    Done
  24. Georg Ringer commented on patch set 13 11/03/26, 19:59

    RecordsXmlSitemapDataProvider.php:72 Reply

    Done
  25. core-ci voted on patch set 13 V +1 11/03/26, 20:07 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/113215