Skip to content

Commit

Permalink
Merge pull request #9623 from ericchiang/grpc-logs
Browse files Browse the repository at this point in the history
etcdctl/ctlv3/command: enable gRPC WARNING logs by default
  • Loading branch information
gyuho authored Apr 25, 2018
2 parents 189d24e + 9ce295a commit e73f909
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion etcdctl/ctlv3/command/global.go
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,9 @@ func clientConfigFromCmd(cmd *cobra.Command) *clientConfig {
fmt.Fprintf(os.Stderr, "%s=%v\n", flags.FlagToEnv("ETCDCTL", f.Name), f.Value)
})
} else {
clientv3.SetLogger(grpclog.NewLoggerV2(ioutil.Discard, ioutil.Discard, ioutil.Discard))
// Enable logging for WARNING and ERROR since these levels include issues with
// connecting to the server, such as TLS misconfiguration.
clientv3.SetLogger(grpclog.NewLoggerV2(ioutil.Discard, os.Stderr, os.Stderr))
}

cfg := &clientConfig{}
Expand Down

0 comments on commit e73f909

Please sign in to comment.