sentry

package
v1.0.7 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 19, 2023 License: Apache-2.0 Imports: 7 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

View Source
var AdditionalSentryTags = env.GetEnvOrDefault("ADDITIONAL_SENTRY_TAGS", "{}")
View Source
var SampleRate = env.GetEnvAsFloatOrDefault("SENTRY_SAMPLE_RATE", "1.0")
View Source
var SentryDebug = env.GetEnvAsBoolOrDefault("SENTRY_DEBUG", "false")
View Source
var SentryDsn = env.GetEnvOrDefault("SENTRY_DSN", "")
View Source
var SentryEnabled = env.GetEnvAsBoolOrDefault("SENTRY_ENABLED", "false")
View Source
var TracesSampleRate = env.GetEnvAsFloatOrDefault("SENTRY_TRACES_SAMPLE_RATE", "1.0")

Functions

func AutoRecoverWithCapture

func AutoRecoverWithCapture(log *logrus.Entry, message string) error

func MaybeInitSentry

func MaybeInitSentry(options sentry.ClientOptions, hook *SentryLogrusHook)

func RecoverWithCapture

func RecoverWithCapture(log *logrus.Entry, message string, recover interface{}) error

Types

type SentryLogrusHook

type SentryLogrusHook struct {
	// contains filtered or unexported fields
}

func NewDefaultSentryLogrusHook

func NewDefaultSentryLogrusHook() *SentryLogrusHook

func NewSentryLogrusHook

func NewSentryLogrusHook(levels []logrus.Level) *SentryLogrusHook

func (*SentryLogrusHook) Fire

func (s *SentryLogrusHook) Fire(entry *logrus.Entry) error

func (*SentryLogrusHook) Levels

func (s *SentryLogrusHook) Levels() []logrus.Level

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL