wanghongbo

切垫片接口修改

... ... @@ -136,7 +136,7 @@ public class BackupMaterialServiceImpl extends ServiceImpl<BackupMaterialMapper,
List<StreamTask> playTasks = streamTaskMapper.selectList(playWrapper);
if(CollectionUtil.isNotEmpty(playTasks)){
playTasks.forEach(playTask -> {
changeChannelSource(playTask.getTaskId(), destFilePath);
changeBackup(playTask.getTaskId(), destFilePath);
});
}
}
... ... @@ -162,6 +162,7 @@ public class BackupMaterialServiceImpl extends ServiceImpl<BackupMaterialMapper,
log.info("请求转码系统换垫片接口成功");
}else {
log.info("请求转码系统换垫片接口响应失败,response:{}",response);
throw new BusinessException("请求转码系统换垫片接口响应失败");
}
} else {
log.error("请求转码系统换垫片接口失败,url:{},body:{}", swapBackupUrl, execute.body());
... ... @@ -192,6 +193,7 @@ public class BackupMaterialServiceImpl extends ServiceImpl<BackupMaterialMapper,
log.info("请求转码系统切换直播源接口成功");
}else {
log.info("请求转码系统切换直播源接口响应失败,response:{}",response);
throw new BusinessException("请求转码系统切换直播源接口响应失败");
}
} else {
log.error("请求转码系统切换直播源接口失败,url:{},body:{}", switchStreamUrl, execute.body());
... ... @@ -226,7 +228,7 @@ public class BackupMaterialServiceImpl extends ServiceImpl<BackupMaterialMapper,
if(CollectionUtil.isNotEmpty(playTasks)){
String backupPath = realPath + backupConfig.getBackupPath();
playTasks.forEach(playTask -> {
changeChannelSource(playTask.getTaskId(), backupPath);
changeBackup(playTask.getTaskId(), backupPath);
});
}
}else {
... ...