Configuration System
The framework has two configuration channels: atapp YAML configuration (instance startup parameters) and Excel design configuration (numerical tables).
Quick Start
Change runtime values using server configuration; edit/export design tables using Excel configuration. Both reuse existing loaders; the following sections explain loading, groups, and config sections.
Customization and Design
logic_config (YAML / atapp configuration)
src/server_frame/config/include/config/logic_config.h: the logic_config singleton parses the atapp
configuration into logic_section_cfg, containing sections such as db / router / task / telemetry /
excel. Each service injects its own config loading callback via
logic_config::set_server_instance_config_loader (see each *_main.cpp), and reload is supported.
Some fields support environment-variable expression expansion (enable_expression); see the deployment
configuration documentation and .agents/skills/configure-expression/ for the syntax.
Excel Configuration (xresloader)
Design tables live in resource/ExcelTables/ (Const.xlsx, DtMq.xlsx, Item.xlsx, Rank.xlsx, etc.).
Register table conversion entries in src/server_frame/protocol/public/xresconv.xml;
resource/excel_xml/xresconv.xml.in supplies global tool/path settings. xresloader (third_party/xresloader/) converts them
into binary configuration according to com.struct.*.config.proto (protos carrying the xrescode.loader
option).
Loading pipeline:
- The generated
config_managercalls each table'sconfig_set, which parses resources using generated protobuf types and builds indexes; excel_config_wrapper(config/src/excel_config_wrapper.cpp) handles buffer/version loaders,reload_all, version-grouped hot reload, and callbacks;- The convenient read API is generated by
config_easy_api.*.mako; business code usesexcel_config_wrapper_reload_allfor hot reload; - Loader declarations generate ordinary indexes;
excel_config_*_index.hfiles handle custom derived data, such as DTMQ'sDChannelConfigure.
Service Instance Configuration
atdtool renders install/cloud-native/charts/**/cfg/*.yaml.tpl into instance YAML.
The local entry point is generate_config.sh/.ps1, driven by layered values. Key sections:
| Section | Content |
|---|---|
atapp / atproxy | bus id, discovery (etcd), connector |
logic.db | Redis cluster/sentinel connections |
logic.router | Router object TTL, auto save interval |
logic.task | Task timeouts, etc. |
logic.telemetry | OpenTelemetry export |
logic.excel | Config loaders and grouping |