sentry

package
v0.0.0-...-9780dc4 Latest Latest
Warning

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

Go to latest
Published: Jul 13, 2020 License: MIT Imports: 6 Imported by: 0

README

sentry

Middleware to integrate with sentry crash reporting. Middleware version of raven.RecoveryHandler().

EOL-warning

This package has been abandoned on 2017-01-13. Please use gin-contrib/sentry instead.

Example

package main

import (
  "github.com/getsentry/raven-go"
  "github.com/gin-gonic/contrib/sentry"
  "github.com/gin-gonic/gin"
)

func init() {
  raven.SetDSN("https://<key>:<secret>@app.getsentry.com/<project>")
}

func main() {
  r := gin.Default()
  r.Use(sentry.Recovery(raven.DefaultClient, false))
  // ...
  r.Run(":8080")
}

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Recovery

func Recovery(client *raven.Client, onlyCrashes bool) gin.HandlerFunc

Types

This section is empty.

Jump to

Keyboard shortcuts

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