Context
Production services need structured, leveled logging with timestamps and enough context to debug incidents. FKVS currently logs mostly through printf/fprintf and compile/runtime verbosity flags.
Scope
- Add log levels: DEBUG, INFO, WARN, ERROR.
- Include timestamp, level, subsystem, and useful context such as client fd/address where safe.
- Make log level configurable.
- Avoid logging raw values by default to prevent sensitive data exposure.
- Support stdout/stderr logging for containers and file/syslog mode if needed for daemon deployments.
- Replace ad hoc logging in server startup, event loops, command errors, config parsing, and shutdown.
Acceptance criteria
- Logs are consistent and parseable enough for production operations.
- Verbose protocol dumps are opt-in and safe by default.
- Errors include actionable context without leaking key/value contents unnecessarily.
- Logging behavior is documented.
Context
Production services need structured, leveled logging with timestamps and enough context to debug incidents. FKVS currently logs mostly through
printf/fprintfand compile/runtime verbosity flags.Scope
Acceptance criteria