Go's Built-in Package for Better Logging (using slog)

Поделиться
HTML-код
  • Опубликовано: 24 ноя 2024

Комментарии • 10

  • @siya.abc123
    @siya.abc123 5 дней назад +1

    Super underrated channel, I'm glad I'm here before you blow up!

  • @nathaaaaaa
    @nathaaaaaa 3 дня назад +1

    Ok thats awesome. Any way to define which context properties should be passed as well? Like a request id?

  • @KhairulHidayat
    @KhairulHidayat 4 дня назад

    I love go

  • @alexbrik1802
    @alexbrik1802 4 дня назад

    Love Go Slog. Btw, how do you format JSON in the terminal? Don't see jq command

    • @betterstack
      @betterstack  3 дня назад

      For the sake of the video, I actually just aliased the go run command to be piped through jq. Made it better to present
      - James

    • @alexbrik1802
      @alexbrik1802 3 дня назад

      @ got it. Thanks 🙏 I thought it was some terminal plugin or something

  • @MasarJuraj
    @MasarJuraj 5 дней назад

    🔥🔥

  • @maciejszarat9408
    @maciejszarat9408 4 дня назад +1

    Can you show how to pass the logs to betterstack pls?

    • @betterstack
      @betterstack  3 дня назад +1

      You can find our documentation here, should have examples of most use cases: betterstack.com/docs/logs/start/
      What language are you using? We also have a few videos on this channel that will guide you through it. One example is getting setup with the OpenTelemetry collector and using that to forward your logs!
      - James

    • @maciejszarat9408
      @maciejszarat9408 3 дня назад

      @ thanks a lot!