You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* refactor: Standardize FC config validation pattern
Introduces a consistent `ValidateAndApplyDefaults` method to the
configuration structs in the `flowcontrol/controller` and
`flowcontrol/registry` packages.
This change refactors the configuration handling to follow a unified
pattern:
- Configuration structs now have a `ValidateAndApplyDefaults` method
that returns a new, validated config object without mutating the
original.
- Constructors for `FlowController` and `FlowRegistry` now assume they
receive a valid configuration, simplifying their logic and pushing the
responsibility of validation to the caller.
- The `deepCopy` logic is corrected to ensure test assertions for
immutability pass reliably.
This improves the clarity and robustness of configuration management
within the flow control module, creating a consistent foundation for
future wiring work.
* feat(flowcontrol): Add bundled Flow Control config
Introduces a new top-level `Config` for the Flow Control layer.
This config bundles the configurations for the `controller` and
`registry` packages, providing a single, unified point of entry fo
validation and default application. This simplifies the management and
initialization of the flow control system by centralizing its
configuration.
* fix: Update controller tests with valid config
The previous commit introduced a unified and validated configuration
for the flow control system, requiring callers to pass a pre-validated
cofig to the controller and registry respectively. This change updates
the controller tests to provide a valid configuration instead of relying
on the now-removed defaulting logic in the constructor.
0 commit comments