🎨 Overview
Underway provides a robust and efficient way to execute asynchronous tasks using PostgreSQL as the backend for task storage and coordination. It is designed to be simple, scalable, and resilient, handling job processing in a way that ensures safe concurrency and reliable task execution. Whether you're processing tasks on a single server or across multiple workers, Underway makes it easy to manage background jobs with confidence.
Key Features:
- PostgreSQL-Backed Built on PostgreSQL for robust task storage and coordination, ensuring consistency and safe concurrency across all operations.
- Transactional Task Management Supports enqueuing tasks within existing database transactions, guaranteeing that tasks are only added if the transaction commits successfully—perfect for operations like user registration.
- Automatic Retries Offers customizable retry strategies for failed executions, ensuring tasks are reliably completed even after transient failures.
- Cron-Like Scheduling Supports scheduling recurring tasks with cron-like expressions, enabling automated, time-based job execution.
- Scalable and Flexible Scales from a single worker to multiple workers with minimal configuration, allowing seamless background job processing.
🤸 Usage
use env;
use ;
use PgPool;
use ;
const QUEUE_NAME: &str = "email";
async
🦺 Safety
This crate uses #![forbid(unsafe_code)] to ensure everything is implemented in 100% safe Rust.
🛟 Getting Help
We've put together a number of examples to help get you started. You're also welcome to open a discussion and ask additional questions you might have.
👯 Contributing
We appreciate all kinds of contributions, thank you!