Copilot commented on code in PR #1105:
URL: https://github.com/apache/dubbo-go-samples/pull/1105#discussion_r3214829631
##########
logger/README.md:
##########
@@ -40,10 +40,11 @@ logger.SetLoggerLevel("warn")
#### output to file
-Add the file item under the logger option in the configuration file
+Set `appender: file` and add the file item under the logger option in the
configuration file. When the sample is run from `logger/rolling`, the relative
file name below is created as `logger/rolling/logs.log`. Use `appender:
console,file` if you want the same log records to be written to both console
and file.
```yaml
logger:
+ appender: file
file:
Review Comment:
The YAML snippet in this section starts at `logger:` without showing the
actual top-level `dubbo:` key used by the sample config (see
`logger/rolling/conf/dubbogo.yml`). Copy/pasting this snippet as-is into
`dubbogo.yml` may not work; consider either including the `dubbo:` root in the
example or explicitly stating that `logger:` is under `dubbo:`.
##########
logger/README_zh.md:
##########
@@ -40,10 +40,11 @@ logger.SetLoggerLevel("warn")
#### 输出到文件
-在配置文件中的 logger 选项下添加 file 项
+在配置文件中的 logger 选项下设置 `appender: file` 并添加 file 项。从 `logger/rolling`
目录运行样例时,下面的相对文件名会生成到 `logger/rolling/logs.log`。如果希望同一批日志同时输出到控制台和文件,可使用
`appender: console,file`。
```yaml
logger:
+ appender: file
file:
Review Comment:
The YAML example here omits the `dubbo:` root key even though the rolling
sample’s config is structured as `dubbo.logger` (see
`logger/rolling/conf/dubbogo.yml`). To avoid readers pasting an invalid config,
include the `dubbo:` root in the snippet or clarify that `logger:` is nested
under `dubbo:`.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]