Fix panic on influx shutdown.
Influx was shutdown before Poseidon was terminated. In that mean time the Profiling data has been written. Also in that mean time, a periodical influx event triggers a panic since influx is already shutdown. We implemented two changes, each fixing this scenario.
This commit is contained in:

committed by
Sebastian Serth

parent
5fe9b686c2
commit
a4599f2cf9
@@ -215,12 +215,12 @@ func main() {
|
||||
initSentry(&config.Config.Sentry, config.Config.Profiling.Enabled)
|
||||
defer shutdownSentry()
|
||||
|
||||
stopProfiling := initProfiling(config.Config.Profiling)
|
||||
defer stopProfiling()
|
||||
|
||||
cancel := monitoring.InitializeInfluxDB(&config.Config.InfluxDB)
|
||||
defer cancel()
|
||||
|
||||
stopProfiling := initProfiling(config.Config.Profiling)
|
||||
defer stopProfiling()
|
||||
|
||||
server := initServer()
|
||||
go runServer(server)
|
||||
shutdownOnOSSignal(server)
|
||||
|
Reference in New Issue
Block a user