Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,10 @@ All notable changes to this project will be documented in this file.

### Added

- Add support for specifying additional extensions to load ([#547])
- Add support for specifying additional extensions to load ([#547], [#563])

[#547]: https://github.com/stackabletech/druid-operator/pull/547
[#563]: https://github.com/stackabletech/druid-operator/pull/563

## [24.3.0] - 2024-03-20

Expand All @@ -23,7 +26,6 @@ All notable changes to this project will be documented in this file.
[#494]: https://github.com/stackabletech/druid-operator/pull/494
[#509]: https://github.com/stackabletech/druid-operator/pull/509
[#518]: https://github.com/stackabletech/druid-operator/pull/518
[#547]: https://github.com/stackabletech/druid-operator/pull/547

## [23.11.0] - 2023-11-24

Expand Down
18 changes: 1 addition & 17 deletions rust/crd/src/lib.rs
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ use stackable_operator::{
spec::Logging,
},
role_utils::{CommonConfiguration, GenericRoleConfig, Role, RoleGroup},
schemars::{self, schema::Schema, JsonSchema},
schemars::{self, JsonSchema},
status::condition::{ClusterCondition, HasStatusCondition},
time::Duration,
utils::COMMON_BASH_TRAP_FUNCTIONS,
Expand Down Expand Up @@ -242,7 +242,6 @@ pub struct DruidClusterConfig {
/// sometimes be necessary to load additional extensions.
/// Add configuration for additional extensions using [configuration override for Druid](https://docs.stackable.tech/home/stable/druid/usage-guide/configuration-and-environment-overrides).
#[serde(default)]
#[schemars(schema_with = "additional_extensions_schema")]
pub additional_extensions: HashSet<String>,

/// List of [AuthenticationClasses](DOCS_BASE_URL_PLACEHOLDER/concepts/authentication)
Expand Down Expand Up @@ -309,21 +308,6 @@ pub struct DruidClusterConfig {
pub listener_class: CurrentlySupportedListenerClasses,
}

/// TODO: Remove once kube-rs is fixed.
/// Currently using HashSets and BTreeMaps in the schema will result in an invalid CRD that is rejected by the kube-apiserver with
/// error message `Forbidden: uniqueItems cannot be set to true since the runtime complexity becomes quadratic`.
/// This issue will be fixed in kube-rs by `<https://github.com/kube-rs/kube/pull/1484>`
pub fn additional_extensions_schema(gen: &mut schemars::gen::SchemaGenerator) -> Schema {
let mut schema = HashSet::<String>::json_schema(gen);

if let Schema::Object(schema) = &mut schema {
let array = schema.array();
array.unique_items = None;
}

schema
}

// TODO: Temporary solution until listener-operator is finished
#[derive(Clone, Debug, Default, Display, Deserialize, Eq, JsonSchema, PartialEq, Serialize)]
#[serde(rename_all = "PascalCase")]
Expand Down