Review main Merged

70849[FEATURE] Support PHP 8 style Channel attribute for logger injection

Benjamin Franzke CR +2 V +2 Normal +178 −2 updated 09/03/21, 15:50

Commit message

Services are now able to control the component name that an
injected logger is created with.
This allows to group logs of related classes and is basically
a channel system as often used in monolog.

Therefore and as preparation for future monolog logging,
the attribute is named Channel.

The Channel attribute is supported for constructor argument
injection as a class and parameter specific attribute and for
LoggerAwareInterface dependency injection services as a class attribute.

This feature is only available with PHP 8.
The channel attribute will be gracefully ignored in PHP 7,
and the classic component name will be used instead.

Review

  • Code review CR +2 Done
    • Benjamin Franzke +2
    • Nikita Hovratov +1
    • Benni Mack +1
  • Verified V +2 Done
    • Benjamin Franzke +2
    • Nikita Hovratov +1
    • Benni Mack +1
    • core-ci +1 CI

Issues 2

Files 4

Review log 1319

  1. Benjamin Franzke uploaded patch set 1 08/31/21, 20:18

  2. core-ci voted on patch set 1 V +1 08/31/21, 20:37 Core CI is happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/15968

  3. Benjamin Franzke uploaded patch set 2 09/02/21, 13:06

  4. core-ci voted on patch set 2 V +1 09/02/21, 13:19 Core CI is happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/16081

  5. Benjamin Franzke rebased onto patch set 3 09/02/21, 21:27

  6. core-ci voted on patch set 3 V +1 09/02/21, 21:48 Core CI is happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/16139

  7. Benjamin Franzke uploaded patch set 4 09/03/21, 09:00

    Rebase
  8. core-ci commented on patch set 4 09/03/21, 09:19 Core CI is happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/16157

  9. Benni Mack voted on patch set 4 V +1 CR +1 09/03/21, 10:56

  10. Nikita Hovratov commented on patch set 4 09/03/21, 13:51

    LoggerAwarePass.php:61

    Is this right? $channel will only be assigned if it's null.
  11. Benjamin Franzke uploaded patch set 5 09/03/21, 14:01

  12. Benjamin Franzke commented on patch set 5 09/03/21, 14:01

    LoggerAwarePass.php:61 Reply

    Ack, that was wrong.
  13. core-ci voted on patch set 5 V +1 09/03/21, 14:23 Core CI is happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/16188

  14. Nikita Hovratov uploaded patch set 6 09/03/21, 14:37

  15. Nikita Hovratov voted on patch set 6 V +1 CR +1 09/03/21, 14:39

  16. core-ci voted on patch set 6 V +1 09/03/21, 14:55 Core CI is happy: https://gitlab.typo3.org/typo3/CI/cms/-/pipelines/16194

  17. Benni Mack voted on patch set 6 V +1 CR +1 09/03/21, 15:12

  18. Benjamin Franzke voted on patch set 6 V +2 CR +2 09/03/21, 15:49

  19. Benjamin Franzke merged patch set 7 09/03/21, 15:50