pub struct Schedule {
pub id: String,
pub description: String,
pub cron: String,
pub jitter_ms: u64,
pub missed_run_policy: MissedRunPolicy,
pub locking: LockingHint,
pub config_json: String,
}Expand description
A single declared schedule.
The cron field accepts the same syntax as bext-core::scheduler::Schedule::parse:
- simple intervals:
"30s","5m","2h" - cron
*/Nsubset:"*/5 * * * *","0 */3 * * *" - shortcuts:
"@hourly","@daily"
Invalid expressions are rejected at plugin load time (the host parses before registering), so a plugin that returns a bad expression fails to start with a clear error.
Fields§
§id: StringStable identifier passed back to ScheduledPlugin::run. Must be
unique within a plugin. Used as the locking key and as the
dashboard / metrics label.
description: StringHuman-readable description for the dev dashboard. Optional.
cron: StringSchedule expression. See module docs for accepted syntax.
jitter_ms: u64Maximum random delay applied to each tick, in milliseconds. Use non-zero jitter for jobs that several plugins might fire simultaneously (e.g., a 60s job with 5000ms jitter spreads load across a 5-second window). Zero means no jitter.
missed_run_policy: MissedRunPolicyBehavior when the scheduler detects a missed run.
locking: LockingHintMulti-instance coordination hint. Ignored until Locking lands
in E2.
config_json: StringOpaque per-schedule config the plugin can use to parameterize its
run logic. Encoded as a JSON string for WASM ABI compatibility
(matches the convention in crate::lifecycle::LifecyclePlugin).
Empty string means “no config”.