Exq.Worker.Server (exq v0.19.0) View Source
Worker process is responsible for the parsing and execution of a Job.
It then broadcasts results to Stats / Manager.
Currently uses the terminate
callback to track job success/failure.
Initialization:
job_serialized
- Full JSON payload of the Job.manager
- Manager process pid.queue
- The queue the job came from.stats
- Stats process pid.namespace
- Redis namespacehost
- Host name
Expects :work message after initialization to kickoff work.
Link to this section Summary
Functions
Returns a specification to start this module under a supervisor.
Kickoff work associated with worker.
Callback implementation for GenServer.init/1
.
Kickoff work associated with worker.
Link to this section Functions
Returns a specification to start this module under a supervisor.
See Supervisor
.
Kickoff work associated with worker.
This step handles:
- Parsing of JSON object
- Preparation of target module
Calls :dispatch to then call target module.
Callback implementation for GenServer.init/1
.
Link to this function
start_link(job_serialized, manager, queue, stats, namespace, host, redis, middleware, metadata)
View SourceKickoff work associated with worker.