taskito¶
Rust-powered task queue for Python. No broker required — just SQLite.
5-Minute Quickstart¶
from taskito import Queue
queue = Queue(db_path="tasks.db")
@queue.task()
def add(a: int, b: int) -> int:
return a + b
job = add.delay(2, 3)
# Start worker (in production, use the CLI instead)
import threading
t = threading.Thread(target=queue.run_worker, daemon=True)
t.start()
print(job.result(timeout=10)) # 5
Why taskito?¶
Most Python task queues require a separate broker (Redis, RabbitMQ) that you need to install, configure, monitor, and keep running. taskito embeds everything into a single SQLite file — the queue, the results, the rate limits, the schedules. Just pip install and go.
The core engine is written in Rust for performance: job dispatch, retry scheduling, rate limiting, and storage all happen in compiled native code. Python only runs during actual task execution.
Features¶
-
Zero Infrastructure
No Redis, no RabbitMQ — just a SQLite file. Install and start queuing in seconds.
-
Priority Queues
Higher priority jobs run first. Override at enqueue time for urgent work.
-
Retry with Backoff
Automatic exponential backoff with jitter. Failed jobs land in a dead letter queue for inspection.
-
Rate Limiting
Token bucket rate limiting per task.
"100/m","10/s","3600/h". -
Task Workflows
Compose pipelines with
chain, parallelize withgroup, aggregate withchord. -
Cron Scheduling
@queue.periodic(cron="0 */5 * * * *")for recurring tasks with 6-field cron expressions. -
Progress Tracking
Report progress from inside tasks. Monitor completion percentage in real time.
-
Rust-Powered
Scheduling, storage, and dispatch in native Rust. Python only runs your task code.
Architecture¶
graph TB
subgraph Python ["Python Layer"]
A["Queue / TaskWrapper"]
D["JobResult"]
end
subgraph Rust ["Rust Core · PyO3"]
F["PyQueue"]
G["Scheduler · Tokio"]
H["Worker Pool · OS Threads"]
I["Rate Limiter"]
end
subgraph Storage ["Embedded Storage"]
J[("SQLite · WAL mode<br/>Diesel ORM")]
end
A -->|enqueue| F
F -->|INSERT| J
G -->|poll & dequeue| J
G -->|crossbeam channel| H
H -->|acquire GIL · run task| A
H -->|result| G
G -->|UPDATE status| J
D -->|poll status| F
F -->|SELECT| J
G -.->|check limit| I
I -.->|token state| J
Comparison¶
| Feature | taskito | Celery | RQ | Dramatiq | Huey |
|---|---|---|---|---|---|
| Broker required | No | Redis/RabbitMQ | Redis | Redis/RabbitMQ | Redis |
| Core language | Rust + Python | Python | Python | Python | Python |
| Priority queues | |||||
| Rate limiting | |||||
| Dead letter queue | |||||
| Task workflows | |||||
| Job cancellation | |||||
| Progress tracking | |||||
| Unique tasks | |||||
| Setup complexity | pip install |
Broker + backend | Redis server | Broker | Redis server |