-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
js(docs): Update Tracing pages for stream mode #17862
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
Open
inventarSarah
wants to merge
13
commits into
master
Choose a base branch
from
smi/span-first/js-tracing-updates
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
13 commits
Select commit
Hold shift + click to select a range
ea9f7ec
tracing docs updates
inventarSarah 8825942
update tracing pages for stream mode
inventarSarah daaa48d
Merge branch 'master' of github.com:getsentry/sentry-docs into smi/sp…
inventarSarah b9e300b
Merge branch 'master' of github.com:getsentry/sentry-docs into smi/sp…
inventarSarah 534eb04
update span terminology
inventarSarah bbaf8fc
Merge branch 'master' of github.com:getsentry/sentry-docs into smi/sp…
inventarSarah 6be10df
Apply suggestion from @sfanahata
inventarSarah d43556d
Merge branch 'smi/span-first/js-tracing-updates' of github.com:getsen…
inventarSarah b211ca5
troubleshooting page PR input
inventarSarah 7fd997b
Merge branch 'master' of github.com:getsentry/sentry-docs into smi/sp…
inventarSarah 782a715
refine troubleshooting explanation for ignorespans
inventarSarah 7029626
Merge branch 'master' of github.com:getsentry/sentry-docs into smi/sp…
inventarSarah ca3c048
pr review updates
inventarSarah File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -70,9 +70,10 @@ For detailed examples of how to implement span metrics in common scenarios, see | |
|
|
||
| ## Adding Metrics to All Spans | ||
|
|
||
| To consistently add metrics across all spans in your application, you can use the `beforeSendSpan` callback: | ||
| To consistently add metrics across all spans in your application, you can use the `beforeSendSpan` callback. | ||
| Note that the property names differ between transaction mode (the default) and <PlatformLink to="/tracing/new-spans/">stream mode</PlatformLink>: | ||
|
|
||
| ```javascript | ||
| ```javascript {tabTitle:Transaction Mode (Default)} | ||
| Sentry.init({ | ||
| beforeSendSpan(span) { | ||
| span.data = { | ||
|
|
@@ -86,6 +87,20 @@ Sentry.init({ | |
| }); | ||
| ``` | ||
|
|
||
| ```javascript {tabTitle:Stream Mode} | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'm liking these additions!
Member
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. +1 |
||
| Sentry.init({ | ||
| beforeSendSpan(span) { | ||
| span.attributes = { | ||
| ...span.attributes, | ||
| "app.version": "1.2.3", | ||
| "environment.region": "us-west-2", | ||
| }; | ||
|
|
||
| return span; | ||
| }, | ||
| }); | ||
| ``` | ||
|
|
||
| For detailed examples of how to implement span metrics in common scenarios, see our <PlatformLink to="/tracing/span-metrics/examples/">Span Metrics Examples</PlatformLink> guide. | ||
|
|
||
| ## Span Metrics vs. Measurements | ||
|
|
||
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
2 changes: 1 addition & 1 deletion
2
...ms/javascript/guides/node/tracing/instrumentation/automatic-instrumentation.mdx
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,6 +1,6 @@ | ||
| --- | ||
| title: Automatic Instrumentation | ||
| description: "Learn what transactions are captured after tracing is enabled." | ||
| description: "Learn what spans are captured after tracing is enabled." | ||
| --- | ||
|
|
||
| <Include name="node-automatic-instrumentation" /> |
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
Oops, something went wrong.
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.