Integrant wiring for the jobs module.
Config keys:
:wagoe/jobs The settings block that switches the module on: {:provider :memory | :db | :redis ; default :memory :lease-ms 60000 ; :db only, in-flight lease :redis {:host "localhost" :port 6379} :workers {:count 1 :queue-name :default}}
:wagoe/jobs-runtime Queue, store and stats from one adapter, so the three share a backend.
:wagoe/job-queue, :wagoe/job-store, :wagoe/job-stats
What other modules and the devtools dashboard take a ref to — workflow
and push already document :job-queue. Projections of the runtime rather
than components of their own, because the in-memory adapter's queue and
store must share state. :wagoe/job-stats is nil under :provider :db,
which ships no IJobStats.
:wagoe/job-registry
The handler map every module contributed. Modules contribute handlers the
way they contribute routes: a :job-handlers vector in their ig-config,
collected by wagoe.platform.shell.system.config (BOU-330 pattern).
:wagoe/job-workers
The worker pool. :count 0 builds none — that is a web node in the
web/worker split; the default of 1 is a single process that both enqueues
and runs, which is what an application without a deployment topology has.
Until BOU-418 this namespace wired none of it: :wagoe/jobs was a settings
passthrough, so java -jar wagoe.jar worker booted and processed nothing.
Integrant wiring for the jobs module.
Config keys:
:wagoe/jobs
The settings block that switches the module on:
{:provider :memory | :db | :redis ; default :memory
:lease-ms 60000 ; :db only, in-flight lease
:redis {:host "localhost" :port 6379}
:workers {:count 1 :queue-name :default}}
:wagoe/jobs-runtime
Queue, store and stats from one adapter, so the three share a backend.
:wagoe/job-queue, :wagoe/job-store, :wagoe/job-stats
What other modules and the devtools dashboard take a ref to — `workflow`
and `push` already document `:job-queue`. Projections of the runtime rather
than components of their own, because the in-memory adapter's queue and
store must share state. `:wagoe/job-stats` is nil under `:provider :db`,
which ships no IJobStats.
:wagoe/job-registry
The handler map every module contributed. Modules contribute handlers the
way they contribute routes: a `:job-handlers` vector in their `ig-config`,
collected by `wagoe.platform.shell.system.config` (BOU-330 pattern).
:wagoe/job-workers
The worker pool. `:count 0` builds none — that is a web node in the
web/worker split; the default of 1 is a single process that both enqueues
and runs, which is what an application without a deployment topology has.
Until BOU-418 this namespace wired none of it: `:wagoe/jobs` was a settings
passthrough, so `java -jar wagoe.jar worker` booted and processed nothing.(ig-config settings _ctx)This module's Integrant entries, for wagoe.platform.shell.system.config.
:handler-maps is filled in by the application's system config from what the
enabled modules contributed, the way :module-routes is — jobs cannot name
the modules that have handlers any more than the HTTP handler can name the
modules that have routes.
This module's Integrant entries, for `wagoe.platform.shell.system.config`. `:handler-maps` is filled in by the application's system config from what the enabled modules contributed, the way `:module-routes` is — jobs cannot name the modules that have handlers any more than the HTTP handler can name the modules that have routes.
(normalize-provider provider)The provider keyword in the vocabulary cache, realtime, events and jobs
share: :memory | :redis, and :db — which this is the only module to
have, because it is the only one with a database adapter.
Jobs already spelled it this way; :in-memory and :database are accepted
because the other three modules used them, and a user moving between config
blocks should not have to remember which is which (BOU-436).
The provider keyword in the vocabulary cache, realtime, events and jobs share: `:memory` | `:redis`, and `:db` — which this is the only module to have, because it is the only one with a database adapter. Jobs already spelled it this way; `:in-memory` and `:database` are accepted because the other three modules used them, and a user moving between config blocks should not have to remember which is which (BOU-436).
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 |