AgentScopeJvmShutdownHook
public final class AgentScopeJvmShutdownHook
源码Source
io/agentscope/core/shutdown/AgentScopeJvmShutdownHook.java:34–70AgentScope Jvm Shutdown 钩子,为框架提供通用类型与基础能力。位于 io.agentscope.core.shutdown 包。核心成员包括 register。
JVM hook for SIGTERM graceful shutdown entry.
Shutdown order:
-
Trigger graceful shutdown (reject new requests, interrupt at checkpoints)
-
Wait for all active agent requests to complete or timeout
-
Close HTTP transports (only after agents are done)
方法摘要Method Summary
| 方法Method | 说明Description |
|---|---|
public static void register(GracefulShutdownManager manager)static | 设置注册。 Performs the register operation. |
方法详情Method Detail
register
public static void register(GracefulShutdownManager manager)
static
设置注册。
Performs the register operation.
参数Parameters
| 名称Name | 类型Type | 说明Description |
|---|---|---|
manager | GracefulShutdownManager | 管理器(类型 `GracefulShutdownManager`)。The manager. |
源码Source
io/agentscope/core/shutdown/AgentScopeJvmShutdownHook.java:43–69