Skip to content

Conversation

@mrstork
Copy link
Contributor

@mrstork mrstork commented Dec 5, 2025

The current instrumentation patches global fetch which is import timing dependant and can conflict with other downstream patches and instrumentations. By subscribing to diagnostic channels, we are able to run alongside other instrumentations without risk of collisions.

  • Changes the name of the span from fetch -> GET/POST/...
  • Beyond ['HEAD', 'GET', 'POST', 'PUT', 'PATCH', 'DELETE'] the span will be named _OTHER
  • Leverages startSpan instead of withActiveSpan since the span timing depends on separate messages
    • In other words, spans that were a result of http calls will no longer be nested under the http call (which I think makes more sense overall). Example below.

Before:
image

After:
image

@mrstork mrstork requested a review from a team as a code owner December 5, 2025 16:03
@mrstork mrstork marked this pull request as draft December 5, 2025 16:04
@mrstork mrstork marked this pull request as ready for review December 5, 2025 17:26
@mrstork mrstork force-pushed the replace-fetch-instrumentation branch from 98fea82 to 5632e54 Compare December 5, 2025 18:31
JakeChampion
JakeChampion previously approved these changes Dec 5, 2025
@mrstork mrstork requested a review from JakeChampion December 5, 2025 21:13
@mrstork mrstork merged commit 412986e into main Dec 5, 2025
23 of 24 checks passed
@mrstork mrstork deleted the replace-fetch-instrumentation branch December 5, 2025 21:30
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