Don't block websocket from handling another message when a long running proccess is triggered
This commit is contained in:
parent
8315ff8ae1
commit
6de18f09e5
|
@ -51,8 +51,10 @@ func getServerWebsocket(c *gin.Context) {
|
||||||
continue
|
continue
|
||||||
}
|
}
|
||||||
|
|
||||||
if err := handler.HandleInbound(j); err != nil {
|
go func(msg websocket.Message) {
|
||||||
handler.SendErrorJson(j, err)
|
if err := handler.HandleInbound(msg); err != nil {
|
||||||
|
handler.SendErrorJson(msg, err)
|
||||||
}
|
}
|
||||||
|
}(j)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user