📝 refine sync parse builder docs

This commit is contained in:
Nanaloveyuki
2026-06-14 01:33:06 +08:00
parent 1a33f5c95d
commit 861adb7b5d
2 changed files with 4 additions and 1 deletions
@@ -38,7 +38,8 @@ Detailed rules explaining key parameters and behaviors
- This API delegates to `parse_and_build_logger(...)` directly.
- JSON parsing and config validation happen before the logger is built.
- The parsed config still goes through the normal configured runtime logger build path, including runtime sink selection, optional queue wrapping, and timestamp application.
- Because the result is only the `ApplicationLogger` alias over `ConfiguredLogger`, this parse-and-build path does not hide any queue, drain, flush, or file runtime helper methods.
- Because the result is only the `ApplicationLogger` alias over `ConfiguredLogger`, this parse-and-build path returns the same underlying configured runtime logger value that `parse_and_build_logger(...)` would produce directly, without hiding any queue, drain, flush, or file runtime helper methods.
- Use `parse_and_build_library_logger(...)` instead when the same parsed configured logger result should be wrapped and narrowed for a library boundary.
### How to Use
@@ -37,9 +37,11 @@ Detailed rules explaining key parameters and behaviors
- This API parses config text, validates it, builds the configured logger through `parse_and_build_logger(...)`, and wraps that same value as a library facade.
- The parsed config still goes through the normal configured runtime logger build path, including runtime sink selection, optional queue wrapping, and timestamp application.
- The returned facade wraps the same underlying `ConfiguredLogger` value that `parse_and_build_logger(...)` would produce directly.
- The returned facade keeps a narrower surface than the underlying configured logger.
- Queue metrics, flush and drain helpers, and file runtime controls stay on the underlying `ConfiguredLogger`, not on the returned facade itself.
- `to_logger()` can be used to recover the underlying full logger object when necessary.
- Use this parse/build facade when text-driven construction should preserve the configured runtime logger path but still hide broader runtime helper methods at the package boundary.
### How to Use