Skip to content

Commit ee9866f

Browse files
committed
feat(versioned)!: Make the crd(doc = "...") argument required
Following review feedback on #1228, the `doc` argument is now mandatory so that every CRD ships a meaningful root description instead of the generic "Auto-generated derived type ..." string. - StructCrdArguments.doc: Option<String> -> String (required via darling) - codegen always emits `doc = ...` in the generated #[kube(...)] - add doc to all CRDs defined in stackable-operator (AuthenticationClass, Listener, ListenerClass, PodListeners, S3Bucket, S3Connection, Scaler) - add doc to all macro test inputs / doc examples; regenerate snapshots - regenerate committed CRD YAMLs
1 parent 093e3b9 commit ee9866f

38 files changed

Lines changed: 114 additions & 41 deletions

crates/stackable-operator/CHANGELOG.md

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

55
## [Unreleased]
66

7+
### Added
8+
9+
- Add root descriptions to all CRDs defined in this crate (`AuthenticationClass`, `Listener`,
10+
`ListenerClass`, `PodListeners`, `S3Bucket`, `S3Connection`, `Scaler`), now that the `versioned`
11+
macro requires a `doc` argument ([#1228]).
12+
13+
[#1228]: https://github.com/stackabletech/operator-rs/pull/1228
14+
715
## [0.112.0] - 2026-06-22
816

917
### Added

crates/stackable-operator/crds/AuthenticationClass.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ spec:
1717
name: v1alpha1
1818
schema:
1919
openAPIV3Schema:
20-
description: Auto-generated derived type for AuthenticationClassSpec via `CustomResource`
20+
description: The Stackable Platform uses the AuthenticationClass as a central mechanism to handle user authentication across supported products.
2121
properties:
2222
spec:
2323
description: |-

crates/stackable-operator/crds/Listener.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ spec:
1717
name: v1alpha1
1818
schema:
1919
openAPIV3Schema:
20-
description: Auto-generated derived type for ListenerSpec via `CustomResource`
20+
description: Exposes a set of pods to the outside world.
2121
properties:
2222
spec:
2323
description: |-

crates/stackable-operator/crds/ListenerClass.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ spec:
1717
name: v1alpha1
1818
schema:
1919
openAPIV3Schema:
20-
description: Auto-generated derived type for ListenerClassSpec via `CustomResource`
20+
description: Defines a policy for how Listeners should be exposed.
2121
properties:
2222
spec:
2323
description: |-

crates/stackable-operator/crds/PodListeners.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ spec:
1717
name: v1alpha1
1818
schema:
1919
openAPIV3Schema:
20-
description: Auto-generated derived type for PodListenersSpec via `CustomResource`
20+
description: Informs users about Listeners that are bound by a given Pod.
2121
properties:
2222
spec:
2323
description: |-

crates/stackable-operator/crds/S3Bucket.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ spec:
1717
name: v1alpha1
1818
schema:
1919
openAPIV3Schema:
20-
description: Auto-generated derived type for BucketSpec via `CustomResource`
20+
description: S3 bucket specification containing the bucket name and an inlined or referenced connection specification.
2121
properties:
2222
spec:
2323
description: |-

crates/stackable-operator/crds/S3Connection.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ spec:
1717
name: v1alpha1
1818
schema:
1919
openAPIV3Schema:
20-
description: Auto-generated derived type for ConnectionSpec via `CustomResource`
20+
description: A reusable definition of a connection to an S3 endpoint.
2121
properties:
2222
spec:
2323
description: |-

crates/stackable-operator/crds/Scaler.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ spec:
1717
name: v1alpha1
1818
schema:
1919
openAPIV3Schema:
20-
description: Auto-generated derived type for ScalerSpec via `CustomResource`
20+
description: Controls the replica count of a Stackable component, integrating with the Kubernetes scale subresource to enable horizontal autoscaling.
2121
properties:
2222
spec:
2323
properties:

crates/stackable-operator/src/crd/authentication/core/mod.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ pub mod versioned {
3636
#[versioned(crd(
3737
group = "authentication.stackable.tech",
3838
plural = "authenticationclasses",
39+
doc = "The Stackable Platform uses the AuthenticationClass as a central mechanism to handle user authentication across supported products.",
3940
))]
4041
#[derive(
4142
Clone,

crates/stackable-operator/src/crd/listener/class/mod.rs

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,10 @@ pub mod versioned {
2525
/// Defines a policy for how [Listeners](DOCS_BASE_URL_PLACEHOLDER/listener-operator/listener) should be exposed.
2626
/// Read the [ListenerClass documentation](DOCS_BASE_URL_PLACEHOLDER/listener-operator/listenerclass)
2727
/// for more information.
28-
#[versioned(crd(group = "listeners.stackable.tech"))]
28+
#[versioned(crd(
29+
group = "listeners.stackable.tech",
30+
doc = "Defines a policy for how Listeners should be exposed.",
31+
))]
2932
#[derive(CustomResource, Serialize, Deserialize, Clone, Debug, JsonSchema, PartialEq)]
3033
#[serde(rename_all = "camelCase")]
3134
pub struct ListenerClassSpec {

0 commit comments

Comments
 (0)