pub struct IntervalsSection {
pub blob_collect_secs: Option<u64>,
pub confinement_poll_secs: Option<u64>,
pub health_secs: Option<u64>,
pub tree_reload_secs: Option<u64>,
}Expand description
How often each background loop runs.
Every one of these trades freshness against load, and they are set apart because they load different things: one talks to a DNS provider with its own rate limits, one walks this server’s own disk, and one only reads state already in memory.
Reload: needs a restart. Each loop is handed its period when it is spawned.
Fields§
§blob_collect_secs: Option<u64>Seconds between passes of the blob collector, which reclaims upload bytes nothing references once their grace window has passed.
Reasonable range: 300 to 86_400 — five minutes to a day.
This is how promptly deleted bytes come back, and each pass walks every account’s blobs. Five minutes suits a deployment near its quota, where the disk is the scarce thing. A day suits one with room to spare, where the walk is the more expensive half. Nothing is lost by a long period: a blob past its grace window stays collectable until a pass reaches it. The built-in default is an hour.
confinement_poll_secs: Option<u64>Seconds between passes of the confinement poll, which notices an account whose hostname no longer resolves the way this server published it.
Reasonable range: 60 to 3600 — a minute to an hour.
Each pass reads records back from the DNS provider, so this is the knob that decides how much of a provider’s rate limit this deployment spends on noticing drift. A minute catches a hijacked or clobbered record fast and costs the most requests; an hour is cheaper and leaves a wrong record standing longer. The built-in default is five minutes.
health_secs: Option<u64>Seconds between health ticks, which refresh what bot.did.stats and
the dashboard report about this server’s own state.
Reasonable range: 5 to 300 — five seconds to five minutes.
This one costs nothing outside the process: it reads state already in memory, so the period is how stale a readout may be rather than a load question. Match it to whatever scrapes the dashboard. The built-in default is ten seconds.
tree_reload_secs: Option<u64>Seconds between re-reads of this configuration file for [tree]’s
three bounds, which take effect without a restart.
Reasonable range: 5 to 3600 — five seconds to an hour.
Each pass reads and parses one local file, so the period is how long an operator waits for an edit to take rather than a load question. Five seconds suits raising a cap that is refusing work right now; an hour suits a file nobody edits. The built-in default is thirty seconds.
Trait Implementations§
Source§impl Clone for IntervalsSection
impl Clone for IntervalsSection
Source§fn clone(&self) -> IntervalsSection
fn clone(&self) -> IntervalsSection
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for IntervalsSection
impl Debug for IntervalsSection
Source§impl Default for IntervalsSection
impl Default for IntervalsSection
Source§fn default() -> IntervalsSection
fn default() -> IntervalsSection
Source§impl<'de> Deserialize<'de> for IntervalsSection
impl<'de> Deserialize<'de> for IntervalsSection
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Source§impl PartialEq for IntervalsSection
impl PartialEq for IntervalsSection
Source§fn eq(&self, other: &IntervalsSection) -> bool
fn eq(&self, other: &IntervalsSection) -> bool
self and other values to be equal, and is used by ==.