Metrics operations shouldn't be inside goroutine (#13950)

Metrics operations are done in memory so there is no need
to spawn a new goroutine
Этот коммит содержится в:
Mario de Frutos Dieguez
2020-03-03 11:53:32 +01:00
коммит произвёл GitHub
родитель 2a5d30f8f3
Коммит 89f4e9d7ef

Просмотреть файл

@@ -232,9 +232,7 @@ func (wc *WebConn) writePump() {
}
if wc.App.Metrics() != nil {
wc.App.Srv().Go(func() {
wc.App.Metrics().IncrementWebSocketBroadcast(msg.EventType())
})
wc.App.Metrics().IncrementWebSocketBroadcast(msg.EventType())
}
}