-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
Changed how the telemetryInitializer is created #6138
Changed how the telemetryInitializer is created #6138
Conversation
Codecov ReportBase: 91.89% // Head: 91.90% // Increases project coverage by
Additional details and impacted files@@ Coverage Diff @@
## main #6138 +/- ##
=======================================
Coverage 91.89% 91.90%
=======================================
Files 217 217
Lines 13319 13322 +3
=======================================
+ Hits 12240 12243 +3
Misses 850 850
Partials 229 229
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report at Codecov. |
For CI failures |
Is there a particular PR that is supposed to fix the contrib tests? If so, will you link it here so we can track it? |
I believe it was this PR open-telemetry/opentelemetry-collector-contrib#14390. The contrib tests look like the fail due to a signalfx go mod error. |
…t global Signed-off-by: Corbin Phelps <[email protected]>
Signed-off-by: Corbin Phelps <[email protected]>
Signed-off-by: Corbin Phelps <[email protected]>
…d removed once logic Signed-off-by: Corbin Phelps <[email protected]>
fa99f71
to
ce253e0
Compare
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 LGTM.
@open-telemetry/collector-maintainers, anyone available to take a look at this one? |
Description:
Changed how the
telemetryInitializer
is created. Previously only a single instance of thetelemetryInitializer
was created for a process. The caused an issue if aCollector
instance was shutdown and a new one was created the new instance would get the global instance that was shutdown as a result of the first Collector instance being shutdown.The new logic ensures the feature gate is only registered once but a new
telemetryInitializer
instance is created per instance of the collector.Link to tracking Issue:
Tangentially related to #5084.
In that issue the desired design is:
I believe this respects that design and fixes a bug where a new instance could not fully startup with the same expectations as the previous instance.
Testing:
Modified unit tests. Also, tested with our OPAMP enabled agent and server to verify that we can create a new instance of the collector with a changed config in a single process and have telemetry still be active. Previously it would not be.