Skip to content

Commit e2e857b

Browse files
fix: Remove Merge trait bound and make product_specific_common_config field public (#946)
* remove merge trait and make product_specific_common_config public * adapt changelog * Update crates/stackable-operator/src/role_utils.rs Co-authored-by: Sebastian Bernauer <sebastian.bernauer@stackable.de> * Update crates/stackable-operator/CHANGELOG.md Co-authored-by: Sebastian Bernauer <sebastian.bernauer@stackable.de> --------- Co-authored-by: Sebastian Bernauer <sebastian.bernauer@stackable.de>
1 parent 68acaaf commit e2e857b

File tree

2 files changed

+11
-3
lines changed

2 files changed

+11
-3
lines changed

crates/stackable-operator/CHANGELOG.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,12 @@ All notable changes to this project will be documented in this file.
44

55
## [Unreleased]
66

7+
### Fixed
8+
9+
- Remove `Merge` trait bound from `erase` and make `product_specific_common_config` public ([#946]).
10+
11+
[#946]: https://github.com/stackabletech/operator-rs/pull/946
12+
713
## [0.84.0] - 2025-01-16
814

915
### Added

crates/stackable-operator/src/role_utils.rs

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -163,9 +163,11 @@ pub struct CommonConfiguration<T, ProductSpecificCommonConfig> {
163163
// No docs needed, as we flatten this struct.
164164
//
165165
// This field is product-specific and can contain e.g. jvmArgumentOverrides.
166-
// It is not accessible by operators, please use [`Role::get_product_specific_common_configs`] to read the values.
166+
//
167+
// If [`JavaCommonConfig`] is used, please use [`Role::get_merged_jvm_argument_overrides`] instead of
168+
// reading this field directly.
167169
#[serde(flatten, default)]
168-
pub(crate) product_specific_common_config: ProductSpecificCommonConfig,
170+
pub product_specific_common_config: ProductSpecificCommonConfig,
169171
}
170172

171173
impl<T, ProductSpecificCommonConfig> CommonConfiguration<T, ProductSpecificCommonConfig> {
@@ -324,7 +326,7 @@ impl<T, U, ProductSpecificCommonConfig> Role<T, U, ProductSpecificCommonConfig>
324326
where
325327
T: Configuration + 'static,
326328
U: Default + JsonSchema + Serialize,
327-
ProductSpecificCommonConfig: Default + JsonSchema + Serialize + Clone + Merge,
329+
ProductSpecificCommonConfig: Default + JsonSchema + Serialize + Clone,
328330
{
329331
/// This casts a generic struct implementing [`crate::product_config_utils::Configuration`]
330332
/// and used in [`Role`] into a Box of a dynamically dispatched

0 commit comments

Comments
 (0)