Files
opsxdb/apps/server/internal/docs/content/08-redis.md
T
logan 26f459d1b8 fix: 顶栏文案去重与文档/连库体验更新
顶栏定为:连接 · 新建连接 · 新建查询 · 查询历史 · 快捷键;
同步 docs/落地页、对象树与 connection-types 注册表整理。
2026-09-20 16:32:29 +08:00

35 lines
1.0 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
Redis 连接使用专用表单(redis),连上后既是命令行又是键空间浏览器。
## 命令执行
SQL 编辑器同样适用于 Redis —— 直接输入命令,⌘/Ctrl + Enter 执行:
```bash
PING
SET demo:key "hello" EX 60
GET demo:key
KEYS demo:*
DEL demo:key
```
- 返回值直接显示在结果面板;
- 集群 / 哨兵模式按各自连接方式配置(哨兵填写主节点名)。
## 键空间浏览
- **KEYS 扫描**:按模式浏览键(生产大库建议用前缀收窄范围);
- 键类型视图:string / hash / list / set / zset 分类型展示;
- **TTL 管理**:查看与设置过期时间,常用于缓存排障;
- 批量操作:选中多个键批量删除。
> **注意**:`KEYS *` 在大库上会阻塞 Redis,OpsxDB 不做强制拦截 —— 生产环境请自觉使用带前缀的模式。
## 连接参数
| 字段 | 说明 |
| --- | --- |
| host / port | 默认 127.0.0.1:6379 |
| password | ACL / requirepass |
| database | 逻辑库序号(0-15 常见) |
| ssl | 红色连接(TLS)开关 |