# Redis API 接口文档 ## 概述 Redis 是一个高性能的键值存储系统,支持多种数据结构。 ## 连接配置 - Host: localhost - Port: 6379 - Password: 可选 ## 常见问题 ### 连接超时 如果遇到 Redis 连接超时问题,请检查: 1. 网络连通性 2. Redis 服务是否启动 3. 防火墙配置 ### 性能优化 - 使用连接池 - 合理设置超时时间 - 避免大 key ## API 示例 ```java // 连接 Redis RedisClient client = new RedisClient("localhost", 6379); // 设置值 client.set("key", "value"); // 获取值 String value = client.get("key"); ```