Skip to content

Commit 1cd0401

Browse files
committed
fix: remove result from product logging
1 parent 6740e26 commit 1cd0401

2 files changed

Lines changed: 2 additions & 41 deletions

File tree

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

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -41,12 +41,6 @@ pub enum Error {
4141
source: stackable_operator::builder::meta::Error,
4242
},
4343

44-
#[snafu(display("failed to add the logging configuration to the ConfigMap {cm_name:?}"))]
45-
InvalidLoggingConfig {
46-
source: crate::product_logging::Error,
47-
cm_name: String,
48-
},
49-
5044
#[snafu(display("cannot build config map for role {role:?} and role group {role_group:?}"))]
5145
Assemble {
5246
source: stackable_operator::builder::configmap::Error,
@@ -145,11 +139,7 @@ pub fn build_rolegroup_config_map(
145139
builder.add_data(ConfigFileName::SslClient.to_string(), ssl_client_xml);
146140
}
147141

148-
extend_role_group_config_map(rolegroup_ref, rg.merged_config.logging(), &mut builder).context(
149-
InvalidLoggingConfigSnafu {
150-
cm_name: rolegroup_ref.object_name(),
151-
},
152-
)?;
142+
extend_role_group_config_map(rolegroup_ref, rg.merged_config.logging(), &mut builder);
153143

154144
builder.build().with_context(|_| AssembleSnafu {
155145
role: rolegroup_ref.role.clone(),

rust/operator-binary/src/product_logging.rs

Lines changed: 1 addition & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
use snafu::Snafu;
21
use stackable_operator::{
32
builder::configmap::ConfigMapBuilder,
43
memory::BinaryMultiple,
@@ -16,32 +15,6 @@ use crate::{
1615
hbase_controller::MAX_HBASE_LOG_FILES_SIZE,
1716
};
1817

19-
#[derive(Snafu, Debug)]
20-
pub enum Error {
21-
#[snafu(display("object has no namespace"))]
22-
ObjectHasNoNamespace,
23-
24-
#[snafu(display("failed to retrieve the ConfigMap [{cm_name}]"))]
25-
ConfigMapNotFound {
26-
source: stackable_operator::client::Error,
27-
cm_name: String,
28-
},
29-
30-
#[snafu(display("failed to retrieve the entry [{entry}] for ConfigMap [{cm_name}]"))]
31-
MissingConfigMapEntry {
32-
entry: &'static str,
33-
cm_name: String,
34-
},
35-
36-
#[snafu(display("crd validation failure"))]
37-
CrdValidationFailure { source: crate::crd::Error },
38-
39-
#[snafu(display("vectorAggregatorConfigMapName must be set"))]
40-
MissingVectorAggregatorAddress,
41-
}
42-
43-
type Result<T, E = Error> = std::result::Result<T, E>;
44-
4518
const CONSOLE_CONVERSION_PATTERN: &str = "%d{ISO8601} %-5p [%t] %c{2}: %.1000m%n";
4619
const HBASE_LOG4J2_FILE: &str = "hbase.log4j2.xml";
4720
pub const LOG4J2_CONFIG_FILE: &str = "log4j2.properties";
@@ -54,7 +27,7 @@ pub fn extend_role_group_config_map(
5427
rolegroup: &RoleGroupRef<v1alpha1::HbaseCluster>,
5528
logging: &Logging<Container>,
5629
cm_builder: &mut ConfigMapBuilder,
57-
) -> Result<()> {
30+
) {
5831
if let Some(ContainerLogConfig {
5932
choice: Some(ContainerLogConfigChoice::Automatic(log_config)),
6033
}) = logging.containers.get(&Container::Hbase)
@@ -77,8 +50,6 @@ pub fn extend_role_group_config_map(
7750
product_logging::framework::create_vector_config(rolegroup, vector_log_config),
7851
);
7952
}
80-
81-
Ok(())
8253
}
8354

8455
fn log4j_config(log_config: &AutomaticContainerLogConfig) -> String {

0 commit comments

Comments
 (0)