feat(logz)!: promote to v1.0.0 — configurable io.Writer output destination

Add Writer io.Writer field to Options; when nil, defaults to os.Stdout (no
breaking change). Enables log capture in tests via the public API and supports
writing to files, multi-writers, or any io.Writer implementation in production.
All remaining roadmap items validated in production (xerrors enrichment
concurrency, WithFields merge semantics, Logger interface finality). API
committed as stable.
This commit is contained in:
2026-05-11 18:50:37 -06:00
parent 3667b92fab
commit 05c99f72ff
3 changed files with 41 additions and 18 deletions

View File

@@ -5,6 +5,21 @@ All notable changes to this module will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this module adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
## [1.0.0] — 2026-05-12
### Added
- `Options.Writer io.Writer` — configurable output destination; `nil` defaults
to `os.Stdout` (backward-compatible). Accepts any `io.Writer` implementation:
`*os.File`, `bytes.Buffer`, `io.MultiWriter`, custom sinks, etc.
### Unchanged
All existing API (`Logger`, `New`, `WithRequestID`, `GetRequestID`, `WithField`,
`WithFields`) is API-compatible with v0.9.0.
[1.0.0]: https://code.nochebuena.dev/go/logz/releases/tag/v1.0.0
## [0.9.0] - 2026-03-18
### Added