| @@ -219,14 +219,17 @@ func (s *AiStorage) SaveClusterResources(adapterId string, clusterId string, clu | |||||
| } | } | ||||
| // prometheus | // prometheus | ||||
| param := tracker.ClusterLoadRecord{ | param := tracker.ClusterLoadRecord{ | ||||
| AdapterId: aId, | |||||
| ClusterName: clusterName, | |||||
| CpuAvail: cpuAvail, | |||||
| CpuTotal: cpuTotal, | |||||
| MemoryAvail: memAvail, | |||||
| MemoryTotal: memTotal, | |||||
| DiskAvail: diskAvail, | |||||
| DiskTotal: diskTotal, | |||||
| AdapterId: aId, | |||||
| ClusterName: clusterName, | |||||
| CpuAvail: cpuAvail, | |||||
| CpuTotal: cpuTotal, | |||||
| CpuUtilisation: clusterResource.CpuAvail / clusterResource.CpuTotal, | |||||
| MemoryAvail: memAvail, | |||||
| MemoryTotal: memTotal, | |||||
| MemoryUtilisation: clusterResource.MemAvail / clusterResource.MemTotal, | |||||
| DiskAvail: diskAvail, | |||||
| DiskTotal: diskTotal, | |||||
| DiskUtilisation: clusterResource.DiskAvail / clusterResource.DiskTotal, | |||||
| } | } | ||||
| tracker.SyncClusterLoad(param) | tracker.SyncClusterLoad(param) | ||||
| return nil | return nil | ||||