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
The current product-config architecture has a few issues that we keep bumping into:
It's confusing to understand what values come from where
Validation error messages are produced in the context of the product's configuration format, which is confusing to users who configure it in term of our ProductCluster abstraction
PC only works on unstructured key/value maps that correspond directly to the product's configuration structure, making it difficult to feed config back from PC to the operator itself (for example: port values need to match between the configuration's listen option and the generated discovery configmaps)
This often leads us to bypass P-C for these options
We have no solid way to get back typed Rust values when using the Configuration mechanism to allow fields to be overridden across the ProductCluster/Role/RoleGroup hierarchy (without implementing the same precedence mechanism in the operator itself)
There is a lot of repetitive boilerplate when linking Rust structs up to the PC machinery
To work this out I propose reorient PC so that the Rust structs are the source of truth for the structure, and so that precedence rules and validations are applied while still working with typed Rust values. We would still need to serialize to the product's native configuration format (and apply overrides to that) eventually, but this would be delayed until it is required.
From the definition side, the API is currently expected to look something like this:
This would allow the reconciler to process already fully merged and validated ZookeeperConfig objects, while still preserving the flexibility of the override hierarchy.
Product-config YAMLs would be relegated to serving as progressive enhancements and overrides to the metadata. For example, this could be used to improve backwards compatibility with older product versions, or to supply more thorough documentation. The current proposal for these looks like this, but this part is still fairly up in the air:
mixins:
- appliesTo:
product:
- kafkaversionRange:
- product: ">=1.0.0"properties:
- tick_limit_msapply:
description: | The maximum allowed clock skew between cluster membersdefault: foo
## Description
This is a starting point for #362, but is intended to be usable outside of that context (in this case, the primary motivation for getting this done now is #365).
Co-authored-by: Teo Klestrup Röijezon <[email protected]>
Co-authored-by: Felix Hennig <[email protected]>
Co-authored-by: Malte Sander <[email protected]>
Co-authored-by: Sebastian Bernauer <[email protected]>
Co-authored-by: Sönke Liebau <[email protected]>
The current product-config architecture has a few issues that we keep bumping into:
ProductCluster
abstractionConfiguration
mechanism to allow fields to be overridden across theProductCluster
/Role
/RoleGroup
hierarchy (without implementing the same precedence mechanism in the operator itself)To work this out I propose reorient PC so that the Rust structs are the source of truth for the structure, and so that precedence rules and validations are applied while still working with typed Rust values. We would still need to serialize to the product's native configuration format (and apply overrides to that) eventually, but this would be delayed until it is required.
From the definition side, the API is currently expected to look something like this:
This would expand to something like the following:
This would allow the reconciler to process already fully merged and validated
ZookeeperConfig
objects, while still preserving the flexibility of the override hierarchy.Product-config YAMLs would be relegated to serving as progressive enhancements and overrides to the metadata. For example, this could be used to improve backwards compatibility with older product versions, or to supply more thorough documentation. The current proposal for these looks like this, but this part is still fairly up in the air:
This is a part of stackabletech/issues#198.
The text was updated successfully, but these errors were encountered: