GoogleCloudPlatform / flink-on-k8s-operator

[DEPRECATED] Kubernetes operator for managing the lifecycle of Apache Flink and Beam applications.
Apache License 2.0
658 stars 266 forks source link

How to set operator Log format and Level #442

Open andre-taveira opened 3 years ago

andre-taveira commented 3 years ago

After installing the operator I saw that our Log aggregation solution (datadog) started considering all operator logs as ERROR and its not optimally displaying them. I'd like to explicitly tell the operator its log level, verbosity and format. Looking through the code I saw how to set the verbosity but I can figure out how to set the log level and format ( JSON format is my goal).

I saw that we're using kubebuilder and looking through the code I saw that we mostly use logr for logs but I couldn't find in their docs a way to set logs via arguments to the application. My fear was that we'd need to do some code adaption to support json encoding in the logs.

Anyone has any tips ?

benkusak commented 2 years ago

+1 - Also interested in how to achieve this.