|
@@ -175,10 +175,6 @@ public class TaskService {
|
|
|
log.info("del-scene:{},oss-path:{}",num,laserOssPath);
|
|
log.info("del-scene:{},oss-path:{}",num,laserOssPath);
|
|
|
fYunFileServiceInterface.deleteFolder(laserOssPath);
|
|
fYunFileServiceInterface.deleteFolder(laserOssPath);
|
|
|
|
|
|
|
|
- String origPath = dataSource.replace("/mnt/data","home");
|
|
|
|
|
- log.info("del-scene:{},oss-orig-path:{}",num,origPath);
|
|
|
|
|
- fYunFileServiceInterface.deleteFolder(origPath);
|
|
|
|
|
-
|
|
|
|
|
for (String meshPath : meshOssPath) {
|
|
for (String meshPath : meshOssPath) {
|
|
|
log.info("del-scene:{},oss-path:{}",num,String.format(meshPath,num));
|
|
log.info("del-scene:{},oss-path:{}",num,String.format(meshPath,num));
|
|
|
if(meshPath.contains(".zip")){
|
|
if(meshPath.contains(".zip")){
|
|
@@ -193,12 +189,16 @@ public class TaskService {
|
|
|
FileUtil.del(String.format(meshPath,num));
|
|
FileUtil.del(String.format(meshPath,num));
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
- if(StringUtils.isNotBlank(dataSource)){
|
|
|
|
|
|
|
+ if(checkDataSource(dataSource)){
|
|
|
List<ScenePro> scenePros = sceneProService.getDataSource(dataSource);
|
|
List<ScenePro> scenePros = sceneProService.getDataSource(dataSource);
|
|
|
List<ScenePlusExt> scenePlusExts = scenePlusExtService.getDataSource(dataSource);
|
|
List<ScenePlusExt> scenePlusExts = scenePlusExtService.getDataSource(dataSource);
|
|
|
if(!scenePros.isEmpty() || !scenePlusExts.isEmpty()){
|
|
if(!scenePros.isEmpty() || !scenePlusExts.isEmpty()){
|
|
|
return;
|
|
return;
|
|
|
}
|
|
}
|
|
|
|
|
+ String origPath = dataSource.replace("/mnt/data","home");
|
|
|
|
|
+ log.info("del-scene:{},oss-orig-path:{}",num,origPath);
|
|
|
|
|
+ fYunFileServiceInterface.deleteFolder(origPath);
|
|
|
|
|
+
|
|
|
log.info("del-scene:{},nas-path:{}",num,dataSource);
|
|
log.info("del-scene:{},nas-path:{}",num,dataSource);
|
|
|
FileUtil.del(dataSource);
|
|
FileUtil.del(dataSource);
|
|
|
for (String meshPath : meshNasDataSourcePath) {
|
|
for (String meshPath : meshNasDataSourcePath) {
|
|
@@ -212,4 +212,12 @@ public class TaskService {
|
|
|
}
|
|
}
|
|
|
|
|
|
|
|
}
|
|
}
|
|
|
|
|
+
|
|
|
|
|
+ public static boolean checkDataSource(String dataSource) {
|
|
|
|
|
+ if(StringUtils.isBlank(dataSource)){
|
|
|
|
|
+ return false;
|
|
|
|
|
+ }
|
|
|
|
|
+ return dataSource.contains("/mnt/data") && dataSource.split("/").length >4;
|
|
|
|
|
+ }
|
|
|
|
|
+
|
|
|
}
|
|
}
|