Machinery is an asynchronous task queue and job queue based on distributed message passing, written in Go.
The tool addresses the need to execute work asynchronously across distributed systems by decoupling task producers from task consumers through message brokers. Tasks are defined as Go functions, registered with the system, and sent to a broker where worker processes consume and execute them. The approach supports multiple broker backends including AMQP, Redis, AWS SQS, GCP Pub/Sub, and DynamoDB, allowing flexibility in infrastructure choices.
Machinery suits projects requiring background job processing, scheduled task execution, or work distribution across multiple workers. The tool is particularly valuable for teams already invested in Go and wanting to avoid external service dependencies. Version 2 is recommended for new projects because it eliminates the need to import dependencies for all supported brokers and backends, importing only those actually in use. The project provides workflow primitives including groups for parallel task execution, chains for sequential execution, and chords for fan-out and fan-in patterns. Periodic task scheduling is supported for recurring work.
Development activity shows consistent maintenance with regular updates addressing issues and feature requests. The project maintains both a legacy version one and an actively developed version two, providing a migration path for existing users while supporting new adopters with a cleaner dependency model. Documentation is comprehensive, covering configuration, task definition, worker setup, and workflow composition through code examples and detailed configuration guides.