Skip to content

Commit ca35570

Browse files
committed
minor #10049 Mention how to inject a specific Monolog service (javiereguiluz)
This PR was merged into the 3.4 branch. Discussion ---------- Mention how to inject a specific Monolog service This replaces #9849 and links to the explanation about how to wire specific services in the container. Commits ------- 391d3e0 Mention how to inject a specific Monolog service
2 parents fe877b9 + 391d3e0 commit ca35570

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

logging/channels_handlers.rst

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -169,5 +169,7 @@ You can also configure additional channels without the need to tag your services
169169
),
170170
));
171171
172-
With this, you can now send log messages to the ``foo`` channel by using
173-
the automatically registered logger service ``monolog.logger.foo``.
172+
Symfony automatically registers one service per channel (in this example, the
173+
channel ``foo`` creates a service called ``monolog.logger.foo``). In order to
174+
inject this service into others, you must update the service configuration to
175+
:ref:`choose the specific service to inject <services-wire-specific-service>`.

0 commit comments

Comments
 (0)