Merge pull request 'fix clusterResouces bugs' (#218) from tzwang/pcm-coordinator:master into master
Former-commit-id: 065653b186be3b52ac45b2b5f36f3e574b501b38
This commit is contained in:
commit
8bd0fcac07
|
@ -126,7 +126,7 @@ func (l *GetCenterOverviewLogic) updateClusterResource(mu *sync.RWMutex, ch chan
|
||||||
|
|
||||||
mu.Lock()
|
mu.Lock()
|
||||||
if (models.TClusterResource{} == *clusterResource) {
|
if (models.TClusterResource{} == *clusterResource) {
|
||||||
err = l.svcCtx.Scheduler.AiStorages.SaveClusterResources(c.Id, c.Name, clusterType, float64(stat.CpuCoreAvail), float64(stat.CpuCoreTotal),
|
err = l.svcCtx.Scheduler.AiStorages.SaveClusterResources(adapter.Id, c.Id, c.Name, clusterType, float64(stat.CpuCoreAvail), float64(stat.CpuCoreTotal),
|
||||||
stat.MemAvail, stat.MemTotal, stat.DiskAvail, stat.DiskTotal, float64(stat.GpuAvail), float64(stat.GpuTotal), cardTotal, topsTotal)
|
stat.MemAvail, stat.MemTotal, stat.DiskAvail, stat.DiskTotal, float64(stat.GpuAvail), float64(stat.GpuTotal), cardTotal, topsTotal)
|
||||||
if err != nil {
|
if err != nil {
|
||||||
mu.Unlock()
|
mu.Unlock()
|
||||||
|
|
Loading…
Reference in New Issue