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,41 @@
package com.njcn.gather.systemops.database.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.database.pojo.vo.DatabaseOverviewVO;
import com.njcn.gather.systemops.database.service.DatabaseService;
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("/database")
@RequiredArgsConstructor
public class DatabaseController extends BaseController {
private final DatabaseService databaseService;
@OperateInfo(info = LogEnum.BUSINESS_COMMON)
@ApiOperation("查询数据库监控基础信息")
@GetMapping("/overview")
public HttpResult<DatabaseOverviewVO> overview() {
String methodDescribe = getMethodDescribe("overview");
LogUtil.njcnDebug(log, "{},开始查询数据库监控基础信息", methodDescribe);
DatabaseOverviewVO result = databaseService.overview();
return HttpResultUtil.assembleCommonResponseResult(CommonResponseEnum.SUCCESS, result, methodDescribe);
}
}

View File

@@ -0,0 +1,38 @@
package com.njcn.gather.systemops.database.pojo.vo;
import lombok.Data;
import java.io.Serializable;
/**
* 数据库监控基础信息。
*/
@Data
public class DatabaseOverviewVO implements Serializable {
private static final long serialVersionUID = -6645576505607222597L;
/**
* 菜单名称。
*/
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.database.service;
import com.njcn.gather.systemops.database.pojo.vo.DatabaseOverviewVO;
/**
* 数据库监控基础服务。
*/
public interface DatabaseService {
/**
* 查询数据库监控基础信息。
*
* @return 数据库监控基础信息
*/
DatabaseOverviewVO overview();
}

View File

@@ -0,0 +1,25 @@
package com.njcn.gather.systemops.database.service.impl;
import com.njcn.gather.systemops.database.pojo.vo.DatabaseOverviewVO;
import com.njcn.gather.systemops.database.service.DatabaseService;
import org.springframework.stereotype.Service;
/**
* 数据库监控基础服务实现。
*/
@Service
public class DatabaseServiceImpl implements DatabaseService {
private static final String STATUS_READY = "READY";
@Override
public DatabaseOverviewVO overview() {
DatabaseOverviewVO result = new DatabaseOverviewVO();
result.setMenuName("数据库监控");
result.setMenuCode("database");
result.setPath("/systemOps/database");
result.setStatus(STATUS_READY);
result.setDescription("数据库监控基础入口已接入,后续可在此扩展连接状态、容量和性能指标。");
return result;
}
}