chore: exclude health endpoint from sentry tracing

This commit is contained in:
Ferdinand Mütsch 2021-04-10 00:10:16 +02:00
parent 1783858854
commit ae97095688
1 changed files with 1 additions and 1 deletions

View File

@ -311,7 +311,7 @@ func initSentry(config sentryConfig, debug bool) {
hub := sentry.GetHubFromContext(ctx.Span.Context())
txName := hub.Scope().Transaction()
if strings.HasPrefix(txName, "GET /assets") {
if strings.HasPrefix(txName, "GET /assets") || strings.HasPrefix(txName, "GET /api/health") {
return sentry.SampledFalse
}
if txName == "POST /api/heartbeat" {