-
Notifications
You must be signed in to change notification settings - Fork 375
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
Some integrations in 0.36.0 have stale tracer instances #1072
Comments
@delner @marcotc thanks for this! We've noticed early this week, that our Rails logs didn't have trace ids (all were a value of 0) after upgrading to 0.36.0 from 0.35.2. We believe this also affects other services used in our Rails app. For now we are downgrading to 0.35.2. I figured there are other changes necessary besides #1073 to resolve this issue but if you have a branch with a possible fix, we'd like to help out and verify. Thanks! |
For anyone who had issues suspected to be caused by this bug, we'd encourage you to try this prerelease which should have the fix. Please feel free to try it out and let us know if it resolves your issue! If all is well, we hope to release this soon.
(CC @javierjulio @frewsxcv @kramuenke @fledman @mhenrixon @jeffblake @rafaelsales @pacoguzman) |
@delner thanks for the update! We just tried out the |
@marcotc @delner is using the test tracer still expected to work? I have this configured in my test suite, upgrading from
|
Hey @sammilechman, yes the |
Thanks for looking @marcotc. It looks like you're right, the traces are happening before |
In 0.36.0 we have a known issue with stale tracer instances being cached incorrectly on integrations, which can result in the instrumentation using the wrong tracer with old settings. The symptoms of this can manifest in a variety of ways, but all of which make it look as though the tracer has ignored settings, or isn't returning active state as expected.
This issue is the result of an intersection of some new changes to the tracer core (where we rebuild tracers after they are changed, following an immutable pattern #996) and old behavior in the integration configuration model (which will cache an instance of the tracer if the integration is explicitly configured with one, as opposed to falling back to the global
Datadog.tracer
.)This is known to affect Rails and GraphQL, and is suspected to affect other integrations as well. For Rails users, you can try using #1064 to see if it resolves your issue (please let us know if it does, so we can know if it works, and what problems it solves.)
A few of these issues can be worked around by using
ENV
vars to drive configuration when possible, but not all of these issues have such workarounds.We're working on a more comprehensive fix to the integrations such that they will not cache tracers, and an overhaul to our CI to detect this issue; we hope to have that ready soon. In the meantime if you have an issue related to this not mitigated by a workaround, we'd recommend using either 0.34.2 or 0.35.2.
Here's a list of issues that are suspected to be related to this bug. At this time, we assume they all have the same approximate cause as described above.
Datadog.tracer.enabled = false
#1029Datadog.tracer.active_correlation
is not set for Rails requests #1069The text was updated successfully, but these errors were encountered: