Skip to content
Sander Maijers edited this page Nov 6, 2017 · 28 revisions

Major changes overview

  • Unified and simplified logging macros structure and ordering.
  • Added logging Record tags
  • Refactored key-value pairs under KV trait
  • Support chaining of OwnedKVLists. Existing Logger can be used as a Drain to allow custom handling logic for a part of the logging hierarchy.
  • Added associated Ok type to Drain.
  • Support for Drains unwind safety.
  • Refactored Record to optimize performance on async operations.
  • slog-extra has been renamed to slog-async since that's the only functionality it contained.
  • slog-stream is obsoleted and won't be used in slog v2 at all. It was a wrong abstraction. Decorators functionality was moved to slog-term.
  • slog-term provides open Decorator traits to allow multiple terminal / file writing backends.
  • slog-term default Decorators use term crate and should work correctly on all supported OSes.
  • DrainExt has been removed and utility methods moved directly to Drain
  • slog-stdlog utilizes slog-scope directly.
  • Support for "typed" Loggers to allow squeezing last drops of performance possible, at the ergonomic cost of T in Logger<T>.

Status

Core slog v2 crate is stable. Majority of core feature crates are ready and working, and will have stable releases after getting more confidence in their APIs.

Your feedback and opinions can speed up the stabilization process.

Per-crate status

This list might not be up to date. Feel free to edit.

# still need porting to v2
slog-cadence
slog-html
slog-example-lib
# obsoleted
slog-extra - contained just `async` so is not `slog-async`
slog-stream - use `Decorator` in slog-term instead
slog-serde - wasn't useful enough
slog-scope-stdlog - use slog-scope instead