Scheduler
Calls
cancel
Cancel an anonymously scheduled task.
Namespace
api.tx.scheduler.cancelType
function cancel(
when: u32,
index: u32
)cancelNamed
Cancel a named scheduled task.
Namespace
api.tx.scheduler.cancelNamedType
function cancelNamed(
id: Bytes
)schedule
Anonymously schedule a task.
Namespace
api.tx.scheduler.scheduleType
function schedule(
when: u32,
maybe_periodic: Option<(u32,u32)>,
priority: u8,
call: FrameSupportScheduleMaybeHashed
)scheduleAfter
Anonymously schedule a task after a delay.
Namespace
api.tx.scheduler.scheduleAfterType
function scheduleAfter(
after: u32,
maybe_periodic: Option<(u32,u32)>,
priority: u8,
call: FrameSupportScheduleMaybeHashed
)scheduleNamed
Schedule a named task.
Namespace
api.tx.scheduler.scheduleNamedType
function scheduleNamed(
id: Bytes,
when: u32,
maybe_periodic: Option<(u32,u32)>,
priority: u8,
call: FrameSupportScheduleMaybeHashed
)scheduleNamedAfter
Schedule a named task after a delay.
Namespace
api.tx.scheduler.scheduleNamedAfterType
function scheduleNamedAfter(
id: Bytes,
after: u32,
maybe_periodic: Option<(u32,u32)>,
priority: u8,
call: FrameSupportScheduleMaybeHashed
)Storage
agenda
Items to be executed, indexed by the block number that they should be executed on.
Namespace
api.query.scheduler.agendaType
function agenda(
u32
): Vec<Option<PalletSchedulerScheduledV3>>lookup
Lookup from identity to the block number and index of the task.
Namespace
api.query.scheduler.lookupType
function lookup(
Bytes
): Option<(u32,u32)>Events
CallLookupFailed
The call for the provided hash was not found so the task has been aborted.
Namespace
api.events.scheduler.CallLookupFailedType
type CallLookupFailed = {
task: (u32,u32),
id: Option<Bytes>,
error: FrameSupportScheduleLookupError
}Canceled
Canceled some task.
Namespace
api.events.scheduler.CanceledType
type Canceled = {
when: u32,
index: u32
}Dispatched
Dispatched some task.
Namespace
api.events.scheduler.DispatchedType
type Dispatched = {
task: (u32,u32),
id: Option<Bytes>,
result: Result<Null, SpRuntimeDispatchError>
}Scheduled
Scheduled some task.
Namespace
api.events.scheduler.ScheduledType
type Scheduled = {
when: u32,
index: u32
}Errors
FailedToSchedule
Failed to schedule a call
Namespace
api.errors.scheduler.FailedToScheduleNotFound
Cannot find the scheduled call.
Namespace
api.errors.scheduler.NotFoundRescheduleNoChange
Reschedule failed because it does not change scheduled time.
Namespace
api.errors.scheduler.RescheduleNoChangeTargetBlockNumberInPast
Given target block number is in the past.
Namespace
api.errors.scheduler.TargetBlockNumberInPastConstants
maximumWeight
The maximum weight that may be scheduled per block for any dispatchables of less priority than schedule::HARD_DEADLINE.
Namespace
api.consts.scheduler.maximumWeightType
type maximumWeight = WeightV1maxScheduledPerBlock
The maximum number of scheduled calls in the queue for a single block. Not strictly enforced, but used for weight estimation.
Namespace
api.consts.scheduler.maxScheduledPerBlockType
type maxScheduledPerBlock = u32