Migrating SetDefaultLoggerName() from raven-go to sentry-go

The migration guide to go from raven-go to sentry-go is here:

It includes a section documenting how to use sentry.Init() with various ClientOptions to implement the same behavior in sentry-go as raven-go. However, there doesn’t appear to be any mapping for SetDefaultLoggerName().

I’ll be honest, I am not really sure exactly how SetDefaultLoggerName() works, and the documentation is pretty lean. Even reading the code didn’t provide me too much insight.

I was thinking of using SetExtra('logger', ...) on the Scope or something like that to get similar behavior, but I’m not really sure this is the best approach.

Can someone clue me in? :smile:

It turns out that SetDefaultLoggerName() is just not available in sentry-go. Sentry customer support recommended using a tag, which is what I’ve done in my use case.

I also submitted a PR against the documentation so that the next person doesn’t struggle with this.

This topic was automatically closed 15 days after the last reply. New replies are no longer allowed.