SessionEntry
public record SessionEntry( String sessionKey, String agentId, String sessionId, String label, SessionKind kind, String spawnedBy, int spawnDepth, long createdAtMs, long lastActivityMs, String sessionFilePath, String spawnRunId, String gateKey, String userId)
io/agentscope/harness/coding/session/SessionEntry.java:26–99承载会话条目数据的记录类型。位于 io.agentscope.harness.coding.session 包。核心成员包括 sessionKey、agentId、sessionId、label、kind、spawnedBy。
Internal metadata for a registered managed session (used by SessionAgentManager).
记录组件摘要Record Component Summary
| 组件Component | 类型Type | 说明Description |
|---|---|---|
sessionKey | String | 执行会话键相关操作。 Performs the session key operation. |
agentId | String | 执行智能体标识相关操作。 Performs the agent id operation. |
sessionId | String | 执行会话标识相关操作。 Performs the session id operation. |
label | String | 执行标签相关操作。 Performs the label operation. |
kind | SessionKind | 执行种类相关操作。 Performs the kind operation. |
spawnedBy | String | 执行 `spawnedBy` 方法。 Performs the spawned by operation. |
spawnDepth | int | 执行 `spawnDepth` 方法。 Performs the spawn depth operation. |
createdAtMs | long | 执行已创建 At Ms相关操作。 Performs the created at ms operation. |
lastActivityMs | long | 执行 `lastActivityMs` 方法。 Performs the last activity ms operation. |
sessionFilePath | String | 执行会话文件路径相关操作。 Performs the session file path operation. |
spawnRunId | String | 执行 `spawnRunId` 方法。 Performs the spawn run id operation. |
gateKey | String | 执行 `gateKey` 方法。 routing key used by the gateway to map this session back to a channel context;
only populated for `SessionKind#MAIN` sessions (nullable) |
userId | String | 执行用户标识相关操作。 optional user identity that owns this session; used by HarnessAgent's
NamespaceFactory for per-user filesystem isolation (nullable — null means single-tenant) |
构造器摘要Constructor Summary
| 构造器Constructor | 说明Description |
|---|---|
public SessionEntry(String sessionKey, String agentId, String sessionId, String label, SessionKind kind, String spawnedBy, int spawnDepth, long createdAtMs, long lastActivityMs, String sessionFilePath, String spawnRunId) | 初始化 `SessionEntry` 实例。 Backwards-compatible constructor without gateKey or userId. |
public SessionEntry(String sessionKey, String agentId, String sessionId, String label, SessionKind kind, String spawnedBy, int spawnDepth, long createdAtMs, long lastActivityMs, String sessionFilePath, String spawnRunId, String gateKey) | 初始化 `SessionEntry` 实例。 Backwards-compatible constructor with gateKey but without userId. |
记录组件详情Record Component Detail
sessionKey
String sessionKey执行会话键相关操作。
Performs the session key operation.
io/agentscope/harness/coding/session/SessionEntry.java:26–99agentId
String agentId执行智能体标识相关操作。
Performs the agent id operation.
io/agentscope/harness/coding/session/SessionEntry.java:26–99sessionId
String sessionId执行会话标识相关操作。
Performs the session id operation.
io/agentscope/harness/coding/session/SessionEntry.java:26–99label
String label执行标签相关操作。
Performs the label operation.
io/agentscope/harness/coding/session/SessionEntry.java:26–99kind
SessionKind kind执行种类相关操作。
Performs the kind operation.
io/agentscope/harness/coding/session/SessionEntry.java:26–99spawnedBy
String spawnedBy执行 spawnedBy 方法。
Performs the spawned by operation.
io/agentscope/harness/coding/session/SessionEntry.java:26–99spawnDepth
int spawnDepth执行 spawnDepth 方法。
Performs the spawn depth operation.
io/agentscope/harness/coding/session/SessionEntry.java:26–99createdAtMs
long createdAtMs执行已创建 At Ms相关操作。
Performs the created at ms operation.
io/agentscope/harness/coding/session/SessionEntry.java:26–99lastActivityMs
long lastActivityMs执行 lastActivityMs 方法。
Performs the last activity ms operation.
io/agentscope/harness/coding/session/SessionEntry.java:26–99sessionFilePath
String sessionFilePath执行会话文件路径相关操作。
Performs the session file path operation.
io/agentscope/harness/coding/session/SessionEntry.java:26–99spawnRunId
String spawnRunId执行 spawnRunId 方法。
Performs the spawn run id operation.
io/agentscope/harness/coding/session/SessionEntry.java:26–99gateKey
String gateKey执行 gateKey 方法。
routing key used by the gateway to map this session back to a channel context;
only populated for SessionKind#MAIN sessions (nullable)
io/agentscope/harness/coding/session/SessionEntry.java:26–99userId
String userId执行用户标识相关操作。
optional user identity that owns this session; used by HarnessAgent's NamespaceFactory for per-user filesystem isolation (nullable — null means single-tenant)
io/agentscope/harness/coding/session/SessionEntry.java:26–99构造器详情Constructor Detail
SessionEntry
public SessionEntry(String sessionKey, String agentId, String sessionId, String label, SessionKind kind, String spawnedBy, int spawnDepth, long createdAtMs, long lastActivityMs, String sessionFilePath, String spawnRunId)
初始化 SessionEntry 实例。
Backwards-compatible constructor without gateKey or userId.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
sessionKey | String | 会话键(类型 `String`)。The session key. |
agentId | String | 智能体标识(类型 `String`)。The agent id. |
sessionId | String | 会话标识(类型 `String`)。The session id. |
label | String | 标签(类型 `String`)。The label. |
kind | SessionKind | 种类(类型 `SessionKind`)。The kind. |
spawnedBy | String | spawned 通过(类型 `String`)。The spawned by. |
spawnDepth | int | spawn Depth(类型 `int`)。The spawn depth. |
createdAtMs | long | 已创建 At Ms(类型 `long`)。The created at ms. |
lastActivityMs | long | 最后 Activity Ms(类型 `long`)。The last activity ms. |
sessionFilePath | String | 会话文件路径(类型 `String`)。The session file path. |
spawnRunId | String | spawn 运行标识(类型 `String`)。The spawn run id. |
io/agentscope/harness/coding/session/SessionEntry.java:42–68SessionEntry
public SessionEntry(String sessionKey, String agentId, String sessionId, String label, SessionKind kind, String spawnedBy, int spawnDepth, long createdAtMs, long lastActivityMs, String sessionFilePath, String spawnRunId, String gateKey)
初始化 SessionEntry 实例。
Backwards-compatible constructor with gateKey but without userId.
| 名称Name | 类型Type | 说明Description |
|---|---|---|
sessionKey | String | 会话键(类型 `String`)。The session key. |
agentId | String | 智能体标识(类型 `String`)。The agent id. |
sessionId | String | 会话标识(类型 `String`)。The session id. |
label | String | 标签(类型 `String`)。The label. |
kind | SessionKind | 种类(类型 `SessionKind`)。The kind. |
spawnedBy | String | spawned 通过(类型 `String`)。The spawned by. |
spawnDepth | int | spawn Depth(类型 `int`)。The spawn depth. |
createdAtMs | long | 已创建 At Ms(类型 `long`)。The created at ms. |
lastActivityMs | long | 最后 Activity Ms(类型 `long`)。The last activity ms. |
sessionFilePath | String | 会话文件路径(类型 `String`)。The session file path. |
spawnRunId | String | spawn 运行标识(类型 `String`)。The spawn run id. |
gateKey | String | gate 键(类型 `String`)。The gate key. |
io/agentscope/harness/coding/session/SessionEntry.java:71–98