fix(topology): consume pending component reloads#25911
Draft
ArunPiduguDD wants to merge 2 commits into
Draft
Conversation
Consume explicit component reload requests after the next topology reload. Environment: Datadog workspace Co-Authored-By: Pi OpenAI GPT-5 <noreply@pi.dev>
Explain how repeated component reloads can reset in-memory state. Environment: Datadog workspace Co-Authored-By: Pi OpenAI GPT-5 <noreply@pi.dev>
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.
Summary
Vector can explicitly reload selected components even when their serialized configuration has not changed. This is used, for example, when a file watched by a component changes.
The selected component names currently remain in the pending reload set after the reload finishes. Consider this sequence:
Achanges, so Vector explicitly reloadsA.B.Ais still in the pending set, Vector unnecessarily restarts bothAandB.Repeated restarts can reset task-local in-memory state and cause unnecessary reconnections, health checks, or brief disruption. This change consumes the pending set when calculating the next topology update. An explicit reload therefore applies once, while a later request can still add the component again.
Vector configuration
Not applicable. This behavior is covered by topology reload tests.
How did you test this PR?
cargo test pending_component_reloads_are_consumed_after_reload --lib --no-default-featuresmake check-clippycargo fmt --all -- --check./scripts/check_changelog_fragments.shmake check-fmtcould not complete because the environment does not have the YAML formatter executable available.Change Type
Is this a breaking change?
Does this PR include user facing changes?
no-changeloglabel to this PR.References