trace: Migrate to sentry-go
Created by: keegancsmith
raven-go has been deprecated for a while. This migrates us to the blessed
package for sending events to Sentry. It works in a strange way for Go were it
seems to simulate goroutine local storage. Notice that the ConfigureScope
and CaptureException
functions both do not rely on any sort of
context
. There doesn't seem to be any alternatives which work with less
magic :(
Additionally sentry-go always does some work, even if a request doesn't report
an exception. It will always clone a hub
for a request, and will always
create a sentry.Request
(with a copy of headers).
This commit also I removes the reportError
function from handlerutil. It
didn't seem to get used in practice (our production sentry has no hits for the
tags it sets).
Additionally we move some "tags" to "extras". Tags are better suited for low cardinality values (the values have stats calculated on them).
Finally I improve the initialization such that we only configure sentry if sentry related configuration changes.
Part of https://github.com/sourcegraph/sourcegraph/issues/6738