Fix crash in console logger and also handle bucket DNS updates (#8654)

Also fix listenBucketNotification bugs seen by minio-js
listen bucket notification API.
This commit is contained in:
Harshavardhana
2019-12-16 20:30:57 -08:00
committed by kannappanr
parent 842d0241ed
commit c8d82588c2
19 changed files with 208 additions and 273 deletions

View File

@@ -38,7 +38,10 @@ import (
func init() {
logger.Init(GOPATH, GOROOT)
logger.RegisterError(config.FmtError)
logger.AddTarget(globalConsoleSys.Console())
// Initialize globalConsoleSys system
globalConsoleSys = NewConsoleLogger(context.Background())
logger.AddTarget(globalConsoleSys)
}
var (
@@ -145,9 +148,6 @@ func StartGateway(ctx *cli.Context, gw Gateway) {
// Set when gateway is enabled
globalIsGateway = true
// Initialize globalConsoleSys system
globalConsoleSys = NewConsoleLogger(context.Background(), globalEndpoints)
enableConfigOps := gatewayName == "nas"
// TODO: We need to move this code with globalConfigSys.Init()