Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Configurable client identification headers and/or base Otel attributes #798

Open
wainglaister opened this issue May 17, 2024 · 2 comments
Open
Labels
enhancement New feature or request internally-reviewed The issue has been reviewed internally.

Comments

@wainglaister
Copy link

Component(s)

router

Is your feature request related to a problem? Please describe.

I'm looking at a migration to using router and I have a number of currently used custom headers to deal with, this includes client name, version and referrer.

Describe the solution you'd like

Initially I was thinking that the config.yaml could include settings for custom header keys which would override the defaults, but that would only solve part of the problem (it could well cater for a good % of people).

Ideally the custom module needs access to more of the lifecycle, NewClientInfoFromRequest is called before Middleware so the request can't be updated (which would be a hack anyway). Really access is required to baseAttributeValues so that arbitrary details can be added to all spans (the module should have access to all steps that create a span...).

Describe alternatives you've considered

Using a custom module to store the custom headers and inject them on the available spans for each request (covers only a small subset of the spans).

There are a lot of interfaces used in the codebase, but almost no way to supply an implementation to be used (that I'm aware of) (nice and general, high effort).

Add custom module callbacks for any stage where a span is created (not all in the router so not so easy.

Additional context

Thinking to the future I'm interested in how this all applies to subscriptions / web sockets

@wainglaister wainglaister added the enhancement New feature or request label May 17, 2024
Copy link

WunderGraph commits fully to Open Source and we want to make sure that we can help you as fast as possible.
The roadmap is driven by our customers and we have to prioritize issues that are important to them.
You can influence the priority by becoming a customer. Please contact us here.

@jensneuse jensneuse added the internally-reviewed The issue has been reviewed internally. label May 21, 2024
@jensneuse
Copy link
Member

We need this for a customer and are looking at implementing it in a configurable way. Currently, we don't have a specific timeline.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request internally-reviewed The issue has been reviewed internally.
Projects
None yet
Development

No branches or pull requests

2 participants