Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

nrzerologplugin: Plugin to support logs in context for Zerolog #294

Closed
wants to merge 1 commit into from

Commits on Apr 14, 2021

  1. nrzerologplugin: Plugin to support logs in context for Zerolog

    This commit adds a integration to enable logs-in-context for zerolog,
    this integrarion is split into two parts:
    * HTTP middleware: adds the "LinkingMetadata" into the logger's
    context.
    * Zerolog Hook: Adds the caller's information to the logs.
    
    Caveats:
    * We cannot get the timestamp from zerolog, so we use time.Now.
    * Reading the filename and line depend on some internals of zerolog.
    belimawr committed Apr 14, 2021
    Configuration menu
    Copy the full SHA
    47645f2 View commit details
    Browse the repository at this point in the history