Kermit icon indicating copy to clipboard operation
Kermit copied to clipboard

Chunked log writer that breaks up long messages

Open psh opened this issue 9 months ago • 0 comments

This PR adds a commonMain implementation of log chunking that can be applied to any log writer.

Logger.setLogWriters(platformLogWriter().chunked())
Logger.setTag("MyTag")
Logger.i { "Hello Kotlin" }

The chunked() method defaults parameters for max / min chunking and returns a wrapped log writer that breaks long messages and feeds them to the wrapped writer.

This PR relates to #394

psh avatar May 07 '24 21:05 psh