fix: preserve associated aggregator on multiple detached configs#2232
Merged
csatib02 merged 3 commits intoMay 5, 2026
Conversation
Signed-off-by: Bence Csati <bence.csati@axoflow.com>
Signed-off-by: Bence Csati <bence.csati@axoflow.com>
|
Promptless prepared a documentation update related to this change. Triggered by PR #2232 Clarified in the FluentdConfig and SyslogNGConfig docs that when multiple configs exist, the previously-associated aggregator continues running and log forwarding remains uninterrupted while users resolve the excess configuration conflict. Review: Clarify excess config behavior preserves running aggregator |
When a second FluentdConfig or SyslogNGConfig was created in the
control namespace, FluentdConfigFor/SyslogNGConfigFor returned a nil
Configuration. The reconciler then cleared
Logging.Status.{Fluentd,SyslogNG}ConfigName and the finalizer logic in
LoggingReconciler.{fluentd,syslogNG}ConfigFinalizer removed the
finalizer because externalConfig was nil. The running aggregator
StatefulSet got de-associated and log forwarding broke - even though
the user only added a redundant CRD that should have been flagged as
excess.
Preserve the previously-associated configuration (looked up via
Logging.Status.{Fluentd,SyslogNG}ConfigName) when multiple detached
configs exist. Stale references (the named config no longer exists)
fall through to the existing all-excess behavior.
Adds regression tests for both paths plus the stale-association case.
Surfaced by flaky e2e TestSyslogNGDetachedIsRunningAndForwardingLogs.
Signed-off-by: Bence Csati <bence.csati@axoflow.com>
03ccd9d to
7181e34
Compare
OverOrion
approved these changes
May 5, 2026
fekete-robert
pushed a commit
to kube-logging/kube-logging.github.io
that referenced
this pull request
May 12, 2026
When multiple FluentdConfig or SyslogNGConfig resources exist in the same namespace, the documentation now clearly states that: - The previously-associated config continues to operate normally - Log forwarding remains uninterrupted while resolving the conflict - Users should delete the excess config to resolve the issue Also standardized SyslogNGConfig capitalization. Related: kube-logging/logging-operator#2232
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.
Creating a second FluentdConfig / SyslogNGConfig in the control namespace tore down the running aggregator instead of flagging the new one as excess.
Fix: When multiple detached configs exist, looking up Logging.Status.{Fluentd,SyslogNG}ConfigName and keep that one as Configuration. Stale reference (named config no longer exists) falls through to the existing all-excess behavior.
Also fixed a copy-paste typo in while handling excess SyslogNG.