RedisSnapshotSpec
public class RedisSnapshotSpec extends RemoteSnapshotSpec
源码Source
io/agentscope/extensions/redis/snapshot/RedisSnapshotSpec.java:25–37Redis 快照规格,在多次调用之间保存和恢复会话与记忆数据。位于 io.agentscope.extensions.redis.snapshot 包,继承自 RemoteSnapshotSpec。核心成员包括 RedisSnapshotSpec。
Convenience SandboxSnapshotSpec for Redis-backed snapshot storage.
构造器摘要Constructor Summary
| 构造器Constructor | 说明Description |
|---|---|
public RedisSnapshotSpec(UnifiedJedis jedis, String keyPrefix, Integer ttlSeconds) | 初始化 `RedisSnapshotSpec` 实例。 Creates a Redis snapshot spec. |
构造器详情Constructor Detail
RedisSnapshotSpec
public RedisSnapshotSpec(UnifiedJedis jedis, String keyPrefix, Integer ttlSeconds)
初始化 RedisSnapshotSpec 实例。
Creates a Redis snapshot spec.
参数Parameters
| 名称Name | 类型Type | 说明Description |
|---|---|---|
jedis | UnifiedJedis | jedis(类型 `UnifiedJedis`)。initialized jedis client |
keyPrefix | String | 键 Prefix(类型 `String`)。redis key prefix (optional) |
ttlSeconds | Integer | 存活时间秒(类型 `Integer`)。optional TTL in seconds (null or negative means no TTL) |
源码Source
io/agentscope/extensions/redis/snapshot/RedisSnapshotSpec.java:34–36