fix server logging (#1417)

This commit is contained in:
Asim Aslam 2020-03-26 13:08:06 +00:00 committed by Vasiliy Tolstov
parent 422f951014
commit bf7cb081f4

View File

@ -830,7 +830,7 @@ func (g *grpcServer) Start() error {
// announce self to the world // announce self to the world
if err := g.Register(); err != nil { if err := g.Register(); err != nil {
if logger.V(logger.ErrorLevel, logger.DefaultLogger) { if logger.V(logger.ErrorLevel, logger.DefaultLogger) {
logger.Errorf("Server register error: ", err) logger.Errorf("Server register error: %v", err)
} }
} }
@ -838,7 +838,7 @@ func (g *grpcServer) Start() error {
go func() { go func() {
if err := g.srv.Serve(ts); err != nil { if err := g.srv.Serve(ts); err != nil {
if logger.V(logger.ErrorLevel, logger.DefaultLogger) { if logger.V(logger.ErrorLevel, logger.DefaultLogger) {
logger.Errorf("gRPC Server start error: ", err) logger.Errorf("gRPC Server start error: %v", err)
} }
} }
}() }()