日志逻辑修改

This commit is contained in:
俞扬
2023-06-29 04:04:19 +08:00
parent b794ec5438
commit 4b1e4f892f
4 changed files with 20 additions and 15 deletions

View File

@@ -44,17 +44,22 @@ public class VideoController {
@PostMapping("/callback")
@ApiOperation("音视频回调(腾讯云回调)")
public ResponseResult videoCallback(@RequestBody VideoCallBackDTO videoCallBackDTO) {
log.info("腾讯音视频上传完成回调request{}", JSONObject.toJSONString(videoCallBackDTO));
//不是音视频上传回调
if (311!= videoCallBackDTO.getEventType()) {
return null;
try {
log.info("腾讯音视频上传回调开始request{}", JSONObject.toJSONString(videoCallBackDTO));
//不是音视频上传的回调
if (311 != videoCallBackDTO.getEventType()) {
return null;
}
if (0 != videoCallBackDTO.getEventInfo().getPayload().getStatus()) {
log.error("腾讯音视频录制视频上传错误request\t{}", videoCallBackDTO);
return null;
}
videoService.handleVideoCallBack(videoCallBackDTO);
return new ResponseResult(0, "腾讯云回调音视频回调数据接收成功");
} catch (Exception e) {
log.error("腾讯音视频录制视频上传回调错误request\t{}", e.getMessage());
}
if (0 !=videoCallBackDTO.getEventInfo().getPayload().getStatus()) {
log.error("腾讯音视频录制视频上传错误request\t{}", videoCallBackDTO);
return null;
}
videoService.handleVideoCallBack(videoCallBackDTO);
return new ResponseResult(0, "腾讯云回调音视频回调数据接收成功");
return null;
}
}