[service] Start receivers after every other component type#15495
Merged
evan-bradley merged 5 commits intoJun 29, 2026
Conversation
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #15495 +/- ##
==========================================
+ Coverage 91.03% 91.08% +0.04%
==========================================
Files 726 726
Lines 47926 47939 +13
==========================================
+ Hits 43631 43666 +35
+ Misses 3000 2978 -22
Partials 1295 1295 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
ravishankar-sumo
approved these changes
Jun 25, 2026
VihasMakwana
approved these changes
Jun 28, 2026
evan-bradley
approved these changes
Jun 29, 2026
Merged
via the queue into
open-telemetry:main
with commit Jun 29, 2026
3e8f5a9
108 of 113 checks passed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
This PR constrains the start order of components so that receivers only start after every other type of component has started across all pipelines. Note that this is still reverse topological order, but with some of the free parameters fixed.
This avoids startup issues with pipelines like this:
in which
receiver/1andreceiver/2are two instances of asharedcomponent.Since
receiver/1andexporter/2are in disconnected parts of the component graph, their order in the startup schedule is undefined, so the service might (depending on the hash of the component instance identities) decide to startreceiver/1beforeexporter/2. But since startingreceiver/1also startsreceiver/2, which the service has no knowledge of, there is a chance forreceiver/2to emit data to an unstartedexporter/2, which violates the standard component lifecycle.Link to tracking issue
Fixes #15485
Testing
I added a unit test in
graph_test.gowhich checks that a shared receiver which eagerly sends data on startup does not send data to an unstarted exporter. This test fails with the previous code ingraph.go.Authorship