[#1636] shard: Change ops limiter on shard reload
Some checks failed
DCO action / DCO (pull_request) Successful in 30s
Tests and linters / Run gofumpt (pull_request) Successful in 38s
Vulncheck / Vulncheck (pull_request) Successful in 1m20s
Pre-commit hooks / Pre-commit (pull_request) Failing after 1m38s
Build / Build Components (pull_request) Successful in 1m45s
Tests and linters / Tests (pull_request) Successful in 2m28s
Tests and linters / Staticcheck (pull_request) Successful in 2m35s
Tests and linters / Lint (pull_request) Successful in 3m11s
Tests and linters / gopls check (pull_request) Successful in 3m6s
Tests and linters / Tests with -race (pull_request) Successful in 5m5s

Signed-off-by: Dmitrii Stepanov <d.stepanov@yadro.com>
This commit is contained in:
Dmitrii Stepanov 2025-02-24 16:06:07 +03:00
parent d705d327cc
commit 9b91325160
Signed by: dstepanov-yadro
GPG key ID: 237AF1A763293BC0

View file

@ -445,6 +445,10 @@ func (s *Shard) Reload(ctx context.Context, opts ...Option) error {
return err
}
}
if c.opsLimiter != nil {
s.opsLimiter.Close()
s.opsLimiter = c.opsLimiter
}
return s.setMode(ctx, c.info.Mode)
}