A high-performance distributed task queue system with web monitoring
Project description
JetTask
高性能分布式任务队列系统,带有实时 Web 监控界面。
特性
- 🚀 高性能: 基于 Redis 和异步 IO 的高性能任务处理
- 📊 实时监控: 美观的 Web UI 实时监控任务状态
- 🔄 分布式: 支持多队列、多 Worker 的分布式架构
- 📈 数据可视化: 任务处理趋势图表和统计分析
- 🎯 灵活配置: 支持多种任务类型和处理策略
- 🔍 任务追踪: 完整的任务生命周期追踪
安装
使用 pip 安装
pip install jettask
从源码安装
git clone https://github.com/yourusername/jettask.git
cd jettask
pip install -e .
快速开始
1. 初始化系统
jettask init
2. 启动 Web UI
jettask webui
# 或指定端口
jettask webui --port 8080
访问 http://localhost:8001 查看监控界面
3. 启动 Worker
jettask worker main:app --queues default --concurrency 4
4. 检查系统状态
jettask status
系统要求
- Python 3.8+
- Redis 6.0+
- PostgreSQL 12+
环境配置
创建 .env 文件配置系统参数:
# Redis 配置
REDIS_HOST=localhost
REDIS_PORT=6379
REDIS_DB=0
# PostgreSQL 配置
JETTASK_PG_HOST=localhost
JETTASK_PG_PORT=5432
JETTASK_PG_DB=jettask
JETTASK_PG_USER=jettask
JETTASK_PG_PASSWORD=123456
命令行工具
JetTask 提供了丰富的命令行工具:
# 查看帮助
jettask --help
# 启动 Web UI
jettask webui
# 启动 Worker
jettask worker app:tasks --queues queue1,queue2
# 启动 WebUI 数据消费者
jettask webui-consumer
# 启动监控器
jettask monitor
# 初始化数据库
jettask init
# 查看系统状态
jettask status
开发
安装开发依赖
pip install -e ".[dev]"
运行测试
pytest
代码格式化
black jettask/
架构
┌─────────────┐ ┌─────────────┐ ┌─────────────┐
│ Producer │────▶│ Redis │◀────│ Worker │
└─────────────┘ └─────────────┘ └─────────────┘
│ │
▼ ▼
┌─────────────┐ ┌─────────────┐
│ PostgreSQL │ │ Monitoring │
└─────────────┘ └─────────────┘
│ │
└──────────┬──────────┘
▼
┌─────────────┐
│ Web UI │
└─────────────┘
许可证
MIT License
贡献
欢迎提交 Issue 和 Pull Request!
支持
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
jettask-0.1.4.tar.gz
(192.1 kB
view details)
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
jettask-0.1.4-py3-none-any.whl
(213.8 kB
view details)
File details
Details for the file jettask-0.1.4.tar.gz.
File metadata
- Download URL: jettask-0.1.4.tar.gz
- Upload date:
- Size: 192.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.11.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
25f187b430fc6381a0cdf078056f796d4b887bcd5ff8448063b35a598d0f8504
|
|
| MD5 |
6a8e7bb815e4531dac4d91cfd3c90813
|
|
| BLAKE2b-256 |
143fda5b62e7acb97d5ddfd93379f88224c7eac50d988dc1f0a7062e897b15ec
|
File details
Details for the file jettask-0.1.4-py3-none-any.whl.
File metadata
- Download URL: jettask-0.1.4-py3-none-any.whl
- Upload date:
- Size: 213.8 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.11.13
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
21c13a2fc08583dd635eab55e208bfb47e910b53d6c6d08db3bc2e58c68fa651
|
|
| MD5 |
ac432be64214596f98a2edf319a33a5c
|
|
| BLAKE2b-256 |
f46b652efb074b74e9cc53170613afa5a367c04175aa52ae6752807f0846e61a
|