Skip to content

Logger metadata unavailable when using LoggerBackend #336

@thdxr

Description

@thdxr

Currently the recommended way to attach Logger.metadata is via a presend hook that pulls out relevant metadata and attaches it to the event. This works great under normal situations because the presend hook runs in the same process as where the exception occurred, making Logger.metadata accessible.

However when using the LoggerBackend the message is first sent to a gen event process before being turned into a Sentry exception. The presend hook loses access to the original Logger.context.

This is fixable and there's a few ways to do but wanted to get it on the radar as I work on the issue

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions