feat(system-ops): 新增系统运维模块及稳态数据视图优化

- 添加 system-ops 模块及其子模块 dbms 和 deploy
- 实现数据库监控和系统部署的基础接口和服务
- 更新项目依赖配置和文档说明
- 优化稳态数据视图中线电压相位显示逻辑
- 完善线电压指标的相位解析和测试验证
This commit is contained in:
2026-05-21 14:08:15 +08:00
parent 89efc55119
commit 9a9614a9e5
21 changed files with 481 additions and 6 deletions

View File

@@ -0,0 +1,14 @@
# deploy 模块说明
## 模块定位
`deploy``system-ops` 下的系统部署模块,当前先提供系统部署菜单对应的后端基础入口。
## 当前接口
- `GET /deploy/overview`
- 查询系统部署基础信息。
## 当前限制
- 当前只完成后端基础入口,不包含真实部署包、环境、执行记录或部署执行逻辑。

30
system-ops/deploy/pom.xml Normal file
View File

@@ -0,0 +1,30 @@
<?xml version="1.0" encoding="UTF-8"?>
<project xmlns="http://maven.apache.org/POM/4.0.0"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>com.njcn.gather</groupId>
<artifactId>system-ops</artifactId>
<version>1.0.0</version>
</parent>
<artifactId>deploy</artifactId>
<packaging>jar</packaging>
<name>deploy</name>
<dependencies>
<dependency>
<groupId>com.njcn</groupId>
<artifactId>njcn-common</artifactId>
<version>0.0.1</version>
</dependency>
<dependency>
<groupId>com.njcn</groupId>
<artifactId>spingboot2.3.12</artifactId>
<version>2.3.12</version>
</dependency>
</dependencies>
</project>

View File

@@ -0,0 +1,41 @@
package com.njcn.gather.systemops.deploy.controller;
import com.njcn.common.pojo.annotation.OperateInfo;
import com.njcn.common.pojo.enums.common.LogEnum;
import com.njcn.common.pojo.enums.response.CommonResponseEnum;
import com.njcn.common.pojo.response.HttpResult;
import com.njcn.common.utils.LogUtil;
import com.njcn.gather.systemops.deploy.pojo.vo.DeployOverviewVO;
import com.njcn.gather.systemops.deploy.service.DeployService;
import com.njcn.web.controller.BaseController;
import com.njcn.web.utils.HttpResultUtil;
import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation;
import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
/**
* 系统部署基础接口。
*/
@Slf4j
@Api(tags = "系统部署")
@RestController
@RequestMapping("/deploy")
@RequiredArgsConstructor
public class DeployController extends BaseController {
private final DeployService deployService;
@OperateInfo(info = LogEnum.BUSINESS_COMMON)
@ApiOperation("查询系统部署基础信息")
@GetMapping("/overview")
public HttpResult<DeployOverviewVO> overview() {
String methodDescribe = getMethodDescribe("overview");
LogUtil.njcnDebug(log, "{},开始查询系统部署基础信息", methodDescribe);
DeployOverviewVO result = deployService.overview();
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, result, methodDescribe);
}
}

View File

@@ -0,0 +1,38 @@
package com.njcn.gather.systemops.deploy.pojo.vo;
import lombok.Data;
import java.io.Serializable;
/**
* 系统部署基础信息。
*/
@Data
public class DeployOverviewVO implements Serializable {
private static final long serialVersionUID = 5544653311667074541L;
/**
* 菜单名称。
*/
private String menuName;
/**
* 菜单编码。
*/
private String menuCode;
/**
* 菜单路径。
*/
private String path;
/**
* 基础功能状态。
*/
private String status;
/**
* 功能说明。
*/
private String description;
}

View File

@@ -0,0 +1,16 @@
package com.njcn.gather.systemops.deploy.service;
import com.njcn.gather.systemops.deploy.pojo.vo.DeployOverviewVO;
/**
* 系统部署基础服务。
*/
public interface DeployService {
/**
* 查询系统部署基础信息。
*
* @return 系统部署基础信息
*/
DeployOverviewVO overview();
}

View File

@@ -0,0 +1,25 @@
package com.njcn.gather.systemops.deploy.service.impl;
import com.njcn.gather.systemops.deploy.pojo.vo.DeployOverviewVO;
import com.njcn.gather.systemops.deploy.service.DeployService;
import org.springframework.stereotype.Service;
/**
* 系统部署基础服务实现。
*/
@Service
public class DeployServiceImpl implements DeployService {
private static final String STATUS_READY = "READY";
@Override
public DeployOverviewVO overview() {
DeployOverviewVO result = new DeployOverviewVO();
result.setMenuName("系统部署");
result.setMenuCode("deploy");
result.setPath("/systemOps/deploy");
result.setStatus(STATUS_READY);
result.setDescription("系统部署基础入口已接入,后续可在此扩展部署包、环境和执行记录。");
return result;
}
}