This change lowers the levels of a few log messages in an attempt
to bring them more in line with the severity of the actual message.
Этот коммит содержится в:
Gabe Jackson
2019-05-21 13:57:26 -04:00
коммит произвёл Christopher Speller
родитель f8a89a52fc
Коммит 8c048a6604
3 изменённых файлов: 6 добавлений и 6 удалений

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

@@ -376,7 +376,7 @@ func (a *App) WaitForChannelMembership(channelId string, userId string) {
return
}
// If we received a error but it wasn't a missing channel member then return
// If we received an error, but it wasn't a missing channel member then return
if err.Id != store.MISSING_CHANNEL_MEMBER_ERROR {
return
}

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

@@ -19,7 +19,7 @@ const MaxOpenGraphResponseSize = 1024 * 1024 * 50
func (a *App) GetOpenGraphMetadata(requestURL string) *opengraph.OpenGraph {
res, err := a.HTTPService.MakeClient(false).Get(requestURL)
if err != nil {
mlog.Error("GetOpenGraphMetadata request failed", mlog.String("requestURL", requestURL), mlog.Err(err))
mlog.Warn("GetOpenGraphMetadata request failed", mlog.String("requestURL", requestURL), mlog.Err(err))
return nil
}
defer res.Body.Close()
@@ -31,7 +31,7 @@ func (a *App) ParseOpenGraphMetadata(requestURL string, body io.Reader, contentT
body = forceHTMLEncodingToUTF8(io.LimitReader(body, MaxOpenGraphResponseSize), contentType)
if err := og.ProcessHTML(body); err != nil {
mlog.Error("ParseOpenGraphMetadata processing failed", mlog.String("requestURL", requestURL), mlog.Err(err))
mlog.Warn("ParseOpenGraphMetadata processing failed", mlog.String("requestURL", requestURL), mlog.Err(err))
}
makeOpenGraphURLsAbsolute(og, requestURL)
@@ -54,7 +54,7 @@ func (a *App) ParseOpenGraphMetadata(requestURL string, body io.Reader, contentT
func forceHTMLEncodingToUTF8(body io.Reader, contentType string) io.Reader {
r, err := charset.NewReader(body, contentType)
if err != nil {
mlog.Error("forceHTMLEncodingToUTF8 failed to convert", mlog.String("contentType", contentType), mlog.Err(err))
mlog.Warn("forceHTMLEncodingToUTF8 failed to convert", mlog.String("contentType", contentType), mlog.Err(err))
return body
}
return r

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

@@ -200,9 +200,9 @@ func (c *WebConn) writePump() {
if len(c.Send) >= SEND_DEADLOCK_WARN {
if evtOk {
mlog.Error(fmt.Sprintf("websocket.full: message userId=%v type=%v channelId=%v size=%v", c.UserId, msg.EventType(), evt.Broadcast.ChannelId, len(msg.ToJson())))
mlog.Warn(fmt.Sprintf("websocket.full: message userId=%v type=%v channelId=%v size=%v", c.UserId, msg.EventType(), evt.Broadcast.ChannelId, len(msg.ToJson())))
} else {
mlog.Error(fmt.Sprintf("websocket.full: message userId=%v type=%v size=%v", c.UserId, msg.EventType(), len(msg.ToJson())))
mlog.Warn(fmt.Sprintf("websocket.full: message userId=%v type=%v size=%v", c.UserId, msg.EventType(), len(msg.ToJson())))
}
}