Documentation corrections.

This commit is contained in:
Dave Shawley 2015-09-14 07:48:00 -04:00
parent 5c0b5b239c
commit f72a1a665d
2 changed files with 9 additions and 5 deletions

View file

@ -23,10 +23,10 @@ Tornado Application JSON Logging
-------------------------------- --------------------------------
If you're looking to log Tornado requests as JSON, the If you're looking to log Tornado requests as JSON, the
:class:`sprockets.logging.JSONRequestFormatter` class works in conjunction with :class:`sprockets.logging.JSONRequestFormatter` class works in conjunction with
the :method:`tornado_log_function` method to output all Tornado log entries as the :func:`tornado_log_function` method to output all Tornado log entries as
JSON objects. In the following example, the dictionary-based configuration is JSON objects. In the following example, the dictionary-based configuration is
expanded upon to include specify the :class:`sprockets.logging.JSONRequestFormatter` expanded upon to include specify the :class:`sprockets.logging.JSONRequestFormatter`
as the formatter and passes :method:`tornado_log_function` in as the ``log_function`` as the formatter and passes :func:`tornado_log_function` in as the ``log_function``
when creating the Tornado application. when creating the Tornado application.
.. literalinclude:: ../examples/tornado-json-logger.py .. literalinclude:: ../examples/tornado-json-logger.py

View file

@ -17,19 +17,23 @@ Version History
`1.1.0`_ Jun 18, 2015 `1.1.0`_ Jun 18, 2015
--------------------- ---------------------
- Added :class:`sprockets.logging.JSONRequestFormatter` - Added :class:`sprockets.logging.JSONRequestFormatter`
- Added :method:`sprockets.logging.tornado_log_function` - Added :func:`sprockets.logging.tornado_log_function`
- Added convenience constants and methods as a pass through to Python's logging package: - Added convenience constants and methods as a pass through to Python's logging package:
- :data:`sprockets.logging.DEBUG` to :data:`logging.DEBUG` - :data:`sprockets.logging.DEBUG` to :data:`logging.DEBUG`
- :data:`sprockets.logging.ERROR` to :data:`logging.ERROR` - :data:`sprockets.logging.ERROR` to :data:`logging.ERROR`
- :data:`sprockets.logging.INFO` to :data:`logging.INFO` - :data:`sprockets.logging.INFO` to :data:`logging.INFO`
- :data:`sprockets.logging.WARN` to :data:`logging.WARN` - :data:`sprockets.logging.WARN` to :data:`logging.WARN`
- :data:`sprockets.logging.WARNING` to :data:`logging.WARNING` - :data:`sprockets.logging.WARNING` to :data:`logging.WARNING`
- :method:`sprockets.logging.dictConfig` to :method:`logging.config.dictConfig` - :func:`sprockets.logging.dictConfig` to :func:`logging.config.dictConfig`
- :method:`sprockets.logging.getLogger` to :method:`logging.getLogger` - :func:`sprockets.logging.getLogger` to :func:`logging.getLogger`
`1.0.0`_ Jun 09, 2015 `1.0.0`_ Jun 09, 2015
--------------------- ---------------------
- Added :class:`sprockets.logging.ContextFilter` - Added :class:`sprockets.logging.ContextFilter`
.. _1.3.0: https://github.com/sprockets/sprockets.logging/compare/1.2.1...1.3.0
.. _1.2.1: https://github.com/sprockets/sprockets.logging/compare/1.2.0...1.2.1
.. _1.2.0: https://github.com/sprockets/sprockets.logging/compare/1.1.0...1.2.0
.. _1.1.0: https://github.com/sprockets/sprockets.logging/compare/1.0.0...1.1.0 .. _1.1.0: https://github.com/sprockets/sprockets.logging/compare/1.0.0...1.1.0
.. _1.0.0: https://github.com/sprockets/sprockets.logging/compare/0.0.0...1.0.0 .. _1.0.0: https://github.com/sprockets/sprockets.logging/compare/0.0.0...1.0.0