修复stream-none-reader-delay-ms为-1时不自动关闭流

This commit is contained in:
64850858
2021-07-26 17:22:40 +08:00
parent ea32cd2673
commit 95ed662935
11 changed files with 70 additions and 23 deletions

View File

@@ -374,4 +374,6 @@ public interface IVideoManagerStorager {
void updateMediaServer(MediaServerItem mediaServerItem);
List<StreamProxyItem> getStreamProxyListForEnableInMediaServer(String id, boolean b);
Device queryVideoDeviceByChannelId(String platformGbId);
}

View File

@@ -102,4 +102,7 @@ public interface DeviceChannelMapper {
" </script>"})
List<ChannelReduce> queryChannelListInAll(String query, Boolean online, Boolean hasSubChannel, String platformId, Boolean inPlatform);
@Select("SELECT * FROM device_channel WHERE channelId=#{channelId}")
List<DeviceChannel> queryChannelByChannelId(String channelId);
}

View File

@@ -623,4 +623,14 @@ public class VideoManagerStoragerImpl implements IVideoManagerStorager {
public List<StreamProxyItem> getStreamProxyListForEnableInMediaServer(String id, boolean enable) {
return streamProxyMapper.selectForEnableInMediaServer(id, enable);
}
@Override
public Device queryVideoDeviceByChannelId(String channelId) {
Device result = null;
List<DeviceChannel> channelList = deviceChannelMapper.queryChannelByChannelId(channelId);
if (channelList.size() == 1) {
result = deviceMapper.getDeviceByDeviceId(channelList.get(0).getDeviceId());
}
return result;
}
}