-
Notifications
You must be signed in to change notification settings - Fork 435
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
ddtrace/tracer: add service version to tracer. #607
Conversation
…es DD_SERVICE and DD_VERSION.
This is massively confusing from an API standpoint. Not exactly sure what we're doing here (no PR description provided), but let's not do it like this. |
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.
Is "service name" and "service" supposed to be the same thing? If yes, let's make sure that only one of them exists from a user standpoint. For example: change ext.ServiceName
to have the value "service"
but keep support for "service.name"
to make sure there are no breaking changes for people using this string direclty.
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.
I think it looks good now.
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.
One last tiny thing :)
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.
lgtm!
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 commit adds the concept of a service version to the tracer. The service version should be the current version of the application (service). the service version will be picked up from the DD_VERSION environment variable, or can be set with the WithServiceVersion StartOption when starting the tracer. WithServiceVersion takes priority over the environment variable. Spans that have a service name equal to the application's service name (set with DD_SERVICE or the WithServiceName StartOption) will be given a "version" tag with the service version as its value.
This PR adds the concept of a service version to the tracer. The service version should be the current version of the application (service). the service version will be picked up from the
DD_VERSION
environment variable, or can be set with theWithServiceVersion
StartOption
when starting the tracer.WithServiceVersion
takes priority over the environment variable.Spans that have a service name equal to the application's service name (set with
DD_SERVICE
or theWithServiceName
StartOption
) will be given a"version"
tag with the service version as its value.