-
Notifications
You must be signed in to change notification settings - Fork 399
DEBUG-3457 hack probe notifier worker starting #4358
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
Changes from 3 commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -39,6 +39,12 @@ def call(env) | |
|
|
||
| boot = Datadog::Core::Remote::Tie.boot | ||
|
|
||
| if defined?(Datadog::DI.current_component) | ||
| # TODO when would Datadog::DI be defined but | ||
| # Datadog::DI.current_component not be defined? | ||
| Datadog::DI.current_component&.probe_notifier_worker&.start | ||
|
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. Also a question similar to TODO's question: Is the
Member
Author
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. The entire DI component should be missing on Ruby 2.5 and JRuby. I am not sure (per the comment, and I did not investigate) why the DI module is defined but current_component is not defined sometimes. If current_component is defined and not nil, the rest of DI infrastructure should be loaded. |
||
| end | ||
|
|
||
| # Extract distributed tracing context before creating any spans, | ||
| # so that all spans will be added to the distributed trace. | ||
| if configuration[:distributed_tracing] | ||
|
|
||
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 there a reason the approach we use in tracing doesn't work for DI?
In tracing, we always check if the process has forked when submitting data, and if it has, we restart the worker:
dd-trace-rb/lib/datadog/tracing/writer.rb
Line 110 in 5319afc
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 can certainly do that.
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.
Done in #4363