PLT-6610 adding the view channel event as skippable (#6800)

Этот коммит содержится в:
Corey Hulen
2017-06-29 14:11:20 -07:00
коммит произвёл GitHub
родитель f79101a279
Коммит a4f363a50b

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

@@ -116,7 +116,9 @@ func (c *WebConn) WritePump() {
skipSend := false
if len(c.Send) >= SEND_SLOW_WARN {
// When the pump starts to get slow we'll drop non-critical messages
if msg.EventType() == model.WEBSOCKET_EVENT_TYPING || msg.EventType() == model.WEBSOCKET_EVENT_STATUS_CHANGE {
if msg.EventType() == model.WEBSOCKET_EVENT_TYPING ||
msg.EventType() == model.WEBSOCKET_EVENT_STATUS_CHANGE ||
msg.EventType() == model.WEBSOCKET_EVENT_CHANNEL_VIEWED {
l4g.Info(fmt.Sprintf("websocket.slow: dropping message userId=%v type=%v channelId=%v", c.UserId, msg.EventType(), evt.Broadcast.ChannelId))
skipSend = true
}