datafusion_dist/
config.rs1use std::time::Duration;
2
3#[derive(Debug, derive_with::With)]
4pub struct DistConfig {
5 pub heartbeat_interval: Duration,
6 pub stage0_task_poll_timeout: Duration,
7 pub job_ttl: Duration,
8 pub job_ttl_check_interval: Duration,
9}
10
11impl DistConfig {
12 pub fn new() -> Self {
13 Self {
14 heartbeat_interval: Duration::from_secs(20),
15 stage0_task_poll_timeout: Duration::from_secs(10),
16 job_ttl: Duration::from_secs(12 * 60 * 60),
17 job_ttl_check_interval: Duration::from_secs(10 * 60),
18 }
19 }
20}
21
22impl Default for DistConfig {
23 fn default() -> Self {
24 Self::new()
25 }
26}