logger — Optimization
Extend redaction for deeper objects
Section titled “Extend redaction for deeper objects”Default redaction covers keys at the top level and one level below it. Add explicit paths for sensitive fields deeper in the object.
Configure once
Section titled “Configure once”Call configureLogger() at startup. A subsequent call without force: true keeps the existing configuration.
Respect browser and Edge behavior
Section titled “Respect browser and Edge behavior”Browser and Edge builds use Pino browser output. withLogContext is pass-through, and pretty and destination do not configure a server stream.
Rebuild Payload configuration after replacement
Section titled “Rebuild Payload configuration after replacement”A forced logger reconfiguration requires rebuilding Payload configuration created with getPayloadLoggerConfig() to pick up the change.