Open terrificsoysauce opened 3 years ago
Hi @terrificsoysauce,
As I think you've realized, the java agent currently only supports downstream HTTP Requests with Apache clients. I would suggest opening this feature request on the disco repo as well since that is where the actual ByteBuddy instrumentation lives. Alternatively, you can checkout the AWS Distro for OpenTelemetry Java agent (docs), which is a ready-to-use OpenTelemetry auto-instrumentation agent that's compatible with the X-Ray backend and supports Spring WebClient.
FR: Support for Spring WebClient
In my sample application using Spring WebClient with X-Ray Java agent auto-instrumentation, the trace header is not injected into the http header.
This is the code block for the downstream http call using Spring webclient
In the downstream http request handler, I printed out the request header and found that no trace id,
2021-03-04 16:19:18.841 INFO [Addition App,604108865e2cf420e5d967d9c6dc0ec3,e5d967d9c6dc0ec3,true] 25 --- [nio-8080-exec-8] c.g.t.s.tracingpoc.AdditionController : Starting to add... x: [100], y: [1000]. RequestHeaders: [{accept-encoding=gzip, user-agent=ReactorNetty/0.9.8.RELEASE, host=<redacted>:8080, accept=*/*}]