forked from TrueCloudLab/frostfs-node
[#948] metrics: Set actual value for shard_id
after restart
Signed-off-by: Anton Nikiforov <an.nikiforov@yadro.com>
This commit is contained in:
parent
6a5769d1da
commit
0bd030507e
8 changed files with 27 additions and 1 deletions
|
@ -145,6 +145,10 @@ type writeCacheMetrics struct {
|
|||
metrics metrics.WriteCacheMetrics
|
||||
}
|
||||
|
||||
func (m *writeCacheMetrics) SetShardID(id string) {
|
||||
m.shardID = id
|
||||
}
|
||||
|
||||
func (m *writeCacheMetrics) Get(d time.Duration, success bool, st writecache.StorageType) {
|
||||
m.metrics.AddMethodDuration(m.shardID, "Get", success, d, st.String())
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue