Liking cljdoc? Tell your friends :D

on-and-on.component

Component integration for scheduler pools and tasks.

Component integration for scheduler pools and tasks.
raw docstring

create-poolclj

(create-pool {:keys [name] :as opts})

Creates a scheduler pool component.

Creates a scheduler pool component.
raw docstring

create-taskclj

(create-task {:keys [name period-ms schedule delay-ms handler]
              :or {delay-ms 0}})

Creates a scheduled task component. Requires a :scheduler dependency.

Supports two scheduling modes (mutually exclusive):

  • :period-ms — fixed-rate interval in milliseconds
  • :schedule — Quartz cron expression string

Options:

  • :name — task name (required)
  • :handler — function called each tick, receives the component map (required)
  • :period-ms — interval in ms for fixed-rate scheduling
  • :schedule — cron expression for cron-based scheduling
  • :delay-ms — initial delay in ms (only when period-ms is provided, ignored when cron schedule is used, default 0)
Creates a scheduled task component. Requires a :scheduler dependency.

Supports two scheduling modes (mutually exclusive):
- `:period-ms` — fixed-rate interval in milliseconds
- `:schedule` — Quartz cron expression string

Options:
- `:name` — task name (required)
- `:handler` — function called each tick, receives the component map (required)
- `:period-ms` — interval in ms for fixed-rate scheduling
- `:schedule` — cron expression for cron-based scheduling
- `:delay-ms` — initial delay in ms (only when `period-ms` is provided, ignored when cron `schedule` is used, default 0)
raw docstring

cljdoc builds & hosts documentation for Clojure/Script libraries

Keyboard shortcuts
Ctrl+kJump to recent docs
Move to previous article
Move to next article
Ctrl+/Jump to the search field
× close