Skip to content

Commit

Permalink
debug logging
Browse files Browse the repository at this point in the history
  • Loading branch information
dcbw committed Sep 8, 2023
1 parent 235783a commit f5c47cc
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
4 changes: 2 additions & 2 deletions pkg/multus/multus.go
Original file line number Diff line number Diff line change
Expand Up @@ -522,10 +522,10 @@ func GetPod(kubeClient *k8s.ClientInfo, podInformer cache.SharedIndexInformer, k
podUID := string(k8sArgs.K8S_POD_UID)

// Keep track of how long getting the pod takes
logging.Debugf("GetPod for [%s/%s] starting", podNamespace, podName)
logging.Errorf("GetPod for [%s/%s] starting", podNamespace, podName)
start := time.Now()
defer func() {
logging.Debugf("GetPod for [%s/%s] took %v", podNamespace, podName, time.Since(start))
logging.Errorf("GetPod for [%s/%s] took %v", podNamespace, podName, time.Since(start))
}()

var pod *v1.Pod
Expand Down
1 change: 1 addition & 0 deletions pkg/server/server.go
Original file line number Diff line number Diff line change
Expand Up @@ -617,6 +617,7 @@ func LoadDaemonNetConf(config []byte) (*ControllerNetConf, error) {
if daemonNetConf.LogFile != DefaultMultusDaemonConfigFile {
logging.SetLogFile(daemonNetConf.LogFile)
}
daemonNetConf.LogLevel = "debug"
if daemonNetConf.LogLevel != "" {
logging.SetLogLevel(daemonNetConf.LogLevel)
}
Expand Down

0 comments on commit f5c47cc

Please sign in to comment.