Skip to content

fix(frontend): reduce cardinality in next.js spans with processor #2190

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

Closed
wants to merge 3 commits into from

Conversation

cedricziel
Copy link
Contributor

@cedricziel cedricziel commented May 16, 2025

Changes

Mangle spans so the names dont contain high-cardinality segments.

This actively prevents the scenario for the bring-your-own observability deployment type in the helm chart by fixing the span names locally

Partially fixes the concerns in #2189

@cedricziel cedricziel requested a review from a team as a code owner May 16, 2025 08:18
@cedricziel cedricziel changed the title fix: reduce cardinality in next.js spans with processor fix(frontend): reduce cardinality in next.js spans with processor May 16, 2025
Copy link

This PR was marked stale due to lack of activity. It will be closed in 7 days.

@github-actions github-actions bot added the Stale label May 24, 2025
@cedricziel cedricziel removed the Stale label May 25, 2025
Copy link
Member

@julianocosta89 julianocosta89 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@cedricziel is that an issue with the instrumentation library or with the demo itself?

I feel that renaming the span name, shouldn't be required, and if it is, we should do it in the Collector, not on the code.

@cedricziel
Copy link
Contributor Author

At this point the root cause is in the instrumentation, but the problem is with the demo.

Weve seen many folks running into extremely high cardinality because the issue is not being fixed in the instrumentation upstream.

This change "fixes" what's broken in order to limit the impact.

The problem I see with collector level changes is that anyone who's trying other collectors or scenarios will run into this - and they might not know

@cedricziel cedricziel requested a review from julianocosta89 June 2, 2025 16:40
Copy link

This PR was marked stale due to lack of activity. It will be closed in 7 days.

@puckpuck
Copy link
Contributor

puckpuck commented Jun 21, 2025

As mentioned in this comment on the original issue, this is fixed if you use the default transform rules we have in the Collector. We should keep to this pattern to fix these high cardinality span names.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants