From 7988810fc03780a06732336480f59c2cd5fdb7fe Mon Sep 17 00:00:00 2001 From: Agniva De Sarker Date: Fri, 28 Jan 2022 12:47:46 +0530 Subject: [PATCH] Disable sentry tracing completely (#19410) We don't do instrumentation of Sentry transactions anywhere in the code. Only opentracing code is present. One has to explicitly add custom instrumentation for it to work: https://docs.sentry.io/platforms/go/performance/instrumentation/custom-instrumentation/ It's likely someone is running custom code and sending transaction data to Sentry. It's not super hard to pick off the sentry DSN string from the binary. The PR is more of a best effort to stop any future transaction events to be sent. ```release-note NONE ``` --- app/server.go | 3 +++ 1 file changed, 3 insertions(+) diff --git a/app/server.go b/app/server.go index 8776a1922e..d21f0a1212 100644 --- a/app/server.go +++ b/app/server.go @@ -343,6 +343,9 @@ func NewServer(options ...Option) (*Server, error) { } return event }, + TracesSampler: sentry.TracesSamplerFunc(func(ctx sentry.SamplingContext) sentry.Sampled { + return sentry.SampledFalse + }), }); err2 != nil { mlog.Warn("Sentry could not be initiated, probably bad DSN?", mlog.Err(err2)) }