aeraki-mesh / aeraki

Manage any layer-7 protocols in a Service Mesh.
https://www.aeraki.net
Apache License 2.0
740 stars 140 forks source link

controller-runtimer: log.SetLogger(...) was never called, logs will not be displayed #386

Open zhaohuabing opened 1 year ago

zhaohuabing commented 1 year ago

Describe the bug A clear and concise description of what the bug is.

To Reproduce Install Aeraki and view Aeraki logs using kubectl logs ...

Expected behavior

[controller-runtime] log.SetLogger(...) was never called, logs will not be displayed:
goroutine 276 [running]:
runtime/debug.Stack()
    /usr/local/go/src/runtime/debug/stack.go:24 +0x65
sigs.k8s.io/controller-runtime/pkg/log.eventuallyFulfillRoot()
    /Users/huabingzhao/go/pkg/mod/sigs.k8s.io/controller-runtime@v0.15.1/pkg/log/log.go:59 +0xbd
sigs.k8s.io/controller-runtime/pkg/log.(*delegatingLogSink).Enabled(0xc000ee62c0, 0x10?)
    /Users/huabingzhao/go/pkg/mod/sigs.k8s.io/controller-runtime@v0.15.1/pkg/log/deleg.go:111 +0x3d
github.com/go-logr/logr.Logger.Enabled(...)
    /Users/huabingzhao/go/pkg/mod/github.com/go-logr/logr@v1.2.4/logr.go:261
github.com/go-logr/logr.Logger.Info({{0x3d365c0?, 0xc000ee62c0?}, 0xc001665a00?}, {0xc000f6c000, 0x4a}, {0xc000b27c80, 0x6, 0x6})
    /Users/huabingzhao/go/pkg/mod/github.com/go-logr/logr@v1.2.4/logr.go:274 +0x78
sigs.k8s.io/controller-runtime/pkg/internal/recorder.(*Provider).getBroadcaster.func1.1(0xc000eb8a00)
    /Users/huabingzhao/go/pkg/mod/sigs.k8s.io/controller-runtime@v0.15.1/pkg/internal/recorder/recorder.go:104 +0x1ed
k8s.io/client-go/tools/record.(*eventBroadcasterImpl).StartEventWatcher.func1()
    /Users/huabingzhao/go/pkg/mod/k8s.io/client-go@v0.27.0/tools/record/event.go:327 +0xa2
created by k8s.io/client-go/tools/record.(*eventBroadcasterImpl).StartEventWatcher
    /Users/huabingzhao/go/pkg/mod/k8s.io/client-go@v0.27.0/tools/record/event.go:318 +0x13d