You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Using single logger in the whole application is not a good idea apparently as memory races happen. We should make this more concurrent friendly or use logger per goroutine.
WARNING: DATA RACE
Write at 0x00c000254730 by goroutine 12:
github.com/infrawatch/apputils/logging.(*Logger).Metadata()
/home/para/Projects/go/pkg/mod/github.com/infrawatch/[email protected]/logging/logger.go:80 +0xe4
github.com/infrawatch/sg-core/plugins/transport/socket.(*logWrapper).Infof()
/root/sg-core/plugins/transport/socket/main.go:48 +0x31
github.com/infrawatch/sg-core/plugins/transport/socket.(*Socket).Run()
/root/sg-core/plugins/transport/socket/main.go:87 +0x2b9
github.com/infrawatch/sg-core/cmd/manager.RunTransports.func2()
/root/sg-core/cmd/manager/manager.go:177 +0x153
Using single logger in the whole application is not a good idea apparently as memory races happen. We should make this more concurrent friendly or use logger per goroutine.
WARNING: DATA RACE
Write at 0x00c000254730 by goroutine 12:
github.com/infrawatch/apputils/logging.(*Logger).Metadata()
/home/para/Projects/go/pkg/mod/github.com/infrawatch/[email protected]/logging/logger.go:80 +0xe4
github.com/infrawatch/sg-core/plugins/transport/socket.(*logWrapper).Infof()
/root/sg-core/plugins/transport/socket/main.go:48 +0x31
github.com/infrawatch/sg-core/plugins/transport/socket.(*Socket).Run()
/root/sg-core/plugins/transport/socket/main.go:87 +0x2b9
github.com/infrawatch/sg-core/cmd/manager.RunTransports.func2()
/root/sg-core/cmd/manager/manager.go:177 +0x153
Previous write at 0x00c000254730 by goroutine 13:
github.com/infrawatch/apputils/logging.(*Logger).writeRecord()
/home/para/Projects/go/pkg/mod/github.com/infrawatch/[email protected]/logging/logger.go:182 +0x201
github.com/infrawatch/apputils/logging.(*Logger).Info()
/home/para/Projects/go/pkg/mod/github.com/infrawatch/[email protected]/logging/logger.go:198 +0x1020
github.com/infrawatch/sg-core/plugins/application/elasticsearch.(*Elasticsearch).Run()
/root/sg-core/plugins/application/elasticsearch/main.go:115 +0x20f
github.com/infrawatch/sg-core/cmd/manager.RunApplications.func1()
/root/sg-core/cmd/manager/manager.go:196 +0xa2
Goroutine 12 (running) created at:
github.com/infrawatch/sg-core/cmd/manager.RunTransports()
/root/sg-core/cmd/manager/manager.go:175 +0x20c
main.main()
/root/sg-core/cmd/main.go:118 +0xe40
Goroutine 13 (running) created at:
github.com/infrawatch/sg-core/cmd/manager.RunApplications()
/root/sg-core/cmd/manager/manager.go:194 +0x14e
main.main()
/root/sg-core/cmd/main.go:119 +0xe78
The text was updated successfully, but these errors were encountered: