diff options
| author | Konstantin Lebedev <9497591+kmlebedev@users.noreply.github.com> | 2024-07-13 00:32:25 +0500 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2024-07-12 12:32:25 -0700 |
| commit | 33964fa29222195c459302c5c7aa7a8e467b725b (patch) | |
| tree | 690adb1dbac1b25fcf11022a3bc22635f18c20e4 /weed/topology/volume_layout.go | |
| parent | 04f4b108842742a7b0205a02baed32d3bacbb73f (diff) | |
| download | seaweedfs-33964fa29222195c459302c5c7aa7a8e467b725b.tar.xz seaweedfs-33964fa29222195c459302c5c7aa7a8e467b725b.zip | |
metrics stats of volume layout depends on the data center (#5775)
stats volume layout depends on the data center
Diffstat (limited to 'weed/topology/volume_layout.go')
| -rw-r--r-- | weed/topology/volume_layout.go | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/weed/topology/volume_layout.go b/weed/topology/volume_layout.go index 66f7118c9..f2c341b7c 100644 --- a/weed/topology/volume_layout.go +++ b/weed/topology/volume_layout.go @@ -356,9 +356,9 @@ func (vl *VolumeLayout) DoneGrowRequest() { func (vl *VolumeLayout) ShouldGrowVolumes(option *VolumeGrowOption) bool { total, active, crowded := vl.GetActiveVolumeCount(option) - stats.MasterVolumeLayout.WithLabelValues(option.Collection, option.ReplicaPlacement.String(), "total").Set(float64(total)) - stats.MasterVolumeLayout.WithLabelValues(option.Collection, option.ReplicaPlacement.String(), "active").Set(float64(active)) - stats.MasterVolumeLayout.WithLabelValues(option.Collection, option.ReplicaPlacement.String(), "crowded").Set(float64(crowded)) + stats.MasterVolumeLayout.WithLabelValues(option.Collection, option.DataCenter, "total").Set(float64(total)) + stats.MasterVolumeLayout.WithLabelValues(option.Collection, option.DataCenter, "active").Set(float64(active)) + stats.MasterVolumeLayout.WithLabelValues(option.Collection, option.DataCenter, "crowded").Set(float64(crowded)) //glog.V(0).Infof("active volume: %d, high usage volume: %d\n", active, high) return active <= crowded } |
