New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Configure zap EncoderConfig for operator #268
Comments
Yes, please! |
Awesome! My schedule is bit busy, I'll pick this up on the next availability within 3 weeks. |
Are you still interested in this one, @kaskavalci? |
I do but it's been difficult to integrate this work with summer plans. I put a self imposed deadline but that didn't work either :) Is the issue prioritized? I'm happy to leave it to others or pick it up ASAP I find some time on my hands. |
It's not prioritized, I would love to have you do it whenever you have time for it. |
@jpkrohling I'm sorry to keep this holding on me. It seems I cannot allocate any time to ship this feature. So, it's open for grabs! |
@jpkrohling, @kaskavalci. Could you please clarify what the expected results in this issue are? |
@kaskavalci do you have any updates regarding this issue? |
@yuriolisa Is this the expected outcome of the issue? Current: {"level":"info","ts":"2024-03-12T14:39:02+08:00","msg":"test"} Expect: {"severity":"info","ts":"2024-03-12T14:41:24+08:00","msg":"test"} |
I did a misinterpretation about that issue, but you're right. It's exactly what's expected. |
Operator uses default configuration for zap encoder configuration.
levelKey
in this config defaults tolevel
. This creates an issue in GCP Logging as it expectsseverity
for log level. Below is an example of a log level interpreted as error.I've noticed operator uses
sigs.k8s.io/controller-runtime/pkg/log/zap
package to bind directly from environment variables. As far as I can see, that function does not support full configuration ofzapcore.EncoderConfig
. But, it seems it is possible to configure zap completely by using the zap package from controller-runtime.If such a feature is reasonable, I'm happy to pick it up to contribute.
The text was updated successfully, but these errors were encountered: