-
Notifications
You must be signed in to change notification settings - Fork 556
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
append some context to logs #323
Comments
Makes sense to do with #305 too |
Do the current logs have enough context or should we add more? The way klog is structured is going to be difficult and repetitive to add more context to the current logs. We could adopt https://github.com/go-logr/logr and zap logger, which is already included in controller runtime, but that means to switch to json logging, which I'm not sure if that makes things better or worse. |
The context I was referring to was knowing if the logs were coming from the machine actuator or cluster actuator. I'm not sure it's worth adding more context as I've been able to debug issues fine without it, I think it's a nice to have and would be fine moving this to the backlog if others are also happy with the logging. |
/priority backlog |
/good-first-issue |
If available .. I want to take up this one and get started :) Can I a take up this one? @chuckha |
yes, please @usahai30 /lifecycle active join us in #cluster-api-aws on the k8s slack if you're not already if you have any questions! |
Thanks @chuckha Please confirm my understanding for this issue -
To-Be -
|
It would be nice if there was a way to set this up in the instantiation of the But yes, you're on the right path! The actuators are the important part, but if you end up having to add context to the manager's logger, that would be fine too. |
Yeah sure, I agree with that ... Will look around what best I can come up with. |
Semi related klog issue / feature here: kubernetes/klog#22 |
@chuckha I looked at the possibilities and my understandings are -
Please suggest, what should we do here? Should we wait for structured logging to be implemented first in klog? |
/remove-lifecycle active |
/remove-priority longterm-important |
@chuckha: Those labels are not set on the issue: In response to this:
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository. |
/remove-priority important-longterm |
/kind feature
Describe the solution you'd like
I'd like to know if logs are coming from the machine actuator or the controller actuator. would be happy with [controller] or [machine] in front of the log.
Anything else you would like to add:
This is up for discussion, but it would be useful in the effort to make this easier to debug
Environment:
kubectl version
):/etc/os-release
):The text was updated successfully, but these errors were encountered: