解决推流设备状态更新异常
This commit is contained in:
@@ -92,7 +92,7 @@ public class RedisPushStreamStatusMsgListener implements MessageListener, Applic
|
|||||||
streamPushService.online(streamStatusMessage.getOnlineStreams());
|
streamPushService.online(streamStatusMessage.getOnlineStreams());
|
||||||
}
|
}
|
||||||
} catch (Exception e) {
|
} catch (Exception e) {
|
||||||
log.warn("[REDIS消息-推流设备状态变化] 发现未处理的异常, \r\n{}", JSON.toJSONString(msg));
|
log.warn("[REDIS消息-推流设备状态变化] 发现未处理的异常, \r\n{}", JSON.parseObject(msg.getBody()));
|
||||||
log.error("[REDIS消息-推流设备状态变化] 异常内容: ", e);
|
log.error("[REDIS消息-推流设备状态变化] 异常内容: ", e);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -471,6 +471,9 @@ public class StreamPushServiceImpl implements IStreamPushService {
|
|||||||
public void online(List<StreamPushItemFromRedis> onlineStreams) {
|
public void online(List<StreamPushItemFromRedis> onlineStreams) {
|
||||||
// 更新部分设备上线streamPushService
|
// 更新部分设备上线streamPushService
|
||||||
List<StreamPush> streamPushList = streamPushMapper.getListFromRedis(onlineStreams);
|
List<StreamPush> streamPushList = streamPushMapper.getListFromRedis(onlineStreams);
|
||||||
|
if (streamPushList.isEmpty()) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
List<CommonGBChannel> commonGBChannelList = gbChannelService.queryListByStreamPushList(streamPushList);
|
List<CommonGBChannel> commonGBChannelList = gbChannelService.queryListByStreamPushList(streamPushList);
|
||||||
gbChannelService.online(commonGBChannelList);
|
gbChannelService.online(commonGBChannelList);
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user