装置文件系统管理
This commit is contained in:
@@ -6,6 +6,7 @@ import com.njcn.common.pojo.enums.common.LogEnum;
|
||||
import com.njcn.common.pojo.response.HttpResult;
|
||||
|
||||
import com.njcn.message.api.fallback.ProduceFeignClientFallbackFactory;
|
||||
import com.njcn.message.message.AskFileSysMessage;
|
||||
import com.njcn.message.message.DeviceRebootMessage;
|
||||
import com.njcn.message.message.ProcessRebootMessage;
|
||||
import com.njcn.message.message.RecallMessage;
|
||||
@@ -38,4 +39,7 @@ public interface ProduceFeignClient {
|
||||
|
||||
public HttpResult<Boolean> askRestartProcess(@RequestBody ProcessRebootMessage message);
|
||||
|
||||
@PostMapping("/askFileSys")
|
||||
public HttpResult<String> askFileSys(@RequestBody AskFileSysMessage message);
|
||||
|
||||
}
|
||||
|
||||
@@ -5,6 +5,7 @@ import com.njcn.common.pojo.exception.BusinessException;
|
||||
import com.njcn.common.pojo.response.HttpResult;
|
||||
|
||||
import com.njcn.message.api.ProduceFeignClient;
|
||||
import com.njcn.message.message.AskFileSysMessage;
|
||||
import com.njcn.message.message.DeviceRebootMessage;
|
||||
import com.njcn.message.message.ProcessRebootMessage;
|
||||
import com.njcn.message.message.RecallMessage;
|
||||
@@ -53,6 +54,12 @@ public class ProduceFeignClientFallbackFactory implements FallbackFactory<Produc
|
||||
log.error("{}异常,降级处理,异常为:{}", "进程重启", throwable.toString());
|
||||
throw new BusinessException(finalExceptionEnum);
|
||||
}
|
||||
|
||||
@Override
|
||||
public HttpResult<String> askFileSys(AskFileSysMessage message) {
|
||||
log.error("{}异常,降级处理,异常为:{}", "请求装置文件系统", throwable.toString());
|
||||
throw new BusinessException(finalExceptionEnum);
|
||||
}
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
@@ -37,6 +37,9 @@ public interface BusinessTopic {
|
||||
String ASK_REAL_DATA_TOPIC = "ask_real_data_topic";
|
||||
String RECALL_TOPIC = "recall_Topic";
|
||||
|
||||
String FILE_TOPIC = "File_Topic";
|
||||
|
||||
|
||||
|
||||
|
||||
/********************************数据中心*********************************/
|
||||
|
||||
@@ -0,0 +1,36 @@
|
||||
package com.njcn.message.message;
|
||||
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* Description:
|
||||
* Date: 2024/12/13 10:15【需求编号】
|
||||
*
|
||||
* @author clam
|
||||
* @version V1.0.0
|
||||
*/
|
||||
@Data
|
||||
public class AskFileSysMessage {
|
||||
|
||||
|
||||
/**
|
||||
* guid : sdghsfdhfdhdfhdfghd234234534534
|
||||
* frontid : dhdfhdfghd2342
|
||||
* ProcessNo : 1
|
||||
* devid : 167456737637374567
|
||||
* type : 2
|
||||
* Path : /remote/vol1_stat.txt
|
||||
* DevPath : /etc/vol1_stat.txt
|
||||
*/
|
||||
|
||||
private String guid;
|
||||
private String nodeId;
|
||||
private int processNo;
|
||||
private String devId;
|
||||
private int type;
|
||||
private String path;
|
||||
private String remotePath;
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,26 @@
|
||||
package com.njcn.message.messagedto;
|
||||
|
||||
import com.njcn.middle.rocket.domain.BaseMessage;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
|
||||
/**
|
||||
* Description:
|
||||
* Date: 2026/04/29 下午 3:16【需求编号】
|
||||
*
|
||||
* @author clam
|
||||
* @version V1.0.0
|
||||
*/
|
||||
@Data
|
||||
public class FileSysDTO<T> extends BaseMessage implements Serializable {
|
||||
private String guid;
|
||||
private String nodeId;
|
||||
private int processNo;
|
||||
private String devId;
|
||||
private int type;
|
||||
private String path;
|
||||
private String devPath;
|
||||
private int result;
|
||||
private T detail;
|
||||
}
|
||||
Reference in New Issue
Block a user