v0.21.1 Latest Latest

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

Go to latest
Published: Apr 1, 2019 License: GPL-3.0 Imports: 15 Imported by: 0




This section is empty.


This section is empty.


func PanicHunter

func PanicHunter()

PanicHunter catches panic, in case of an enabled reporter.


type Client

type Client struct {
	// contains filtered or unexported fields

Client Bugsnag client object.

func NewClient

func NewClient(
	cfg *Config, db *reform.DB, log Log, version string) (*Client, error)

NewClient initializing Bugsnag client. Bugsnag client that automatic error sender to remote server. We use this service to collect anonymous information about the error and panic. Service is activated if exist entry key = "error.sendremote" and value = true in the database settings table.

func (*Client) Enable

func (c *Client) Enable() bool

Enable returns true if client is enabled.

func (*Client) Notify

func (c *Client) Notify(err error, sync bool, skip int)

Notify takes three arguments: err - standard error; sync - if true then the function waits for the end of sending; skip - how many errors to remove from stacktrace.

func (*Client) PanicIgnore

func (c *Client) PanicIgnore()

PanicIgnore disables the PanicHunter.

type Config

type Config struct {
	ReleaseStage     string
	ExcludedPackages []string
	UserID           string `json:"userid"`

Config Bugsnag client config.

func NewConfig

func NewConfig() *Config

NewConfig generates a new default Bugsnag client Config.

type Log

type Log interface {
	Printf(format string, v ...interface{})
	Reporter(reporter report.Reporter)
	Logger(logger log.Logger)

Log interface for report.

Jump to

Keyboard shortcuts

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