Skip to content
This repository has been archived by the owner on Nov 19, 2019. It is now read-only.
/ sentry Public archive

Middleware to integrate with sentry crash reporting.

License

Notifications You must be signed in to change notification settings

gin-contrib/sentry

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

21 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

sentry

Build Status Go Report Card GoDoc Join the chat at https://gitter.im/gin-gonic/gin


The sentry middleware is no longer maintained and was superseded by the sentry-go SDK. Learn more about the project on GitHub and check out the new gin middleware.


Example

See the example

package main

import (
	"github.com/getsentry/raven-go"
	"github.com/gin-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))
	// only send crash reporting
	// r.Use(sentry.Recovery(raven.DefaultClient, true))
	r.Run(":8080")
}

Releases

No releases published

Packages

No packages published

Languages