From 4b389b18f65e17a05573d949297164ed48bfc010 Mon Sep 17 00:00:00 2001 From: Malte Sander Date: Tue, 25 Apr 2023 16:28:38 +0200 Subject: [PATCH 1/8] add listenerclass --- .../kuttl/druid-connection/02-install-superset.yaml.j2 | 2 ++ 1 file changed, 2 insertions(+) diff --git a/tests/templates/kuttl/druid-connection/02-install-superset.yaml.j2 b/tests/templates/kuttl/druid-connection/02-install-superset.yaml.j2 index 089e0833..5e81c14d 100644 --- a/tests/templates/kuttl/druid-connection/02-install-superset.yaml.j2 +++ b/tests/templates/kuttl/druid-connection/02-install-superset.yaml.j2 @@ -32,6 +32,8 @@ spec: {% endif %} credentialsSecret: superset-credentials loadExamplesOnInit: false + clusterConfig: + listenerClass: external-unstable nodes: config: logging: From b8b3d51daa9b85a02acf3e1117876d9025e95d79 Mon Sep 17 00:00:00 2001 From: Malte Sander Date: Tue, 25 Apr 2023 16:28:44 +0200 Subject: [PATCH 2/8] switch versions --- rust/crd/src/affinity.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/rust/crd/src/affinity.rs b/rust/crd/src/affinity.rs index e307b087..3434b908 100644 --- a/rust/crd/src/affinity.rs +++ b/rust/crd/src/affinity.rs @@ -46,8 +46,8 @@ mod tests { name: simple-superset spec: image: - productVersion: 1.5.1 - stackableVersion: "23.1" + productVersion: 2.1.0 + stackableVersion: "0.0.0-dev" credentialsSecret: simple-superset-credentials nodes: roleGroups: @@ -108,8 +108,8 @@ mod tests { name: simple-superset spec: image: - productVersion: 1.5.1 - stackableVersion: "23.1" + productVersion: 2.1.0 + stackableVersion: "0.0.0-dev" credentialsSecret: simple-superset-credentials nodes: roleGroups: From 32a9f227d07299d96c93d553602b887bed196b37 Mon Sep 17 00:00:00 2001 From: Malte Sander Date: Tue, 25 Apr 2023 16:29:11 +0200 Subject: [PATCH 3/8] add SUPERSET_SECRET_KEY to envars to prevent failing druid import job in v2.1.0 --- rust/operator-binary/src/druid_connection_controller.rs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/rust/operator-binary/src/druid_connection_controller.rs b/rust/operator-binary/src/druid_connection_controller.rs index 12311b95..38e2e28d 100644 --- a/rust/operator-binary/src/druid_connection_controller.rs +++ b/rust/operator-binary/src/druid_connection_controller.rs @@ -316,6 +316,8 @@ async fn build_import_job( .command(vec!["/bin/sh".to_string()]) .args(vec![String::from("-c"), commands.join("; ")]) .add_env_var_from_secret("DATABASE_URI", secret, "connections.sqlalchemyDatabaseUri") + // From 2.1.0 superset barfs if the SECRET_KEY is not set properly. This causes the import job to fail. + .add_env_var_from_secret("SUPERSET_SECRET_KEY", secret, "connections.secretKey") .build(); let pod = PodTemplateSpec { From bd4a933697ca99d970e0aab0d2c8526d993f5213 Mon Sep 17 00:00:00 2001 From: Malte Sander Date: Tue, 25 Apr 2023 16:29:33 +0200 Subject: [PATCH 4/8] push versions to 2.1.0 --- docs/modules/superset/examples/getting_started/superset.yaml | 2 +- .../superset/examples/getting_started/superset.yaml.j2 | 2 +- docs/modules/superset/pages/usage-guide/security.adoc | 2 +- examples/superset-with-ldap.yaml | 4 +++- 4 files changed, 6 insertions(+), 4 deletions(-) diff --git a/docs/modules/superset/examples/getting_started/superset.yaml b/docs/modules/superset/examples/getting_started/superset.yaml index 17404410..1eda0008 100644 --- a/docs/modules/superset/examples/getting_started/superset.yaml +++ b/docs/modules/superset/examples/getting_started/superset.yaml @@ -5,7 +5,7 @@ metadata: name: simple-superset spec: image: - productVersion: 1.5.1 + productVersion: 2.1.0 stackableVersion: 0.0.0-dev clusterConfig: listenerClass: external-unstable diff --git a/docs/modules/superset/examples/getting_started/superset.yaml.j2 b/docs/modules/superset/examples/getting_started/superset.yaml.j2 index b60d65c0..675c7854 100644 --- a/docs/modules/superset/examples/getting_started/superset.yaml.j2 +++ b/docs/modules/superset/examples/getting_started/superset.yaml.j2 @@ -5,7 +5,7 @@ metadata: name: simple-superset spec: image: - productVersion: 1.5.1 + productVersion: 2.1.0 stackableVersion: {{ versions.superset }} clusterConfig: listenerClass: external-unstable diff --git a/docs/modules/superset/pages/usage-guide/security.adoc b/docs/modules/superset/pages/usage-guide/security.adoc index bdf86b74..f91007ef 100644 --- a/docs/modules/superset/pages/usage-guide/security.adoc +++ b/docs/modules/superset/pages/usage-guide/security.adoc @@ -19,7 +19,7 @@ metadata: name: superset-with-ldap-server spec: image: - productVersion: 1.5.1 + productVersion: 2.1.0 stackableVersion: 0.0.0-dev [...] authenticationConfig: diff --git a/examples/superset-with-ldap.yaml b/examples/superset-with-ldap.yaml index 6b783de5..843f2ac5 100644 --- a/examples/superset-with-ldap.yaml +++ b/examples/superset-with-ldap.yaml @@ -149,8 +149,10 @@ metadata: name: superset-with-ldap-server-veri-tls spec: image: - productVersion: 1.5.1 + productVersion: 2.1.0 stackableVersion: 0.0.0-dev + clusterConfig: + listenerClass: external-unstable credentialsSecret: superset-with-ldap-server-veri-tls-credentials nodes: roleGroups: From ce5a81b4175fb0c21fba105c309afb8a65e2103d Mon Sep 17 00:00:00 2001 From: Malte Sander Date: Tue, 25 Apr 2023 16:29:51 +0200 Subject: [PATCH 5/8] add supported versions 1.4.2, 1.5.3, 2.0.1, 2.1.0 --- docs/modules/superset/partials/supported-versions.adoc | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/docs/modules/superset/partials/supported-versions.adoc b/docs/modules/superset/partials/supported-versions.adoc index 1233bc51..0987da8e 100644 --- a/docs/modules/superset/partials/supported-versions.adoc +++ b/docs/modules/superset/partials/supported-versions.adoc @@ -3,5 +3,7 @@ // Stackable Platform documentation. - 1.3.2 -- 1.4.1 -- 1.5.1 +- 1.4.1, 1.4.2 +- 1.5.1, 1.5.3 +- 2.0.1 +- 2.1.0 From 682d045fc3eeb69d8b92f8f2331b7358f12f25f0 Mon Sep 17 00:00:00 2001 From: Malte Sander Date: Tue, 25 Apr 2023 17:16:37 +0200 Subject: [PATCH 6/8] adapted tests --- tests/test-definition.yaml | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/tests/test-definition.yaml b/tests/test-definition.yaml index 063ac797..706f2d3e 100644 --- a/tests/test-definition.yaml +++ b/tests/test-definition.yaml @@ -3,11 +3,13 @@ dimensions: - name: superset values: - 1.3.2-stackable0.0.0-dev - - 1.4.1-stackable0.0.0-dev - - 1.5.1-stackable0.0.0-dev + - 1.4.2-stackable0.0.0-dev + - 1.5.3-stackable0.0.0-dev + - 2.0.1-stackable0.0.0-dev + - 2.1.0-stackable0.0.0-dev - name: superset-latest values: - - 1.5.1-stackable0.0.0-dev + - 2.1.0-stackable0.0.0-dev - name: ldap-authentication values: - no-tls From a24d94f834ba0b86360640ea04118a4b64938981 Mon Sep 17 00:00:00 2001 From: Malte Sander Date: Tue, 25 Apr 2023 17:16:49 +0200 Subject: [PATCH 7/8] added better comment for secret key envar --- rust/operator-binary/src/druid_connection_controller.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/rust/operator-binary/src/druid_connection_controller.rs b/rust/operator-binary/src/druid_connection_controller.rs index 38e2e28d..115a7c40 100644 --- a/rust/operator-binary/src/druid_connection_controller.rs +++ b/rust/operator-binary/src/druid_connection_controller.rs @@ -317,6 +317,7 @@ async fn build_import_job( .args(vec![String::from("-c"), commands.join("; ")]) .add_env_var_from_secret("DATABASE_URI", secret, "connections.sqlalchemyDatabaseUri") // From 2.1.0 superset barfs if the SECRET_KEY is not set properly. This causes the import job to fail. + // Setting the env var is enough to be picked up: https://superset.apache.org/docs/installation/configuring-superset/#configuration .add_env_var_from_secret("SUPERSET_SECRET_KEY", secret, "connections.secretKey") .build(); From e951af051c01022b84a233f3fa974d3b10b9ceaa Mon Sep 17 00:00:00 2001 From: Malte Sander Date: Tue, 25 Apr 2023 17:20:13 +0200 Subject: [PATCH 8/8] adapted changelog --- CHANGELOG.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 26566ad3..e6fc333e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,10 @@ ## [Unreleased] +### Added + +- Added support for Superset versions `1.4.2`, `1.5.3`, `2.0.1` and `2.1.0` ([#362]). + ### Changed - `operator-rs` `0.40.2` -> `0.41.0` ([#360]). @@ -10,6 +14,7 @@ [#360]: https://github.com/stackabletech/superset-operator/pull/360 [#361]: https://github.com/stackabletech/superset-operator/pull/361 +[#362]: https://github.com/stackabletech/superset-operator/pull/362 ## [23.4.0] - 2023-04-17