fix: logger and context.

This commit is contained in:
Ludovic Fernandez 2019-09-13 19:28:04 +02:00 committed by Traefiker Bot
parent b4c7b90c9e
commit 8e18d37b3d
52 changed files with 231 additions and 183 deletions

View file

@ -155,8 +155,9 @@ func GoWithRecover(goroutine func(), customRecover func(err interface{})) {
}
func defaultRecoverGoroutine(err interface{}) {
log.Errorf("Error in Go routine: %s", err)
log.Errorf("Stack: %s", debug.Stack())
logger := log.WithoutContext()
logger.Errorf("Error in Go routine: %s", err)
logger.Errorf("Stack: %s", debug.Stack())
}
// OperationWithRecover wrap a backoff operation in a Recover