Commit 89976748 by 朱亚洁

feat: [1003010] 华为云迁移-OBS/MPC

parent 6cc82c8a
...@@ -2510,7 +2510,7 @@ public class AdvertisingSpaceBizImpl implements AdvertisingSpaceBiz { ...@@ -2510,7 +2510,7 @@ public class AdvertisingSpaceBizImpl implements AdvertisingSpaceBiz {
if (startTime.equals(0d) && endTime.equals(0d)) { if (startTime.equals(0d) && endTime.equals(0d)) {
musicUrl = fileUrl; musicUrl = fileUrl;
} else { } else {
String realUrl = OssUtils.submitClipJob(fileText, fileUrl, startTime.toString(), duration.toString()); String realUrl = convertConsr.clipCustomByUrlAndTime(fileText, fileUrl, startTime.toString(), duration.toString());
musicUrl = realUrl; musicUrl = realUrl;
} }
} catch (Exception e) { } catch (Exception e) {
......
...@@ -5,6 +5,7 @@ import com.pcloud.common.core.aspect.ParamLog; ...@@ -5,6 +5,7 @@ import com.pcloud.common.core.aspect.ParamLog;
import com.pcloud.common.utils.ResponseHandleUtil; import com.pcloud.common.utils.ResponseHandleUtil;
import com.pcloud.convert.file.entity.FileUploadInfo; import com.pcloud.convert.file.entity.FileUploadInfo;
import com.pcloud.convert.file.service.ConvertFileService; import com.pcloud.convert.file.service.ConvertFileService;
import com.pcloud.convert.file.service.TranscodeService;
import org.slf4j.Logger; import org.slf4j.Logger;
import org.slf4j.LoggerFactory; import org.slf4j.LoggerFactory;
...@@ -23,6 +24,8 @@ public class ConvertConsr { ...@@ -23,6 +24,8 @@ public class ConvertConsr {
@Autowired @Autowired
private ConvertFileService convertFileService; private ConvertFileService convertFileService;
@Autowired
private TranscodeService transcodeService;
/** /**
* 获取转码文件 * 获取转码文件
...@@ -40,4 +43,16 @@ public class ConvertConsr { ...@@ -40,4 +43,16 @@ public class ConvertConsr {
return fileUploadInfo; return fileUploadInfo;
} }
@ParamLog("音视频剪切")
public String clipCustomByUrlAndTime(String fileName, String fileUrl, String startTime, String duration){
String url = null;
try {
url = ResponseHandleUtil.parseResponse(transcodeService.clipCustomByUrlAndTime(fileName,fileUrl,startTime,duration), String.class);
}catch (Exception e){
LOGGER.error("音视频剪切失败"+e.getMessage(),e);
}
return url;
}
} }
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment