Skip to content

Commit 576984f

Browse files
Apply suggestions from code review
Co-authored-by: maltesander <malte.sander.it@gmail.com> Co-authored-by: Siegfried Weber <mail@siegfriedweber.net>
1 parent 126da64 commit 576984f

5 files changed

Lines changed: 2 additions & 14 deletions

File tree

rust/operator-binary/src/controller.rs

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,6 @@ pub enum Error {
131131
},
132132

133133
#[snafu(display("internal operator failure"))]
134-
InternalOperatorFailure { source: crate::crd::Error },
135134

136135
#[snafu(display("failed to apply PodDisruptionBudget"))]
137136
ApplyPdb {
@@ -329,9 +328,6 @@ impl ValidatedCluster {
329328
}
330329

331330
/// Whether Kerberos is enabled for this cluster (a Kerberos `SecretClass` was configured).
332-
///
333-
/// Mirrors [`v1alpha1::HiveCluster::has_kerberos_enabled`], derived here from the validated
334-
/// config so build steps don't have to re-read the raw cluster.
335331
pub fn has_kerberos_enabled(&self) -> bool {
336332
self.cluster_config.kerberos_secret_class.is_some()
337333
}

rust/operator-binary/src/controller/build/opa.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -127,6 +127,6 @@ impl HiveOpaConfig {
127127
pub fn tls_ca_cert_mount_path(&self) -> Option<String> {
128128
self.tls_secret_class
129129
.as_ref()
130-
.map(|_| format!("/stackable/secrets/{}", &*OPA_TLS_VOLUME_NAME))
130+
.map(|_| format!("/stackable/secrets/{}", *OPA_TLS_VOLUME_NAME))
131131
}
132132
}

rust/operator-binary/src/controller/build/resource/listener.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ use crate::{
1111

1212
#[derive(Snafu, Debug)]
1313
pub enum Error {
14-
#[snafu(display("{role} listener has no adress"))]
14+
#[snafu(display("{role} listener has no address"))]
1515
RoleListenerHasNoAddress { role: String },
1616
#[snafu(display("could not find port [{port_name}] for rolegroup listener {role}"))]
1717
NoServicePort { port_name: String, role: String },

rust/operator-binary/src/controller/validate.rs

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -94,10 +94,6 @@ pub enum Error {
9494
}
9595

9696
/// Validated logging configuration for the Hive metastore and (optional) Vector container.
97-
///
98-
/// Produced up-front by [`validate_logging`] (mirroring the opensearch-operator) so that an
99-
/// invalid custom log ConfigMap name or a missing Vector aggregator discovery ConfigMap name
100-
/// fails reconciliation during validation rather than at resource-build time.
10197
#[derive(Clone, Debug, PartialEq, Eq)]
10298
pub struct ValidatedLogging {
10399
pub hive_container: ValidatedContainerLogConfigChoice,

rust/operator-binary/src/crd/mod.rs

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -2,10 +2,6 @@ use std::str::FromStr;
22

33
use databases::MetadataDatabaseConnection;
44
/// Re-export of the shared product-logging spec data types (test-only).
5-
///
6-
/// These are plain logging *data* types (also consumed by the `stackable_operator::v2` logging
7-
/// framework). Re-exporting them through `crate::crd` lets the logging validation tests reference
8-
/// them without importing the v1 `product_logging` module by its fully-qualified path.
95
#[cfg(test)]
106
pub use product_logging::spec::{
117
ConfigMapLogConfig, ContainerLogConfig, ContainerLogConfigChoice, CustomContainerLogConfig,

0 commit comments

Comments
 (0)