szemul/logging-error-handling-context

Provides an error handler and logging context to manage contextual data to be injected into errors and log messages.

1.0.0 2022-09-10 04:41 UTC

This package is auto-updated.

Last update: 2024-04-10 08:06:05 UTC


README

CI pipeline codecov

Provides an error handler and logging context to manage contextual data to be injected into errors and log messages.

Context

The context is useful for storing values used to enrich logs and errors. The context class supports switching contexts. When adding a new context, the existing values are preserved, and you can switch back to any previous context and recover the state (switching back drops any changes in any newer context).