Skip to main content

NewSchedule

Struct NewSchedule 

Source
pub struct NewSchedule {
Show 25 fields pub path: String, pub schedule: String, pub timezone: String, pub script_path: String, pub is_flow: bool, pub args: HashMap<String, Value>, pub enabled: Option<bool>, pub on_failure: Option<String>, pub on_failure_times: Option<f64>, pub on_failure_exact: Option<bool>, pub on_failure_extra_args: Option<HashMap<String, Value>>, pub on_recovery: Option<String>, pub on_recovery_times: Option<f64>, pub on_recovery_extra_args: Option<HashMap<String, Value>>, pub on_success: Option<String>, pub on_success_extra_args: Option<HashMap<String, Value>>, pub ws_error_handler_muted: Option<bool>, pub retry: Option<Box<Retry>>, pub no_flow_overlap: Option<bool>, pub summary: Option<String>, pub description: Option<String>, pub tag: Option<String>, pub paused_until: Option<String>, pub cron_version: Option<String>, pub dynamic_skip: Option<String>,
}

Fields§

§path: String

The unique path identifier for this schedule

§schedule: String

Cron expression with 6 fields (seconds, minutes, hours, day of month, month, day of week). Example ‘0 0 12 * * *’ for daily at noon

§timezone: String

IANA timezone for the schedule (e.g., ‘UTC’, ‘Europe/Paris’, ‘America/New_York’)

§script_path: String

Path to the script or flow to execute when triggered

§is_flow: bool

True if script_path points to a flow, false if it points to a script

§args: HashMap<String, Value>

The arguments to pass to the script or flow

§enabled: Option<bool>

Whether the schedule is currently active and will trigger jobs

§on_failure: Option<String>

Path to a script or flow to run when the scheduled job fails

§on_failure_times: Option<f64>

Number of consecutive failures before the on_failure handler is triggered (default 1)

§on_failure_exact: Option<bool>

If true, trigger on_failure handler only on exactly N failures, not on every failure after N

§on_failure_extra_args: Option<HashMap<String, Value>>

The arguments to pass to the script or flow

§on_recovery: Option<String>

Path to a script or flow to run when the schedule recovers after failures

§on_recovery_times: Option<f64>

Number of consecutive successes before the on_recovery handler is triggered (default 1)

§on_recovery_extra_args: Option<HashMap<String, Value>>

The arguments to pass to the script or flow

§on_success: Option<String>

Path to a script or flow to run after each successful execution

§on_success_extra_args: Option<HashMap<String, Value>>

The arguments to pass to the script or flow

§ws_error_handler_muted: Option<bool>

If true, the workspace-level error handler will not be triggered for this schedule’s failures

§retry: Option<Box<Retry>>§no_flow_overlap: Option<bool>

If true, skip this schedule’s execution if the previous run is still in progress (prevents concurrent runs)

§summary: Option<String>

Short summary describing the purpose of this schedule

§description: Option<String>

Detailed description of what this schedule does

§tag: Option<String>

Worker tag to route jobs to specific worker groups

§paused_until: Option<String>

ISO 8601 datetime until which the schedule is paused. Schedule resumes automatically after this time

§cron_version: Option<String>

Cron parser version. Use ‘v2’ for extended syntax with additional features

§dynamic_skip: Option<String>

Path to a script that validates scheduled datetimes. Receives scheduled_for datetime and returns boolean to skip (true) or run (false)

Implementations§

Source§

impl NewSchedule

Source

pub fn new( path: String, schedule: String, timezone: String, script_path: String, is_flow: bool, args: HashMap<String, Value>, ) -> NewSchedule

Trait Implementations§

Source§

impl Clone for NewSchedule

Source§

fn clone(&self) -> NewSchedule

Returns a duplicate of the value. Read more
1.0.0 · Source§

fn clone_from(&mut self, source: &Self)

Performs copy-assignment from source. Read more
Source§

impl Debug for NewSchedule

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Default for NewSchedule

Source§

fn default() -> NewSchedule

Returns the “default value” for a type. Read more
Source§

impl<'de> Deserialize<'de> for NewSchedule

Source§

fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>
where __D: Deserializer<'de>,

Deserialize this value from the given Serde deserializer. Read more
Source§

impl PartialEq for NewSchedule

Source§

fn eq(&self, other: &NewSchedule) -> bool

Tests for self and other values to be equal, and is used by ==.
1.0.0 · Source§

fn ne(&self, other: &Rhs) -> bool

Tests for !=. The default implementation is almost always sufficient, and should not be overridden without very good reason.
Source§

impl Serialize for NewSchedule

Source§

fn serialize<__S>(&self, __serializer: __S) -> Result<__S::Ok, __S::Error>
where __S: Serializer,

Serialize this value into the given Serde serializer. Read more
Source§

impl StructuralPartialEq for NewSchedule

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> CloneToUninit for T
where T: Clone,

Source§

unsafe fn clone_to_uninit(&self, dest: *mut u8)

🔬This is a nightly-only experimental API. (clone_to_uninit)
Performs copy-assignment from self to dest. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more
Source§

fn in_current_span(self) -> Instrumented<Self>

Instruments this type with the current Span, returning an Instrumented wrapper. Read more
Source§

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> PolicyExt for T
where T: ?Sized,

Source§

fn and<P, B, E>(self, other: P) -> And<T, P>
where T: Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns Action::Follow only if self and other return Action::Follow. Read more
Source§

fn or<P, B, E>(self, other: P) -> Or<T, P>
where T: Policy<B, E>, P: Policy<B, E>,

Create a new Policy that returns Action::Follow if either self or other returns Action::Follow. Read more
Source§

impl<T> ToOwned for T
where T: Clone,

Source§

type Owned = T

The resulting type after obtaining ownership.
Source§

fn to_owned(&self) -> T

Creates owned data from borrowed data, usually by cloning. Read more
Source§

fn clone_into(&self, target: &mut T)

Uses borrowed data to replace owned data, usually by cloning. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

impl<T> DeserializeOwned for T
where T: for<'de> Deserialize<'de>,

Source§

impl<T> ErasedDestructor for T
where T: 'static,