NacosA2aTransportPropertiesEnvParser
public class NacosA2aTransportPropertiesEnvParser
io/agentscope/core/nacos/a2a/registry/NacosA2aTransportPropertiesEnvParser.java:41–135用于NacosA2aRegistryTransportProperties来自环境的解析器。位于 io.agentscope.core.nacos.a2a.registry 包。核心成员包括 getTransportProperties。
Parser for NacosA2aRegistryTransportProperties from Environment.
The ENV of A2A transport properties is prefixed with Constants#PROPERTIES_ENV_PREFIX, and is appended with
{TRANSPORT} and {ATTRIBUTE}. Such as NACOS_A2A_AGENT_JSONRPC_HOST=127.0.0.1.
This parser will parse the environment variables which are prefixed with Constants#PROPERTIES_ENV_PREFIX and
convert them into NacosA2aRegistryTransportProperties.
These variables will be split by _ excluding the prefix and the first part is the transport name, the second part is the
attribute name. If there are duplicate keys in the environment variables, the last one will be used.
方法摘要Method Summary
| 方法Method | 说明Description |
|---|---|
public Map<String, NacosA2aRegistryTransportProperties> getTransportProperties() | 获取传输层属性。 Retrieves transport properties from environment variables and converts them to a map of
`NacosA2aRegistryTransportProperties`. |
方法详情Method Detail
getTransportProperties
public Map<String, NacosA2aRegistryTransportProperties> getTransportProperties()
获取传输层属性。
Retrieves transport properties from environment variables and converts them to a map of NacosA2aRegistryTransportProperties.
Map<String, NacosA2aRegistryTransportProperties>io/agentscope/core/nacos/a2a/registry/NacosA2aTransportPropertiesEnvParser.java:56–58