shard: Update metric mode_info on Init #1174

Merged
fyrchik merged 1 commit from acid-ant/frostfs-node:bugfix/upd-mode-metric-init into master 2024-06-13 08:33:06 +00:00

View file

@ -484,6 +484,7 @@ func (s *Shard) updateMetrics(ctx context.Context) {
s.setContainerObjectsCount(contID.EncodeToString(), logical, count.Logic)
s.setContainerObjectsCount(contID.EncodeToString(), user, count.User)
}
s.cfg.metricsWriter.SetMode(s.info.Mode)
fyrchik marked this conversation as resolved
Review

All other methods check whether s.cfg.metricsWriter != nil, I suggest adding the check here too.

All other methods check whether `s.cfg.metricsWriter != nil`, I suggest adding the check here too.
Review

It's done at the beginning of the method.

It's done at the beginning of the method.
}
// incObjectCounter increment both physical and logical object