-
Notifications
You must be signed in to change notification settings - Fork 10.3k
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
Instrument with open tracing #6347
Instrument with open tracing #6347
Conversation
Note: This shouldn't be merged until DanielMSchmidt/zipkin-javascript-opentracing#68 has been merged. |
Deploy preview for using-drupal ready! Built with commit ea26228 |
Deploy preview for gatsbygram ready! Built with commit ea26228 |
Fantastic work! So excited about this. Could you post a screenshot or two of some sample traces? Re) code style — looks good to me. We do use Prettier for formatting so run |
Cool, added an image in the docs and ran |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice, thanks @Moocar 👌
I nearly merged this - so I'll repeat @Moocar's comment above - don't merge this until this PR has been merged. |
|
||
async function stopTracer() { | ||
if (tracerProvider) { | ||
if (tracerProvider.stop) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This was the only syntax nitpick I could find - you could also write it as if (tracerProvider && tracerProvider.stop) {
I'll be over here painting my bikeshed.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
That failed Netlify build is a red herring. Merging, thanks again @Moocar! |
Published as |
Hiya @Moocar! 👋 This is definitely late, but on behalf of the entire Gatsby community, I wanted to say thank you for being here. Gatsby is built by awesome people like you. Let us say “thanks” in two ways:
If you have questions, please don’t hesitate to reach out to us: tweet at @gatsbyjs and we’ll come a-runnin’. Thanks again! 💪💜 |
Add tracing to Gatsby! This PR adds open tracing instrumentation to Gatsby so that the following spans are automatically traced:
The traces can be viewed with any open tracing compatible backend by adding the appropriate library dependency and passing its configuration via the new
--open-tracing-config-file
command line option.Documentation on how to use it is provided in the new
/docs/performance-tracing.md
doc.Background information on why this approach to tracing was chosen can be found in #1074
I'm still relatively new to the javascript world, so syntax level feedback would be very much appreciated.