1use std::time::Duration;
13
14use mz_dyncfg::{Config, ConfigSet};
15
16pub(crate) const MZ_METRICS_LGALLOC_MAP_REFRESH_INTERVAL: Config<Duration> = Config::new(
18 "mz_metrics_lgalloc_map_refresh_interval",
19 Duration::from_secs(600),
20 "How frequently to refresh lgalloc stats. A zero duration disables refreshing.",
21);
22
23pub(crate) const MZ_METRICS_LGALLOC_REFRESH_INTERVAL: Config<Duration> = Config::new(
25 "mz_metrics_lgalloc_refresh_interval",
26 Duration::from_secs(30),
27 "How frequently to refresh lgalloc stats. A zero duration disables refreshing.",
28);
29
30pub(crate) const MZ_METRICS_RUSAGE_REFRESH_INTERVAL: Config<Duration> = Config::new(
32 "mz_metrics_rusage_refresh_interval",
33 Duration::from_secs(30),
34 "How frequently to refresh rusage stats. A zero duration disables refreshing.",
35);
36
37pub fn all_dyncfgs(configs: ConfigSet) -> ConfigSet {
39 configs
40 .add(&MZ_METRICS_LGALLOC_MAP_REFRESH_INTERVAL)
41 .add(&MZ_METRICS_LGALLOC_REFRESH_INTERVAL)
42 .add(&MZ_METRICS_RUSAGE_REFRESH_INTERVAL)
43}