This commit is contained in:
@@ -12,7 +12,6 @@ use store::{
|
||||
rand::{distributions::Alphanumeric, thread_rng, Rng},
|
||||
Stores,
|
||||
};
|
||||
use tracing_appender::non_blocking::WorkerGuard;
|
||||
use utils::{
|
||||
config::{Config, ConfigKey},
|
||||
failed, UnwrapFailure,
|
||||
@@ -32,7 +31,6 @@ pub struct BootManager {
|
||||
pub config: Config,
|
||||
pub core: SharedCore,
|
||||
pub servers: Servers,
|
||||
pub guards: Option<Vec<WorkerGuard>>,
|
||||
}
|
||||
|
||||
const HELP: &str = r#"Stalwart Mail Server
|
||||
@@ -164,7 +162,7 @@ impl BootManager {
|
||||
}
|
||||
|
||||
// Enable tracing
|
||||
let guards = Tracers::parse(&mut config).enable(&mut config);
|
||||
Tracers::parse(&mut config).enable();
|
||||
|
||||
match import_export {
|
||||
ImportExport::None => {
|
||||
@@ -323,7 +321,6 @@ impl BootManager {
|
||||
|
||||
BootManager {
|
||||
core,
|
||||
guards,
|
||||
config,
|
||||
servers,
|
||||
}
|
||||
|
||||
@@ -23,6 +23,7 @@ use super::config::{ConfigManager, Patterns};
|
||||
pub struct ReloadResult {
|
||||
pub config: Config,
|
||||
pub new_core: Option<Core>,
|
||||
pub tracers: Option<Tracers>,
|
||||
}
|
||||
|
||||
impl Core {
|
||||
@@ -75,6 +76,7 @@ impl Core {
|
||||
Ok(ReloadResult {
|
||||
config,
|
||||
new_core: core.into(),
|
||||
tracers: None,
|
||||
})
|
||||
}
|
||||
|
||||
@@ -82,7 +84,7 @@ impl Core {
|
||||
let mut config = self.storage.config.build_config("").await?;
|
||||
|
||||
// Parse tracers
|
||||
Tracers::parse(&mut config);
|
||||
let tracers = Tracers::parse(&mut config);
|
||||
|
||||
// Load stores
|
||||
let mut stores = Stores {
|
||||
@@ -136,6 +138,7 @@ impl Core {
|
||||
ReloadResult {
|
||||
config,
|
||||
new_core: core.into(),
|
||||
tracers: tracers.into(),
|
||||
}
|
||||
} else {
|
||||
config.into()
|
||||
@@ -148,6 +151,7 @@ impl From<Config> for ReloadResult {
|
||||
Self {
|
||||
config,
|
||||
new_core: None,
|
||||
tracers: None,
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user