Skip to content
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

sidecar: Use zap as logger backend #770

Merged
merged 1 commit into from
Feb 17, 2025

Conversation

black-dragon74
Copy link
Member

@black-dragon74 black-dragon74 commented Feb 17, 2025

This patch sets zap as logger backend for klog
and controller runtime.

Setting the logger is required by controller runtime, not doing so leads to an error in the logs like:

[controller-runtime] log.SetLogger(...) was never called; logs will not be displayed.
Detected at:
        >  goroutine 26 [running]:
        >  runtime/debug.Stack()
        >       /usr/local/go/src/runtime/debug/stack.go:26 +0x5e
        >  sigs.k8s.io/controller-runtime/pkg/log.eventuallyFulfillRoot()
        ....

Copy link
Member

@Madhu-1 Madhu-1 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please update the PR description/commit message to show what exact error you are seeing now without this change.

This patch sets `zap` as logger backend for klog
and controller runtime.

Signed-off-by: Niraj Yadav <[email protected]>
@mergify mergify bot merged commit 6e0f6e0 into csi-addons:main Feb 17, 2025
15 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants