ChannelRuntimeCatalog
@Component public class ChannelRuntimeCatalog
源码Source
io/agentscope/builder/web/config/ChannelRuntimeCatalog.java:29–66渠道运行时目录,承载智能体的部署、调度与服务化运行。位于 io.agentscope.builder.web.config 包。核心成员包括 replaceAll、get、ownerId、dmScope、snapshot。
In-memory snapshot of channel configs last fetched from the control plane. Used by io.agentscope.builder.runtime.SchedulerGateway to resolve the Builder owner of an IM channel
when bridging inbound turns into managed sessions.
方法摘要Method Summary
| 方法Method | 说明Description |
|---|---|
public void replaceAll(Map<String, ChannelConfigEntry> configs) | 设置该参数。 Replaces the catalog with `configs` (null-safe). |
public ChannelConfigEntry get(String channelId) | 返回配置用于`channelId`,或`null`。 Returns the config for `channelId`, or `null`. |
public String ownerId(String channelId) | 设置所有者标识。 Builder owner id for the channel, or `null` when unknown. |
public String dmScope(String channelId) | 设置dm 范围。 DmScope string for the channel (may be null / blank → treat as MAIN). |
public Map<String, ChannelConfigEntry> snapshot() | 返回快照。 Unmodifiable view of the current catalog. |
方法详情Method Detail
replaceAll
public void replaceAll(Map<String, ChannelConfigEntry> configs)
设置该参数。
Replaces the catalog with configs (null-safe).
参数Parameters
| 名称Name | 类型Type | 说明Description |
|---|---|---|
configs | Map<String, ChannelConfigEntry> | configs(类型 `Map`)。The configs. |
源码Source
io/agentscope/builder/web/config/ChannelRuntimeCatalog.java:35–40get
public ChannelConfigEntry get(String channelId)
返回配置用于channelId,或null。
Returns the config for channelId, or null.
参数Parameters
| 名称Name | 类型Type | 说明Description |
|---|---|---|
channelId | String | 渠道标识(类型 `String`)。The channel id. |
ChannelConfigEntry返回ChannelConfigEntry。Returns channel config entry.
源码Source
io/agentscope/builder/web/config/ChannelRuntimeCatalog.java:43–48ownerId
public String ownerId(String channelId)
设置所有者标识。
Builder owner id for the channel, or null when unknown.
参数Parameters
| 名称Name | 类型Type | 说明Description |
|---|---|---|
channelId | String | 渠道标识(类型 `String`)。The channel id. |
String返回字符串结果。Returns a string.
源码Source
io/agentscope/builder/web/config/ChannelRuntimeCatalog.java:51–54dmScope
public String dmScope(String channelId)
设置dm 范围。
DmScope string for the channel (may be null / blank → treat as MAIN).
参数Parameters
| 名称Name | 类型Type | 说明Description |
|---|---|---|
channelId | String | 渠道标识(类型 `String`)。The channel id. |
String返回字符串结果。Returns a string.
源码Source
io/agentscope/builder/web/config/ChannelRuntimeCatalog.java:57–60snapshot
public Map<String, ChannelConfigEntry> snapshot()
返回快照。
Unmodifiable view of the current catalog.
Map<String, ChannelConfigEntry>返回映射。Returns map.
源码Source
io/agentscope/builder/web/config/ChannelRuntimeCatalog.java:63–65