Skip to content

Commit a60d881

Browse files
committed
Merge remote-tracking branch 'origin/main' into chore/kube-2.0.0
2 parents 20ddb60 + ef89fdb commit a60d881

File tree

10 files changed

+70
-30
lines changed

10 files changed

+70
-30
lines changed

.github/ISSUE_TEMPLATE/release-workspace-members.md

Lines changed: 21 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -31,30 +31,31 @@ Replace the items in the task lists below with the applicable Pull Requests
3131
> [!NOTE]
3232
> The PR is usually titled: `chore: Bump Rust version and workflow actions`
3333
34-
1. Adjust the version of the channel in the `rust-toolchain.toml` file. See
35-
<https://releases.rs>.
36-
2. Adjust the version `RUST_TOOLCHAIN_VERSION` in the workflows:
37-
- `.github/workflows/build.yml`
38-
- `.github/workflows/pre_commit.yaml`
39-
- `.github/workflows/publish-docs.yaml`
40-
3. Add a changelog entry.
41-
4. Update any actions (using the Git commit hash) in the workflows. Hint: Also
42-
make sure that the `cargo-udeps` action is up-to-date, otherwise the CI might
43-
report errors.
34+
- [ ] Adjust the version of the channel in the `rust-toolchain.toml` file. See <https://releases.rs>.
35+
- [ ] Adjust the version `RUST_TOOLCHAIN_VERSION` in the workflows:
36+
- `.github/workflows/build.yml`
37+
- `.github/workflows/pre_commit.yaml`
38+
- `.github/workflows/publish-docs.yaml`
39+
- [ ] Also adjust the nightly Rust toolchain version used for formatting (this should be kept in
40+
sync across here, operator-templating and docker-images).
41+
- `.github/workflows/pre_commit.yaml`
42+
- `.vscode/settings.json`
43+
- [ ] Add a changelog entry.
44+
- [ ] Update any actions (using the Git commit hash) in the workflows. Hint: Also make sure that the
45+
`cargo-udeps` action is up-to-date, otherwise the CI might report errors.
4446

4547
## Update Rust Dependencies
4648

4749
> [!NOTE]
4850
> This PR is usually titled: `chore: Bump Rust dependencies`
4951
50-
1. Bump minor versions of dependencies in the `Cargo.toml` manifest.
51-
2. Then run the `cargo update` command.
52-
3. Fix any code which needs updating due to the dependency bumps.
53-
4. Locally update any product operator to identify any breaking changes
54-
downstream.
55-
- Hint: Use the `[patch."https://github.com/..."]` mechanism to temporarily
56-
override the dependency.
57-
5. Add a changelog entry if required.
52+
- [ ] Bump minor versions of dependencies in the `Cargo.toml` manifest.
53+
- [ ] Then run the `cargo update` command.
54+
- [ ] Fix any code which needs updating due to the dependency bumps.
55+
- [ ] Locally update any product operator to identify any breaking changes downstream.
56+
- Hint: Use the `[patch."https://github.com/..."]` mechanism to temporarily override the
57+
dependency.
58+
- [ ] Add a changelog entry if required.
5859

5960
## Adjust and Verify Crate Versions
6061

@@ -72,5 +73,5 @@ Replace the items in the task lists below with the applicable Pull Requests
7273
> [!NOTE]
7374
> The PR is usually titled: `chore: Release workspace members`
7475
75-
1. Bump the crate versions in their appropriate `Cargo.toml` manifests.
76-
2. Verify the previous step using `.scripts/verify_crate_versions.sh`.
76+
- [ ] Bump the crate versions in their appropriate `Cargo.toml` manifests.
77+
- [ ] Verify the previous step using `.scripts/verify_crate_versions.sh`.

Cargo.lock

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

crates/stackable-operator/CHANGELOG.md

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

77
### Added
88

9+
- Extend `ObjectMetaBuilder` with `finalizers` ([#1094]).
10+
11+
[#1094]: https://github.com/stackabletech/operator-rs/pull/1094
12+
13+
## [0.97.0] - 2025-09-09
14+
15+
### Added
16+
917
- BREAKING: Add a new CLI flag/env to disabling CRD maintenance: `--disable-crd-maintenance` ([#1085]).
1018

1119
### Changed

crates/stackable-operator/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
[package]
22
name = "stackable-operator"
33
description = "Stackable Operator Framework"
4-
version = "0.96.0"
4+
version = "0.97.0"
55
authors.workspace = true
66
license.workspace = true
77
edition.workspace = true

crates/stackable-operator/src/builder/meta.rs

Lines changed: 29 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -24,12 +24,13 @@ pub enum Error {
2424
/// It is strongly recommended to always call [`Self::with_recommended_labels()`]!
2525
#[derive(Clone, Default)]
2626
pub struct ObjectMetaBuilder {
27-
ownerreference: Option<OwnerReference>,
2827
annotations: Option<Annotations>,
28+
finalizers: Option<Vec<String>>,
2929
generate_name: Option<String>,
30-
namespace: Option<String>,
3130
labels: Option<Labels>,
31+
namespace: Option<String>,
3232
name: Option<String>,
33+
ownerreference: Option<OwnerReference>,
3334
}
3435

3536
impl ObjectMetaBuilder {
@@ -163,6 +164,26 @@ impl ObjectMetaBuilder {
163164
Ok(self)
164165
}
165166

167+
/// This adds a single finalizer to the existing finalizers.
168+
pub fn with_finalizer(&mut self, finalizer: impl Into<String>) -> &mut Self {
169+
self.finalizers
170+
.get_or_insert(Vec::new())
171+
.push(finalizer.into());
172+
self
173+
}
174+
175+
/// This adds multiple finalizers to the existing finalizers.
176+
pub fn with_finalizers(&mut self, finalizers: Vec<String>) -> &mut Self {
177+
self.finalizers.get_or_insert(Vec::new()).extend(finalizers);
178+
self
179+
}
180+
181+
/// This will replace all existing finalizers
182+
pub fn finalizers(&mut self, finalizers: Vec<String>) -> &mut Self {
183+
self.finalizers = Some(finalizers);
184+
self
185+
}
186+
166187
pub fn build(&self) -> ObjectMeta {
167188
// NOTE (Techassi): Shouldn't this take self instead of &self to consume
168189
// the builder and build ObjectMeta without cloning?
@@ -187,6 +208,7 @@ impl ObjectMetaBuilder {
187208
.map(|ownerreference| vec![ownerreference.clone()]),
188209
labels: self.labels.clone().map(|l| l.into()),
189210
annotations: self.annotations.clone().map(|a| a.into()),
211+
finalizers: self.finalizers.clone(),
190212
..ObjectMeta::default()
191213
}
192214
}
@@ -339,6 +361,7 @@ mod tests {
339361
})
340362
.unwrap()
341363
.with_annotation(("foo", "bar").try_into().unwrap())
364+
.with_finalizer("finalizer")
342365
.build();
343366

344367
assert_eq!(meta.generate_name, Some("generate_foo".to_string()));
@@ -352,5 +375,9 @@ mod tests {
352375
meta.annotations.as_ref().unwrap().get(&"foo".to_string()),
353376
Some(&"bar".to_string())
354377
);
378+
assert_eq!(
379+
meta.finalizers.as_ref().unwrap().first(),
380+
Some(&"finalizer".to_string())
381+
);
355382
}
356383
}

crates/stackable-versioned-macros/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "stackable-versioned-macros"
3-
version = "0.8.1"
3+
version = "0.8.2"
44
authors.workspace = true
55
license.workspace = true
66
edition.workspace = true

crates/stackable-versioned/CHANGELOG.md

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

55
## [Unreleased]
66

7+
## [0.8.2] - 2025-09-09
8+
79
### Added
810

911
- Add new `#[versioned(hint)]` argument to provide type hints for struct fields ([#1089]).

crates/stackable-versioned/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "stackable-versioned"
3-
version = "0.8.1"
3+
version = "0.8.2"
44
authors.workspace = true
55
license.workspace = true
66
edition.workspace = true

crates/stackable-webhook/CHANGELOG.md

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

55
## [Unreleased]
66

7+
## [0.6.0] - 2025-09-09
8+
79
### Added
810

911
- BREAKING: Support disabling CRD maintenance using a new boolean flag in `ConversionWebhookOptions` ([#1085]).

crates/stackable-webhook/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "stackable-webhook"
3-
version = "0.5.0"
3+
version = "0.6.0"
44
authors.workspace = true
55
license.workspace = true
66
edition.workspace = true

0 commit comments

Comments
 (0)