Add kubernetes objects aware logger with zap (#2179)

Using controller-runtime zap integration which is aware of Kubernetesobjects and logs only name+namespace of the object when complete runtime.Object compatible type is given to logger.

Signed-off-by: Sanket Sudake <sanketsudake@gmail.com>
This commit is contained in:
Sanket Sudake
2021-08-31 18:38:14 +05:30
committed by GitHub
parent f195975bda
commit a1cbce810e
13 changed files with 130 additions and 104 deletions
+3 -2
View File
@@ -47,8 +47,8 @@ require (
github.com/opencontainers/runc v1.0.1 // indirect
github.com/ory/dockertest v3.3.5+incompatible
github.com/pkg/errors v0.9.1
github.com/prometheus/client_golang v1.7.1
github.com/prometheus/common v0.10.0
github.com/prometheus/client_golang v1.11.0
github.com/prometheus/common v0.26.0
github.com/robfig/cron v0.0.0-20180505203441-b41be1df6967
github.com/satori/go.uuid v1.2.0
github.com/spf13/cobra v1.2.1
@@ -72,4 +72,5 @@ require (
k8s.io/client-go v0.21.4
k8s.io/klog v1.0.0
k8s.io/metrics v0.21.4
sigs.k8s.io/controller-runtime v0.9.6
)