mirror of
https://github.com/Rain-kl/OpenFlare.git
synced 2026-09-30 22:26:38 +08:00
Refactor logging to use slog package across the application
- Replaced standard log package with log/slog in httpclient, nginx manager, sync service, updater, and other components for structured logging. - Introduced environment variable `LOG_LEVEL` to control logging levels (debug, info, warn, error). - Updated documentation to reflect changes in logging configuration and requirements. - Added a new logging setup function in the ats_agent internal package to initialize the slog logger.
This commit is contained in:
@@ -21,6 +21,7 @@
|
||||
|
||||
`atsf_server` 继续作为单体控制面:
|
||||
|
||||
* Go 1.23+
|
||||
* Gin
|
||||
* GORM
|
||||
* SQLite
|
||||
@@ -36,6 +37,7 @@
|
||||
|
||||
`atsf_agent` 继续作为 Go 单体程序:
|
||||
|
||||
* Go 1.23+
|
||||
* 单二进制
|
||||
* 节点本地执行
|
||||
* `openresty_path` 优先
|
||||
@@ -275,6 +277,7 @@ Agent 必须满足:
|
||||
|
||||
要求:
|
||||
|
||||
* Server 与 Agent 统一使用 `slog` 输出结构化日志
|
||||
* 日志足够定位问题
|
||||
* 不打印敏感凭证完整值
|
||||
|
||||
|
||||
Reference in New Issue
Block a user