Skip to content

Commit

Permalink
Increase slow code log thresholds (ZcashFoundation#4997)
Browse files Browse the repository at this point in the history
  • Loading branch information
teor2345 authored Sep 1, 2022
1 parent c322533 commit 422da6e
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions zebra-chain/src/diagnostic.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,14 @@ use std::time::{Duration, Instant};
use crate::fmt::duration_short;

/// The default minimum info-level message time.
pub const DEFAULT_MIN_INFO_TIME: Duration = Duration::from_secs(5);
///
/// This is high enough to ignore most slow code.
pub const DEFAULT_MIN_INFO_TIME: Duration = Duration::from_secs(5 * 60);

/// The default minimum warning message time.
pub const DEFAULT_MIN_WARN_TIME: Duration = Duration::from_secs(20);
///
/// This is a little lower than the block verify timeout.
pub const DEFAULT_MIN_WARN_TIME: Duration = Duration::from_secs(9 * 60);

/// A guard that logs code execution time when dropped.
#[derive(Debug)]
Expand Down

0 comments on commit 422da6e

Please sign in to comment.