(add-worker! {:keys [worker-name body-fn schedule timeout-ms] :as config})Register and launch a periodic worker using chime.
Required keys: :worker-name (string/keyword, unique) :body-fn (0-arg fn) :timeout-ms (ms) :schedule (a chime sequence of Instants/ZonedDateTimes)
No-op if a worker with same name exists.
Returns nil.
Register and launch a periodic worker using chime. Required keys: :worker-name (string/keyword, unique) :body-fn (0-arg fn) :timeout-ms (ms) :schedule (a chime sequence of Instants/ZonedDateTimes) No-op if a worker with same name exists. Returns nil.
(stop-all-workers!)Stops all workers. Returns a map of {worker-name -> true|nil}.
Stops all workers. Returns a map of {worker-name -> true|nil}.
(stop-worker! worker-name)Stops the named worker. If force? is truthy, interrupts in-flight task(s).
Returns true if a worker was found (and shutdown initiated), else nil.
Stops the named worker. If `force?` is truthy, interrupts in-flight task(s). Returns true if a worker was found (and shutdown initiated), else nil.
cljdoc builds & hosts documentation for Clojure/Script libraries
| Ctrl+k | Jump to recent docs |
| ← | Move to previous article |
| → | Move to next article |
| Ctrl+/ | Jump to the search field |