Open morley92 opened 3 months ago
How possible would it be to add the user agent OTEL attribute to the root span? Ideally user_agent.original
user_agent.original
I was hoping to achieve this by using the attributesFromHeaders function but this seems to have no effect, e.g:
attributesFromHeaders
attributesFromHeaders: { 'user_agent.original': 'User-Agent' }
Reading through the code it seems like user agent is added in certain circumstances but this doesn't appear be included in our spans - see https://github.com/vercel/otel/blob/879fdcbc3ba26437105c1f0ec9b72e1979d8b063/packages/otel/src/vercel-request-context/attributes.ts#L24
We're not hosting with Vercel if that helps.
Thanks
How possible would it be to add the user agent OTEL attribute to the root span? Ideally
user_agent.original
I was hoping to achieve this by using the
attributesFromHeaders
function but this seems to have no effect, e.g:Reading through the code it seems like user agent is added in certain circumstances but this doesn't appear be included in our spans - see https://github.com/vercel/otel/blob/879fdcbc3ba26437105c1f0ec9b72e1979d8b063/packages/otel/src/vercel-request-context/attributes.ts#L24
We're not hosting with Vercel if that helps.
Thanks