reporter

package
v0.2.0 Latest Latest
Warning

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

Go to latest
Published: Feb 17, 2026 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Overview

Package reporter wrapper abstracting Sentry.

Index

Constants

This section is empty.

Variables

View Source
var ErrReporterInitializationFail = errors.New("reporter init error")

ErrReporterInitializationFail indicates an error with the report initialization parameters.

Functions

func Initialize

func Initialize(conf *Config) error

Initialize and configures underlying Sentry library.

func Shutdown

func Shutdown()

Shutdown flushes buffered events before the program terminates.

Types

type Config

type Config struct {
	Dsn         string
	Debug       bool
	Release     string
	Environment string
}

Config structure for minimum set of reporter parameters.

type Event

type Event = sentry.Event

Event is the fundamental data structure that is sent to our reporter.

type EventID

type EventID = sentry.EventID

EventID is a hexadecimal string representing a unique uuid4 for an Event. An EventID must be 32 characters long, lowercase and not have any dashes.

func CaptureEvent

func CaptureEvent(e *Event) *EventID

CaptureEvent captures a structured event.

func CaptureException

func CaptureException(err error) *EventID

CaptureException captures an error.

func CaptureMessage

func CaptureMessage(msg string) *EventID

CaptureMessage captures a message.

Jump to

Keyboard shortcuts

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