Conversation
The loader, action and fetcher spans from the instrumentation API still
named themselves after the value they had at hand: the route pattern,
which falls back to the raw request path when React Router matches no
pattern, or the fetcher key, which is unique per fetcher instance. Under
span streaming both are high cardinality.
Name these spans after the function they wrap, matching the
`code.function.name` they already set. The `function` op's description
template is `{{code.function.name}}` and nothing else, so Relay cannot
infer the route from any attribute we could add - the previous name is
kept on `sentry.description` instead.
Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com>
Contributor
size-limit report 📦
|
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The loader, action and fetcher spans started by the instrumentation API named themselves after whatever value was at hand: the route pattern, which falls back to the raw request path whenever React Router matches no pattern, or the fetcher key, which is unique per fetcher instance. Under span streaming both are high cardinality. They now use the function they wrap — the
code.function.namethese spans already set — so the name matches what thefunctionop's convention asks for.The
functionop's description template is{{code.function.name}}and nothing else, so there is no attribute we could set to let Relay infer the route back. The previous name is kept onsentry.descriptioninstead, on the streaming branch only. Without span streaming nothing changes.🤖 Generated with Claude Code