【优化】服务器监控结果类2个属性名改正

pull/200/head
vchao 2024-03-26 14:11:26 +08:00
parent 6b18466988
commit 3131ffa409
3 changed files with 6 additions and 6 deletions

View File

@ -91,8 +91,8 @@
</a-row>
<a-card title="CPU监控" :bordered="false" class="mb-2">
<a-descriptions size="middle" :column="2" bordered>
<a-descriptions-item label="CPU名称">{{ devMonitorCpuInfo.cupName }}</a-descriptions-item>
<a-descriptions-item label="CPU数量">{{ devMonitorCpuInfo.cupNum }}</a-descriptions-item>
<a-descriptions-item label="CPU名称">{{ devMonitorCpuInfo.cpuName }}</a-descriptions-item>
<a-descriptions-item label="CPU数量">{{ devMonitorCpuInfo.cpuNum }}</a-descriptions-item>
<a-descriptions-item label="CPU物理核心数">{{ devMonitorCpuInfo.cpuPhysicalCoreNum }}</a-descriptions-item>
<a-descriptions-item label="CPU逻辑核心数">{{ devMonitorCpuInfo.cpuLogicalCoreNum }}</a-descriptions-item>
</a-descriptions>

View File

@ -65,11 +65,11 @@ public class DevMonitorServerResult {
/** CPU名称 */
@ApiModelProperty(value = "CPU名称", position = 1)
private String cupName;
private String cpuName;
/** CPU数量 */
@ApiModelProperty(value = "CPU数量", position = 2)
private String cupNum;
private String cpuNum;
/** CPU物理核心数 */
@ApiModelProperty(value = "CPU物理核心数", position = 3)

View File

@ -58,8 +58,8 @@ public class DevMonitorServiceImpl implements DevMonitorService {
// CPU信息
DevMonitorServerResult.DevMonitorCpuInfo devMonitorCpuInfo = new DevMonitorServerResult.DevMonitorCpuInfo();
devMonitorCpuInfo.setCupName(StrUtil.trim(cpu.getProcessorIdentifier().getName()));
devMonitorCpuInfo.setCupNum(cpu.getPhysicalPackageCount() + "颗物理CPU");
devMonitorCpuInfo.setCpuName(StrUtil.trim(cpu.getProcessorIdentifier().getName()));
devMonitorCpuInfo.setCpuNum(cpu.getPhysicalPackageCount() + "颗物理CPU");
devMonitorCpuInfo.setCpuPhysicalCoreNum(cpu.getPhysicalProcessorCount() + "个物理核心");
devMonitorCpuInfo.setCpuLogicalCoreNum(cpu.getLogicalProcessorCount() + "个逻辑核心");
long[] prevTicks = cpu.getSystemCpuLoadTicks();