Browse Source

attach context with span to *http.Request

bergquist 8 years ago
parent
commit
d55b49b7b7
1 changed files with 1 additions and 1 deletions
  1. 1 1
      pkg/middleware/request_tracing.go

+ 1 - 1
pkg/middleware/request_tracing.go

@@ -22,7 +22,7 @@ func RequestTracing() macaron.Handler {
 		defer span.Finish()
 
 		ctx := opentracing.ContextWithSpan(req.Context(), span)
-		req = req.WithContext(ctx)
+		c.Req.Request = req.WithContext(ctx)
 
 		c.Next()