Skip to content

Commit 51cfff6

Browse files
authored
Merge branch 'main' into spike/generic-databases
2 parents a21b8bd + c81d453 commit 51cfff6

21 files changed

Lines changed: 464 additions & 82 deletions

File tree

.pre-commit-config.yaml

Lines changed: 100 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -55,14 +55,39 @@ repos:
5555
pass_filenames: false
5656
files: \.rs$|Cargo\.(toml|lock)
5757

58-
- id: cargo-test-no-default-features
59-
name: cargo-test-no-default-features
58+
- id: cargo-doc-no-default-features
59+
name: cargo-doc-no-default-features
6060
language: system
61-
entry: cargo test --no-default-features --workspace
61+
entry: cargo doc --no-deps --no-default-features --document-private-items
6262
stages: [pre-commit, pre-merge-commit]
6363
pass_filenames: false
6464
files: \.rs$|Cargo\.(toml|lock)
6565

66+
- id: cargo-doc-all-features
67+
name: cargo-doc-all-features
68+
language: system
69+
entry: cargo doc --no-deps --all-features --document-private-items
70+
stages: [pre-commit, pre-merge-commit]
71+
pass_filenames: false
72+
files: \.rs$|Cargo\.(toml|lock)
73+
74+
# As long as we run tests for every contained crate (to test turning off all features),
75+
# we don't need to re-run them here
76+
# - id: cargo-test
77+
# name: cargo-test
78+
# language: system
79+
# entry: cargo test --workspace
80+
# stages: [pre-commit, pre-merge-commit]
81+
# pass_filenames: false
82+
# files: \.rs$|Cargo\.(toml|lock)
83+
# - id: cargo-test-no-default-features
84+
# name: cargo-test-no-default-features
85+
# language: system
86+
# entry: cargo test --no-default-features --workspace
87+
# stages: [pre-commit, pre-merge-commit]
88+
# pass_filenames: false
89+
# files: \.rs$|Cargo\.(toml|lock)
90+
6691
- id: cargo-test-all-features
6792
name: cargo-test-all-features
6893
language: system
@@ -71,6 +96,78 @@ repos:
7196
pass_filenames: false
7297
files: \.rs$|Cargo\.(toml|lock)
7398

99+
- id: cargo-test-k8s-version-no-default-features
100+
name: cargo-test-k8s-version-no-default-features
101+
language: system
102+
entry: cargo test --no-default-features --package k8s-version
103+
stages: [pre-commit, pre-merge-commit]
104+
pass_filenames: false
105+
files: \.rs$|Cargo\.(toml|lock)
106+
107+
- id: cargo-test-stackable-certs-no-default-features
108+
name: cargo-test-stackable-certs-no-default-features
109+
language: system
110+
entry: cargo test --no-default-features --package stackable-certs
111+
stages: [pre-commit, pre-merge-commit]
112+
pass_filenames: false
113+
files: \.rs$|Cargo\.(toml|lock)
114+
115+
- id: cargo-test-stackable-operator-no-default-features
116+
name: cargo-test-stackable-operator-no-default-features
117+
language: system
118+
entry: cargo test --no-default-features --package stackable-operator
119+
stages: [pre-commit, pre-merge-commit]
120+
pass_filenames: false
121+
files: \.rs$|Cargo\.(toml|lock)
122+
123+
- id: cargo-test-stackable-operator-derive-no-default-features
124+
name: cargo-test-stackable-operator-derive-no-default-features
125+
language: system
126+
entry: cargo test --no-default-features --package stackable-operator-derive
127+
stages: [pre-commit, pre-merge-commit]
128+
pass_filenames: false
129+
files: \.rs$|Cargo\.(toml|lock)
130+
131+
- id: cargo-test-stackable-shared-no-default-features
132+
name: cargo-test-stackable-shared-no-default-features
133+
language: system
134+
entry: cargo test --no-default-features --package stackable-shared
135+
stages: [pre-commit, pre-merge-commit]
136+
pass_filenames: false
137+
files: \.rs$|Cargo\.(toml|lock)
138+
139+
- id: cargo-test-stackable-telemetry-no-default-features
140+
name: cargo-test-stackable-telemetry-no-default-features
141+
language: system
142+
entry: cargo test --no-default-features --package stackable-telemetry
143+
stages: [pre-commit, pre-merge-commit]
144+
pass_filenames: false
145+
files: \.rs$|Cargo\.(toml|lock)
146+
147+
- id: cargo-test-stackable-versioned-no-default-features
148+
name: cargo-test-stackable-versioned-no-default-features
149+
language: system
150+
entry: cargo test --no-default-features --package stackable-versioned
151+
stages: [pre-commit, pre-merge-commit]
152+
pass_filenames: false
153+
files: \.rs$|Cargo\.(toml|lock)
154+
155+
- id: cargo-test-stackable-versioned-macros-no-default-features
156+
name: cargo-test-stackable-versioned-macros-no-default-features
157+
language: system
158+
entry: cargo test --no-default-features --package stackable-versioned-macros
159+
stages: [pre-commit, pre-merge-commit]
160+
pass_filenames: false
161+
files: \.rs$|Cargo\.(toml|lock)
162+
163+
- id: cargo-test-stackable-webhook-no-default-features
164+
name: cargo-test-stackable-webhook-no-default-features
165+
language: system
166+
entry: cargo test --no-default-features --package stackable-webhook
167+
stages: [pre-commit, pre-merge-commit]
168+
pass_filenames: false
169+
files: \.rs$|Cargo\.(toml|lock)
170+
74171
- id: cargo-rustfmt
75172
name: cargo-rustfmt
76173
language: system

Cargo.lock

Lines changed: 51 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

Cargo.toml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ either = "1.13.0"
2929
futures = "0.3.30"
3030
futures-util = "0.3.30"
3131
http = "1.3.1"
32+
humantime = "2.1.0"
3233
indexmap = "2.5.0"
3334
indoc = "2.0.6"
3435
jiff = "0.2.18"

crates/stackable-operator/CHANGELOG.md

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

55
## [Unreleased]
66

7+
### Added
8+
9+
- Add support for specifying a `clientAuthenticationMethod` for OIDC ([#1178]).
10+
This was originally done in [#1158] and had been reverted in [#1170].
11+
12+
[#1178]: https://github.com/stackabletech/operator-rs/pull/1178
13+
14+
## [0.108.0] - 2026-03-10
15+
16+
### Removed
17+
18+
- Reverted support for specifying a `clientAuthenticationMethod` for OIDC ([#1170]).
19+
It can be added back after the SDP 26.3.0 release.
20+
21+
[#1170]: https://github.com/stackabletech/operator-rs/pull/1170
22+
23+
## [0.107.1] - 2026-03-10
24+
25+
### Added
26+
27+
- Add CRD established signal/helper ([#1167]).
28+
29+
## Changed
30+
31+
- Demote `kube_runtime::controller::Error::QueueError` to warning ([#1168]).
32+
33+
[#1167]: https://github.com/stackabletech/operator-rs/pull/1167
34+
[#1168]: https://github.com/stackabletech/operator-rs/pull/1168
35+
36+
## [0.107.0] - 2026-03-09
37+
38+
### Added
39+
40+
- Add support for specifying a `clientAuthenticationMethod` for OIDC ([#1158]).
41+
- Added two new crate features: `crds` and `kube-ws` ([#1162]).
42+
43+
### Fixed
44+
45+
- BREAKING: Fix compilation failures when not enabling default features ([#1162]).
46+
This is achieved by removing the `clap`, `telemetry` and `versioned` features, which were previously enabled by default.
47+
They have been removed as the stackable-operator code actually always requires them.
48+
49+
[#1158]: https://github.com/stackabletech/operator-rs/pull/1158
50+
[#1162]: https://github.com/stackabletech/operator-rs/pull/1162
51+
752
## [0.106.2] - 2026-02-26
853

954
### Changed

crates/stackable-operator/Cargo.toml

Lines changed: 7 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,28 +1,27 @@
11
[package]
22
name = "stackable-operator"
33
description = "Stackable Operator Framework"
4-
version = "0.106.2"
4+
version = "0.108.0"
55
authors.workspace = true
66
license.workspace = true
77
edition.workspace = true
88
repository.workspace = true
99

1010
[features]
11-
full = ["certs", "telemetry", "versioned", "time", "webhook", "clap"]
12-
default = ["telemetry", "versioned", "clap"]
11+
default = ["crds"]
12+
full = ["crds", "certs", "time", "webhook", "kube-ws"]
1313

14-
clap = []
14+
crds = ["dep:stackable-versioned"]
1515
certs = ["dep:stackable-certs"]
16-
telemetry = ["dep:stackable-telemetry"]
1716
time = ["stackable-shared/time"]
18-
versioned = ["dep:stackable-versioned"]
1917
webhook = ["dep:stackable-webhook"]
18+
kube-ws = ["kube/ws"]
2019

2120
[dependencies]
2221
stackable-certs = { path = "../stackable-certs", optional = true }
2322
stackable-operator-derive = { path = "../stackable-operator-derive" }
24-
stackable-shared = { path = "../stackable-shared", features = ["time", "jiff"] }
25-
stackable-telemetry = { path = "../stackable-telemetry", optional = true, features = ["clap"] }
23+
stackable-shared = { path = "../stackable-shared", features = ["jiff"] }
24+
stackable-telemetry = { path = "../stackable-telemetry", features = ["clap"] }
2625
stackable-versioned = { path = "../stackable-versioned", optional = true }
2726
stackable-webhook = { path = "../stackable-webhook", optional = true }
2827

crates/stackable-operator/crds/DummyCluster.yaml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,16 @@ spec:
3030
description: This field contains OIDC-specific configuration. It is only required in case OIDC is used.
3131
nullable: true
3232
properties:
33+
clientAuthenticationMethod:
34+
default: client_secret_basic
35+
description: 'The client authentication method used when communicating with the token endpoint. Defaults to `client_secret_basic`. The required contents of `clientCredentialsSecret` depend on the chosen method: secret-based methods (`client_secret_basic`, `client_secret_post`, `client_secret_jwt`) expect a client secret, while `private_key_jwt` expects a private key.'
36+
enum:
37+
- client_secret_basic
38+
- client_secret_post
39+
- client_secret_jwt
40+
- private_key_jwt
41+
- none
42+
type: string
3343
clientCredentialsSecret:
3444
description: |-
3545
A reference to the OIDC client credentials secret. The secret contains

crates/stackable-operator/src/cluster_resources.rs

Lines changed: 10 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,6 @@ use crate::{
3636
ResourceRequirementsExt, ResourceRequirementsType,
3737
},
3838
},
39-
crd::listener,
4039
deep_merger::{self, ObjectOverrides},
4140
kvp::{
4241
Label, LabelError, Labels,
@@ -221,7 +220,8 @@ impl ClusterResource for Service {}
221220
impl ClusterResource for ServiceAccount {}
222221
impl ClusterResource for RoleBinding {}
223222
impl ClusterResource for PodDisruptionBudget {}
224-
impl ClusterResource for listener::v1alpha1::Listener {}
223+
#[cfg(feature = "crds")]
224+
impl ClusterResource for crate::crd::listener::v1alpha1::Listener {}
225225

226226
impl ClusterResource for Job {
227227
fn pod_spec(&self) -> Option<&PodSpec> {
@@ -670,6 +670,13 @@ impl<'a> ClusterResources<'a> {
670670
///
671671
/// * `client` - The client which is used to access Kubernetes
672672
pub async fn delete_orphaned_resources(self, client: &Client) -> Result<()> {
673+
// We can only delete Listeners in case the "crds" feature is enabled, otherwise it's a NOP.
674+
#[cfg(feature = "crds")]
675+
let delete_listeners = self
676+
.delete_orphaned_resources_of_kind::<crate::crd::listener::v1alpha1::Listener>(client);
677+
#[cfg(not(feature = "crds"))]
678+
let delete_listeners = async { Ok(()) };
679+
673680
tokio::try_join!(
674681
self.delete_orphaned_resources_of_kind::<Service>(client),
675682
self.delete_orphaned_resources_of_kind::<StatefulSet>(client),
@@ -680,7 +687,7 @@ impl<'a> ClusterResources<'a> {
680687
self.delete_orphaned_resources_of_kind::<ServiceAccount>(client),
681688
self.delete_orphaned_resources_of_kind::<RoleBinding>(client),
682689
self.delete_orphaned_resources_of_kind::<PodDisruptionBudget>(client),
683-
self.delete_orphaned_resources_of_kind::<listener::v1alpha1::Listener>(client),
690+
delete_listeners
684691
)?;
685692

686693
Ok(())

0 commit comments

Comments
 (0)