Skip to content

Commit 440ba50

Browse files
committed
refactor: move graceful shutdown to controller/build
1 parent 8c8ce80 commit 440ba50

5 files changed

Lines changed: 3 additions & 4 deletions

File tree

rust/operator-binary/src/operations/graceful_shutdown.rs renamed to rust/operator-binary/src/controller/build/graceful_shutdown.rs

File renamed without changes.

rust/operator-binary/src/controller/build.rs renamed to rust/operator-binary/src/controller/build/mod.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@ stackable_operator::constant!(pub(crate) PLACEHOLDER_LISTENER_ROLE_GROUP: RoleGr
1616
// deployed. A constant value keeps the labels stable across version upgrades.
1717
stackable_operator::constant!(pub(crate) UNVERSIONED_PRODUCT_VERSION: ProductVersion = "none");
1818

19+
pub mod graceful_shutdown;
1920
pub mod jvm;
2021
pub mod properties;
2122
pub mod resource;

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

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,7 @@ use crate::{
3737
controller::{
3838
build::{
3939
UNVERSIONED_PRODUCT_VERSION,
40+
graceful_shutdown::add_graceful_shutdown_config,
4041
properties::product_logging::MAX_DRUID_LOG_FILES_SIZE,
4142
resource::listener::{
4243
LISTENER_VOLUME_DIR, LISTENER_VOLUME_NAME, build_group_listener_pvc,
@@ -50,7 +51,6 @@ use crate::{
5051
LOG_CONFIG_DIRECTORY, METRICS_PORT, METRICS_PORT_NAME, RW_CONFIG_DIRECTORY,
5152
STACKABLE_LOG_DIR, ValidatedDruidConfig,
5253
},
53-
operations::graceful_shutdown::add_graceful_shutdown_config,
5454
};
5555

5656
// volume names
@@ -65,7 +65,7 @@ const USERDATA_MOUNTPOINT: &str = "/stackable/userdata";
6565
pub enum Error {
6666
#[snafu(display("failed to configure graceful shutdown"))]
6767
GracefulShutdown {
68-
source: crate::operations::graceful_shutdown::Error,
68+
source: crate::controller::build::graceful_shutdown::Error,
6969
},
7070

7171
#[snafu(display("failed to add OIDC Volumes and VolumeMounts to the Pod and containers"))]

rust/operator-binary/src/main.rs

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -42,7 +42,6 @@ mod controller;
4242
mod crd;
4343
mod extensions;
4444
mod internal_secret;
45-
mod operations;
4645
mod webhooks;
4746

4847
mod built_info {

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

Lines changed: 0 additions & 1 deletion
This file was deleted.

0 commit comments

Comments
 (0)