mcp-redis监测仪
FastMCP服务器提供只读工具来监控Redis实例。
安装
pip install -e ".[dev]"环境变量
| 变量 | 默认值 | 描述 |
|---|---|---|
REDIS_MONITOR_HOST | localhost | Redis主机 |
REDIS_MONITOR_PORT | 6379 | Redis端口 |
REDIS_MONITOR_PASSWORD | *(无)* | Redis密码(可选) |
工具
| 工具 | 说明 |
|---|---|
get_queue_depths | 特定数据库中的键+按类型的长度(默认值:3) |
get_celery_queue_status | Celery队列名称、待处理计数、最旧任务 |
get_connected_clients | 连接的客户端数量 |
get_server_info | 内存、正常运行时间、密钥空间统计数据 |
get_key_count_by_db | 每个数据库的密钥(概述) |
用法
mcp-redis-monitor或者添加到您的MCP客户端配置中:
{
"mcpServers": {
"redis-monitor": {
"command": "mcp-redis-monitor"
}
}
}发展
ruff check src/ tests/
ruff format src/ tests/
pytest