Skip to content

Commit 67f8c2c

Browse files
author
Denis Brumann
committed
Adds documentation for monolog processors.
Adds both a short description for existing processors as well as a note for the newly added TokenProcessor added in 3.4. Replaces #8156
1 parent 9f6ad6c commit 67f8c2c

File tree

1 file changed

+10
-0
lines changed

1 file changed

+10
-0
lines changed

logging/processors.rst

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -160,6 +160,16 @@ If you use several handlers, you can also register a processor at the
160160
handler level or at the channel level instead of registering it globally
161161
(see the following sections).
162162

163+
Symfony's MonologBridge provides processors that can be registered inside your application.
164+
165+
* :class:`Symfony\\Bridge\\Monolog\\Processor\\DebugProcessor` adds additional information useful for debugging like a timestamp or an error message to the record.
166+
* :class:`Symfony\\Bridge\\Monolog\\Processor\\TokenProcessor` adds information from the current user's token to the record namely username, roles and whether the user is authenticated.
167+
* :class:`Symfony\\Bridge\\Monolog\\Processor\\WebProcessor` overrides data from the request using the data inside Symfony's request object.
168+
169+
.. versionadded:: 3.4
170+
171+
The :class:`Symfony\\Bridge\\Monolog\\Processor\\TokenProcessor` class was added in Symfony 3.4.
172+
163173
Registering Processors per Handler
164174
----------------------------------
165175

0 commit comments

Comments
 (0)