Browse Source

修改上传文件逻辑引用

tianboguang 3 năm trước cách đây
mục cha
commit
7069241428

+ 5 - 4
src/main/java/com/fdkankan/modeling/receiver/RabbitMqListener.java

@@ -5,6 +5,7 @@ import cn.hutool.core.util.StrUtil;
 import com.alibaba.fastjson.JSONObject;
 import com.fdkankan.common.constant.ModelingBuildStatus;
 import com.fdkankan.common.util.FileUtils;
+import com.fdkankan.fyun.config.FYunFileConfig;
 import com.fdkankan.fyun.face.FYunFileServiceInterface;
 import com.fdkankan.model.constants.ConstantFilePath;
 import com.fdkankan.model.constants.UploadFilePath;
@@ -72,13 +73,13 @@ public class RabbitMqListener {
     @Value("${4dkk.laserService.host}")
     private String laserHost;
 
-    @Value("${oss.prefix.ali}")
-    private String prefixAli;
-
     @Autowired
     private FYunFileServiceInterface fYunFileService;
 
     @Autowired
+    private FYunFileConfig fYunFileConfig;
+
+    @Autowired
     private RabbitMqProducer rabbitMqProducer;
 
     @Autowired
@@ -321,7 +322,7 @@ public class RabbitMqListener {
 
                 //如果是重复计算,没有走到计算逻辑,不需要上传日志文件
                 String buildLogPath = String.format(UploadFilePath.BUILD_LOG_PATH, message.getSceneNum());
-                buildLog.setLogDetailPath(prefixAli+ buildLogPath + "console.log");
+                buildLog.setLogDetailPath(fYunFileConfig+ buildLogPath + "console.log");
             }
             buildLog.setCameraType(Integer.parseInt(buildSceneResult.getCameraType()));
             buildLogService.updateById(buildLog);

+ 0 - 4
src/main/resources/bootstrap-test.yml

@@ -28,10 +28,6 @@ spring:
             group: DEFAULT_GROUP
             refresh: true
 
-          - data-id: common-upload-config.yaml
-            group: DEFAULT_GROUP
-            refresh: true
-
           - data-id: common-fyun-config.yaml
             group: DEFAULT_GROUP
             refresh: true