<@U078Y59KC3B> How can I set the log output as JSO...
# ask-ai
t
@RunLLM How can I set the log output as JSON using the helm chart?
r
To set the log output as JSON using the Helm chart for StreamNative Platform, configure the
logConfig
field in your values.yaml file for the desired component (e.g., broker, bookkeeper, zookeeper, proxy). Set
format: "json"
under the component's
logConfig
section. For example:
Copy code
broker:
  logConfig:
    level: "INFO"
    format: "json"
    template: {}
This will configure the broker to output logs in JSON format. The same approach applies to other components. For this feature, ensure you are using sn-platform 1.11 and have installed pulsar-operator after 0.17, as required by the documentation. More details can be found in the official docs at Configure Log Format. Would you like more detail? Sources: - Configure Log Format 👍 0 button 👎 0 button 💡 Hint: Mention @runllm in the thread for followups.
t
@RunLLM How can I set the log output as JSON using the apache helm chart
pulsar-helm-chart
?
r
The official Apache Pulsar Helm chart does not provide a direct values.yaml option to set log output as JSON. To achieve JSON log output, you must customize the Log4j2 configuration file (e.g.,
log4j2.yaml
) for each component and mount it via a Kubernetes ConfigMap or by overriding the image's default config. There is no built-in Helm value for log format in the
pulsar-helm-chart
as per the documentation. Would you like more detail on how to mount a custom Log4j2 config? Sources: - https://docs.streamnative.io/private/config-log-format-1.11.0 - https://docs.streamnative.io/private/private-cloud-log-format 👍 0 button 👎 0 button 💡 Hint: Mention @runllm in the thread for followups.