Skip to content

Remove an unneeded logging article #8770

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 5 commits into from
Closed
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 0 additions & 1 deletion logging.rst
Original file line number Diff line number Diff line change
Expand Up @@ -343,7 +343,6 @@ Learn more
logging/processors
logging/monolog_regex_based_excludes
logging/monolog_console
logging/disable_microsecond_precision

.. _Monolog: https://github.com/Seldaek/monolog
.. _LoggerInterface: https://github.com/php-fig/log/blob/master/Psr/Log/LoggerInterface.php
Expand Down
42 changes: 0 additions & 42 deletions logging/disable_microsecond_precision.rst

This file was deleted.

13 changes: 12 additions & 1 deletion reference/configuration/monolog.rst
Original file line number Diff line number Diff line change
Expand Up @@ -74,6 +74,11 @@ Full Default Configuration
id: ~ # Required (when the email_prototype is used)
method: ~
formatter: ~
# Setting this parameter to false forces the logger to reduce
# the precision in the datetime field of the log messages from
# microsecond to second. Avoiding a call to the microtime(true)
# function and the subsequent parsing.
use_microseconds: true
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree! This is a little long :). How about:

Set to false to use seconds (instead of microseconds) in the logs (gives a small performance boost)


.. code-block:: xml

Expand All @@ -86,7 +91,13 @@ Full Default Configuration
http://symfony.com/schema/dic/monolog
http://symfony.com/schema/dic/monolog/monolog-1.0.xsd">

<monolog:config>
<!-- By default, use-microseconds is set to true
including 'use-microseconds="false' forces
the logger to reduce the precision in the
datetime field of the log messages from
microsecond to second. Avoiding a call to the
microtime(true) function and the subsequent parsing. -->
<monolog:config use-microseconds="true">
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No need to put the comments in XML also. We typically just put the comments in YAML - it's the most visible and avoids duplication :)

<monolog:handler
name="syslog"
type="stream"
Expand Down