Skip to content

Commit

Permalink
Switch alias.go to new logging pkg layout
Browse files Browse the repository at this point in the history
This switches alias.go over to the new logging layout.  In order to
avoid alias.go pulling in Zap, we don't put ZapLogger in alias.go any
more.  Practically, this is probably fine.  It means an extra line in
main.go, but it's just one, and allows people to avoid extraneous
dependencies.
  • Loading branch information
DirectXMan12 committed Jan 9, 2019
1 parent 5b02cc2 commit 140b281
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions alias.go
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ import (
"sigs.k8s.io/controller-runtime/pkg/controller/controllerutil"
"sigs.k8s.io/controller-runtime/pkg/manager"
"sigs.k8s.io/controller-runtime/pkg/reconcile"
"sigs.k8s.io/controller-runtime/pkg/runtime/log"
"sigs.k8s.io/controller-runtime/pkg/log"
"sigs.k8s.io/controller-runtime/pkg/runtime/scheme"
"sigs.k8s.io/controller-runtime/pkg/runtime/signals"
)
Expand Down Expand Up @@ -126,10 +126,4 @@ var (

// SetLogger sets a concrete logging implementation for all deferred Loggers.
SetLogger = log.SetLogger

// ZapLogger is a Logger implementation.
// If development is true, a Zap development config will be used
// (stacktraces on warnings, no sampling), otherwise a Zap production
// config will be used (stacktraces on errors, sampling).
ZapLogger = log.ZapLogger
)

0 comments on commit 140b281

Please sign in to comment.