Installation & Extras¶
litestar-queues supports Python 3.11 through 3.15 and requires litestar>=2.24.0.
Core Package¶
The base installation includes the core task runtime, InMemoryQueueBackend, EphemeralQueueBackend (built on Python's standard-library sqlite3), LocalExecutionBackend, ImmediateExecutionBackend, cron/interval scheduling, and realtime SSE/WebSocket event streams.
Storage Backend Extras¶
Install the extra corresponding to your production database or key-value store:
SQLSpec (SQLite, PostgreSQL, CockroachDB, MySQL, MariaDB, Oracle, DuckDB, Spanner)¶
Advanced Alchemy (SQLAlchemy 2.0 Async)¶
Redis (redis>=8.1.0) or Valkey (valkey>=6.0.0)¶
Execution Transport & Observability Extras¶
| Extra | Package Dependency | Purpose |
|---|---|---|
cloud-tasks |
google-cloud-tasks>=2.23.0 |
Serverless HTTP push dispatch via CloudTasksExecutionConfig and /_litestar-queues/cloud-tasks. |
cloudrun |
google-cloud-run>=0.10.0 |
Serverless batch container execution via CloudRunExecutionConfig and litestar queues run-task. |
pubsub |
google-cloud-pubsub>=2.39.0 |
Google Cloud Pub/Sub ID-only execution dispatch via PubSubExecutionConfig. |
sqs |
aiobotocore>=3.8.0 |
AWS SQS standard and FIFO execution dispatch via SQSExecutionConfig. |
rabbitmq |
aio-pika>=10.0.1 |
RabbitMQ AMQP 0-9-1 execution dispatch via RabbitMQExecutionConfig. |
kafka |
aiokafka>=0.14.0 |
Apache Kafka execution dispatch via KafkaExecutionConfig. |
otel |
opentelemetry-api, opentelemetry-sdk |
OpenTelemetry distributed tracing spans and metrics via ObservabilityConfig(enable_otel=True). |
prometheus |
prometheus-client |
Prometheus queue depth, latency, and outcome counters via ObservabilityConfig(enable_prometheus=True). |
Combine multiple extras in a single install command: