Capturing HTTP headers in java agent #4733
-
Hi, I would like to capture some HTTP server request headers, e.g. x-bussiness-user. But, when I configured java agent with parameter: -Dotel.instrumentation.common.experimental.capture-http-headers.server.request=http.request.header.x_business_user=[""], In result, I can't see that agent is capturing header. I'm using agent in version 1.7.2. Where I have problem please? Thank you |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 2 replies
-
Hey @stanosamek, |
Beta Was this translation helpful? Give feedback.
Hey @stanosamek,
Try using
-Dotel.instrumentation.common.experimental.capture-http-headers.server.request=x-business-user
(or-Dotel.instrumentation.http.capture-headers.server.request=x-business-user
if you decide to upgrade to agent 1.9.0) instead. This configuration option accepts a comma-separated list of header names -- not the span attribute names.