[#1410] engine: Provide the default implementation to MetricsRegister
All checks were successful
DCO action / DCO (pull_request) Successful in 1m6s
Tests and linters / Run gofumpt (pull_request) Successful in 1m26s
Pre-commit hooks / Pre-commit (pull_request) Successful in 2m9s
Vulncheck / Vulncheck (pull_request) Successful in 2m16s
Build / Build Components (pull_request) Successful in 2m40s
Tests and linters / gopls check (pull_request) Successful in 2m53s
Tests and linters / Staticcheck (pull_request) Successful in 3m11s
Tests and linters / Lint (pull_request) Successful in 3m42s
Tests and linters / Tests (pull_request) Successful in 4m29s
Tests and linters / Tests with -race (pull_request) Successful in 6m13s

Signed-off-by: Evgenii Stratonikov <e.stratonikov@yadro.com>
This commit is contained in:
Evgenii Stratonikov 2024-10-03 10:40:56 +03:00
parent 82674c0439
commit 906f3edfaa
11 changed files with 77 additions and 55 deletions

View file

@ -82,9 +82,7 @@ func (e *StorageEngine) getRange(ctx context.Context, prm RngPrm) (RngRes, error
))
defer span.End()
if e.metrics != nil {
defer elapsed("GetRange", e.metrics.AddMethodDuration)()
}
defer elapsed("GetRange", e.metrics.AddMethodDuration)()
var shPrm shard.RngPrm
shPrm.SetAddress(prm.addr)