Aiven-Open / karapace

Karapace - Your Apache Kafka® essentials in one tool
https://karapace.io
Apache License 2.0
450 stars 68 forks source link

Support for JSON log format #905

Open wavermartijn opened 2 months ago

wavermartijn commented 2 months ago

When running karapace in a container on a platform that includes centralized logging, it would be helpful to be able to output the logs formatted as JSON. I tried doing this with the KARAPACE_LOG_FORMAT option. This works for most of the log lines, but some log lines include double quotes and these will then corrupt the outputted JSON.

Native JSON output or at least a way to use the log_format to generate valid JSON would help a lot to be able to ingest the logs.