Review main Merged Breaking

81618[!!!][TASK] Streamline File Processing API

Benni Mack CR +2 V +2 Hard +264 −428 updated 11/02/23, 10:04

Commit message

This change the concept of the Processed File API,
which was introduced back in TYPO3 v6 in 2012
(commit #66c204f0bf3e83d302e6a5f9e367ebda267a015e),
and was almost not touched since then.

The "TaskInterface" was hardly extended for purposes
other than "ImagePreview" (BE) and "ImageCropScaleMask" (FE).

In order to accommodate for what is / was useful
in the past years, the TaskInterface's interface
signature was adapted, next to typed methods and arguments,
the method "sanitizeConfiguration" is added,
allowing to reduce logic in the "LocalPreviewHelper".

The AbstractGraphicalTask was removed as it
extended from AbstractTask and had little value
over the concrete implementations, and wasn't even
abstract. The AbstractTask now has two abstract methods
"getName" and "getType" in order to be extended in its
subclasses.

All in all, the main goal for this patch is
to make the structure of this functionality easier
to understand:
* A task holds the configuration of a file
* A ProcessedFile object is the instance of a file that was or is about to be processed file
* A processor can be used to do the actual action

Review

  • Code review CR +2 Done
    • Benni Mack +2
    • Stefan Bürk +1
    • Andreas Kienast +1
  • Verified V +2 Done
    • Benni Mack +2
    • Stefan Bürk +1
    • Andreas Kienast +1
    • core-ci +1 CI

Issues 1

Files 15

Review log 1318

  1. Benni Mack uploaded patch set 1 10/30/23, 20:57

  2. core-ci voted on patch set 1 V -1 10/30/23, 21:12 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/48369

  3. Benni Mack uploaded patch set 2 V -1 10/30/23, 21:34

  4. core-ci voted on patch set 2 V -1 10/30/23, 21:48 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/48370

  5. Benni Mack uploaded patch set 3 V -1 10/31/23, 11:14

  6. core-ci voted on patch set 3 V -1 10/31/23, 11:26 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/48395

  7. Benni Mack uploaded patch set 4 V -1 10/31/23, 11:31

  8. core-ci voted on patch set 4 V +1 10/31/23, 11:38 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/48397

  9. Andreas Kienast commented on patch set 4 10/31/23, 13:03

    ImageCropScaleMaskTask.php:58

    Why is this a hardcoded list in the first place? Also, should we add webp here, since we support it now?

    Breaking-102165-FileAbstractionLayerProcessingAPIsAndInterfaceChanged.rst:43

    ```[...] the :php:`AbstractGraphicalTask` class, [...]```

    Breaking-102165-FileAbstractionLayerProcessingAPIsAndInterfaceChanged.rst:63

    ``` :php:`AbstractTask` ```
  10. Benni Mack commented on patch set 4 10/31/23, 13:07

    ImageCropScaleMaskTask.php:58 Reply

    not yet (in GraphicalFunctions). This will be a separate patch
  11. Benni Mack commented on patch set 5 V +1 10/31/23, 13:08

    Published edit on patch set 4.
  12. Benni Mack commented on patch set 5 10/31/23, 13:08

    ImageCropScaleMaskTask.php:58 Reply

    Done

    Breaking-102165-FileAbstractionLayerProcessingAPIsAndInterfaceChanged.rst:43 Reply

    Done

    Breaking-102165-FileAbstractionLayerProcessingAPIsAndInterfaceChanged.rst:63 Reply

    Done
  13. Andreas Kienast voted on patch set 5 V +1 CR +1 10/31/23, 13:12

  14. core-ci voted on patch set 5 V +1 10/31/23, 13:15 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/48405

  15. Stefan Bürk voted on patch set 5 CR -1 11/02/23, 08:41

  16. Stefan Bürk voted on patch set 5 V +1 CR +1 11/02/23, 09:23

  17. Benni Mack voted on patch set 5 V +2 CR +2 11/02/23, 10:04

  18. Benni Mack merged patch set 6 11/02/23, 10:04