Durable.Queue.Manager (Durable v0.1.0-rc)
View SourceSupervises queue pollers and worker supervisors.
The Manager creates a supervision tree for each configured queue:
- A DynamicSupervisor for workers
- A Poller for the queue
It also starts the StaleJobRecovery process and a Registry for looking up pollers by queue name.
Configuration
Queue configuration is passed via the Durable config:
{Durable,
repo: MyApp.Repo,
queues: %{
default: [concurrency: 10, poll_interval: 1000],
high_priority: [concurrency: 20, poll_interval: 500]
}}
Summary
Functions
Returns a specification to start this module under a supervisor.
Drains a queue, waiting for active jobs to complete.
Pauses a queue, stopping it from claiming new jobs.
Returns the list of configured queues for a Durable instance.
Resumes a paused queue.
Starts the queue manager supervisor.
Returns statistics for a queue from the adapter.
Returns the status of a queue.
Functions
Returns a specification to start this module under a supervisor.
See Supervisor.
Drains a queue, waiting for active jobs to complete.
Pauses a queue, stopping it from claiming new jobs.
Returns the list of configured queues for a Durable instance.
Resumes a paused queue.
@spec start_link(keyword()) :: Supervisor.on_start()
Starts the queue manager supervisor.
Returns statistics for a queue from the adapter.
Returns the status of a queue.