mirror of https://github.com/minio/minio.git
replication: clone metrics while loading metrics cache (#16462)
This commit is contained in:
parent
93fbb228bf
commit
ca2a1c3f60
|
@ -197,7 +197,8 @@ func (r *ReplicationStats) loadInitialReplicationMetrics(ctx context.Context) {
|
|||
m := make(map[string]*BucketReplicationStats)
|
||||
if stats, err := globalReplicationPool.loadStatsFromDisk(); err == nil {
|
||||
for b, st := range stats {
|
||||
m[b] = &st
|
||||
c := st.Clone()
|
||||
m[b] = &c
|
||||
}
|
||||
r.ulock.Lock()
|
||||
r.UsageCache = m
|
||||
|
|
Loading…
Reference in New Issue