|
@@ -203,6 +203,9 @@ public class VideoStableServiceImpl extends BaseServiceImpl<VideoStableMapper, V
|
|
|
return this.removeByIds(Arrays.asList(ids));
|
|
|
}
|
|
|
|
|
|
+ @Resource
|
|
|
+ private CommonAlgorithmConfigServiceImpl algorithmConfigService;
|
|
|
+
|
|
|
@Override
|
|
|
public CommonResult start(Long id) {
|
|
|
VideoStable videoStable = getById(id);
|
|
@@ -235,7 +238,9 @@ public class VideoStableServiceImpl extends BaseServiceImpl<VideoStableMapper, V
|
|
|
|
|
|
videoStable.setLogPath(videoStable.getOutputPath() + File.separator + getLogFileName(videoStable));
|
|
|
|
|
|
- HttpResponseEntity responseEntity = sendPostMsg(video_stable_start_url, videoStable);
|
|
|
+ String url = algorithmConfigService.getByAlgorithmName("电子稳相").getStartApi();
|
|
|
+
|
|
|
+ HttpResponseEntity responseEntity = sendPostMsg(url, videoStable);
|
|
|
if (ObjectUtil.isNotNull(responseEntity) && responseEntity.getStatus() == 200) {
|
|
|
return CommonResult.success("任务开始成功,请等待完成");
|
|
|
} else {
|
|
@@ -329,7 +334,10 @@ public class VideoStableServiceImpl extends BaseServiceImpl<VideoStableMapper, V
|
|
|
VideoStable videoStable = getById(id);
|
|
|
|
|
|
videoStable.setLogPath(videoStable.getOutputPath() + File.separator + getLogFileName(videoStable));
|
|
|
- HttpResponseEntity responseEntity = sendPostMsg(video_stable_stop_url, videoStable);
|
|
|
+
|
|
|
+ String url = algorithmConfigService.getByAlgorithmName("电子稳相").getTerminateApi();
|
|
|
+
|
|
|
+ HttpResponseEntity responseEntity = sendPostMsg(url, videoStable);
|
|
|
if (ObjectUtil.isNotNull(responseEntity) && responseEntity.getStatus() == 200) {
|
|
|
videoStable.setStatus(BizConstant.VideoStatus.INTERRUPTED);
|
|
|
updateById(videoStable);
|