pub struct EngineConfig {
pub write_period_secs: u64,
pub policy_file: Option<PathBuf>,
pub server_ioc_drift_secs: u64,
pub write_shards: usize,
pub per_shard_buffer: usize,
}Expand description
EPICS CA engine configuration.
Fields§
§write_period_secs: u64Write period in seconds — how often buffered samples flush to storage.
policy_file: Option<PathBuf>Path to PV policy TOML file.
server_ioc_drift_secs: u64Maximum allowed drift between IOC-reported sample timestamps and
the appliance’s wall clock, in either direction (Java parity
6538631 — org.epics.archiverappliance.engine.epics.SERVER_IOC_DRIFT_SECONDS).
Default 30 minutes; set higher for known-skewed sites without
recompiling.
write_shards: usizeNumber of parallel write-loop shards. 1 (the default)
keeps the legacy single-worker layout. Sites with many
active PVs and a fast STS can raise this to e.g. 4–16; the
engine spawns a dispatcher that hashes pv_name to a fixed
shard so per-PV ordering is preserved while different PVs
can append concurrently.
per_shard_buffer: usizePer-shard mpsc capacity. Only consulted when
write_shards > 1. The dispatcher try_sends into each
shard channel — when a shard is saturated its overflow is
dropped and recorded on the per-PV buffer_overflow_drops
counter, while OTHER shards keep flowing (per-shard
isolation).
Trait Implementations§
Source§impl Clone for EngineConfig
impl Clone for EngineConfig
Source§fn clone(&self) -> EngineConfig
fn clone(&self) -> EngineConfig
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more