Semantic Logger v4.0.0 Release Notes
Release Date: 2017-03-02 // about 7 years ago-
โ Added
- ๐ฒ #backtrace to log the backtrace for a thread.
- ๐ฒ
named_tags
to support hash like tagging of log messages.
๐ Changed
- ๐ Ruby V2.1 is now the minimum runtime version.
- ๐ Switch from Hash arguments to Ruby keyword arguments, for better performance, validation and defaults.
- ๐ฐ Replaced Logger#with_payload with SemanticLogger.named_tagged.
- ๐ฐ Replaced Logger#payload with SemanticLogger.named_tags.
๐ฐ Any payload elements passed into the log line must now be specified in a separate :payload tag.
- For example any occurrences of: ~~~ruby logger.error(message: 'Hello', response: response_message) ~~~
- Must be changed to use the payload tag:
logger.error(message: 'Hello', payload: {response: response_message} )
- Otherwise Ruby will raise the following error:
ArgumentError: unknown keywords: response semantic_logger/lib/semantic_logger/log.rb:65:in `assign'
๐ For JSON and Hash appender format, payload is now in its own :payload tag instead of being merged into the hash.
Text and Color formatters now include named_tags in their output.
โฌ๏ธ MongoDB Appender has been upgraded to support Mongo Ruby Client V2.
Replaced hash arguments with keyword arguments.
- For example, the Bugsnag Appender now only accepts the level as follows: ๐ ~~~ruby SemanticLogger::Appender::Bugsnag.new(level: :info) ~~~
๐ Fixed
- ๐ป Graylog appender when logger is called with only an exception object.
- ๐ During a backtrace dump, include the current thread on Ruby MRI.
โฌ๏ธ Dropped Support for
- ๐ Rails 3.2
- ๐ Ruby 1.9 & 2.0
- ๐ JRuby 1.7