feat: use sentry tags instead of context for better observability
All checks were successful
Cadoles/bouncer/pipeline/head This commit looks good
All checks were successful
Cadoles/bouncer/pipeline/head This commit looks good
This commit is contained in:
parent
692523e54f
commit
8b6e75ae77
@ -80,9 +80,10 @@ func (d *Director) rewriteRequest(r *http.Request) (*http.Request, error) {
|
|||||||
r = r.WithContext(proxyCtx)
|
r = r.WithContext(proxyCtx)
|
||||||
|
|
||||||
if sentryScope, _ := SentryScope(ctx); sentryScope != nil {
|
if sentryScope, _ := SentryScope(ctx); sentryScope != nil {
|
||||||
sentryScope.SetContext("bouncer", sentry.Context{
|
sentryScope.SetTags(map[string]string{
|
||||||
"proxy_name": p.Name,
|
"bouncer.proxy.name": string(p.Name),
|
||||||
"proxy_target": r.URL.String(),
|
"bouncer.proxy.target.url": r.URL.String(),
|
||||||
|
"bouncer.proxy.target.host": r.URL.Host,
|
||||||
})
|
})
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user