Review main Merged

82073[FEATURE] FE cache information request attribute

Christian Kuhn CR +2 V +2 Hard +283 −185 updated 12/10/23, 07:40

Commit message

Refactor TSFE->no_cache towards the new Request
attribute 'frontend.cache.instruction': This
attribute can be created by middlewares early
when they need to disable cache mechanics of
middlewares later in the stack.

The new construct *requires* a reason when caching
is disabled, and the disable instruction can be set
by multiple middlewares which can result in multiple
reasons being gathered. The admin panel now lists
any "cache has been disabled" reasons.

Review

  • Code review CR +2 Done
    • Christian Kuhn +2
    • Oli Bartsch +1
    • Sascha Nowak +1
    • Benni Mack +1
  • Verified V +2 Done
    • Christian Kuhn +2
    • Oli Bartsch +1
    • Benni Mack +1
    • core-ci +1 CI

Issues 1

Files 25

Show 5 more files

Review log 2333

Show 58 earlier messages
  1. Christian Kuhn uploaded patch set 1 12/03/23, 09:51

  2. core-ci voted on patch set 1 V +1 12/03/23, 09:57 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/50270

  3. Christian Kuhn uploaded patch set 2 V +1 12/03/23, 11:27

  4. core-ci voted on patch set 2 V +1 12/03/23, 11:34 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/50274

  5. Christian Kuhn uploaded patch set 3 V +1 12/03/23, 12:12

  6. core-ci voted on patch set 3 V +1 12/03/23, 12:17 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/50275

  7. Benni Mack commented on patch set 3 12/04/23, 11:53

    CacheInformationRequestAttribute.php:23

    In general I like the patch, however, I'm not 100% sure with the naming. It's not just an "information" but actually an instruction or directive of the request to avoid using the page cache (and TypoScript cache, depending on the place where it is set).
  8. Christian Kuhn uploaded patch set 4 V +1 12/07/23, 15:19

  1. Christian Kuhn commented on patch set 4 12/07/23, 15:23

    CacheInformationRequestAttribute.php:23 Reply

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

  3. Christian Kuhn uploaded patch set 5 V +1 12/07/23, 15:46

  4. Christian Kuhn commented on patch set 5 12/07/23, 15:47

    CacheInformationRequestAttribute.php:23 Reply

    note the page cache identifier (which currently runs under the awful name "newHash") will most likely be part of that attribute as well, and only used by a different attribute later thaht
  5. core-ci voted on patch set 5 V +1 12/07/23, 15:51 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/50461

  6. Christian Kuhn uploaded patch set 6 V +1 12/07/23, 16:10

  7. core-ci voted on patch set 6 V +1 12/07/23, 16:15 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/50462

  8. Christian Kuhn uploaded patch set 7 V +1 12/07/23, 16:17

  9. Christian Kuhn commented on patch set 7 12/07/23, 16:18

    benni requested renaming from CacheInstructionRequestAttribute to CacheInstruction.
  10. core-ci voted on patch set 7 V +1 12/07/23, 16:23 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/50463

  11. Christian Kuhn uploaded patch set 8 V +1 12/08/23, 10:45

  12. Christian Kuhn updated the commit message in patch set 9 12/08/23, 10:46

  13. core-ci voted on patch set 9 V +1 12/08/23, 10:52 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/50486

  14. core-ci voted on patch set 8 V +1 12/08/23, 10:53 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/50485

  15. Sascha Nowak commented on patch set 9 CR +1 12/08/23, 11:23

    Feature-102628-CacheInstructionMiddleware.rst:25

    Could we add an Example here how to use it. Personally I as a developer was searching for there files and love to copy an example as a starting point: $cacheInstruction = $request->getAttribute('frontend.cache.instruction', new CacheInstruction()); $cacheInstruction->disableCache('EXT:mxext: Add reason here why you disables the cache.');
  16. Christian Kuhn uploaded patch set 10 CR +1 V +1 12/08/23, 11:54

  17. Christian Kuhn commented on patch set 9 12/08/23, 11:54

    Feature-102628-CacheInstructionMiddleware.rst:25 Reply

    Done
  18. Sascha Nowak voted on patch set 10 CR +1 12/08/23, 11:57

  19. Benni Mack voted on patch set 10 CR +1 V +1 12/08/23, 11:58

  20. core-ci voted on patch set 10 V +1 12/08/23, 12:01 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/50492

  21. Oli Bartsch voted on patch set 10 CR +1 V +1 12/08/23, 16:15

  22. Christian Kuhn voted on patch set 10 CR +2 V +2 12/09/23, 10:16

  23. Christian Kuhn merged patch set 11 12/09/23, 10:16

  24. Simon Schaufelberger commented on patch set 11 12/09/23, 11:04

    WorkspacePreview.php:122

    to be consistent, "Ext" should be used like all other other places.
  25. Christian Kuhn commented on patch set 11 12/10/23, 07:40

    WorkspacePreview.php:122 Reply

    changing as drive-by with another patch.