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

Data race fix for context slog.Logger #1193

Closed
wants to merge 5 commits into from
Closed

Commits on Sep 22, 2024

  1. Add failing test for race

    See tus#1192
    
    This adds a mock slog Logger to create a data race issue.
    Run go test -race to trigger
    wongak committed Sep 22, 2024
    Configuration menu
    Copy the full SHA
    e9786ba View commit details
    Browse the repository at this point in the history
  2. Fix data race related to slog Logger

    This fix adds two possible solutions to the data race issue.
    
    We either add the "id" info manually when logging, or we create a
    function-scoped logger based on the initial logger. The context logger
    must not be mutated.
    wongak committed Sep 22, 2024
    Configuration menu
    Copy the full SHA
    085dbcc View commit details
    Browse the repository at this point in the history

Commits on Oct 4, 2024

  1. Configuration menu
    Copy the full SHA
    c7aece8 View commit details
    Browse the repository at this point in the history
  2. Revert "Fix data race related to slog Logger"

    This reverts commit 085dbcc.
    Acconut committed Oct 4, 2024
    Configuration menu
    Copy the full SHA
    85ea4a5 View commit details
    Browse the repository at this point in the history

Commits on Oct 8, 2024

  1. Configuration menu
    Copy the full SHA
    fdcda27 View commit details
    Browse the repository at this point in the history