Dmitrii Stepanov
d3b209c8e1
All checks were successful
Vulncheck / Vulncheck (pull_request) Successful in 1m3s
DCO action / DCO (pull_request) Successful in 1m28s
Pre-commit hooks / Pre-commit (pull_request) Successful in 2m2s
Build / Build Components (pull_request) Successful in 2m15s
Tests and linters / Run gofumpt (pull_request) Successful in 2m10s
Tests and linters / gopls check (pull_request) Successful in 2m21s
Tests and linters / Staticcheck (pull_request) Successful in 2m55s
Tests and linters / Lint (pull_request) Successful in 3m29s
Tests and linters / Tests (pull_request) Successful in 3m47s
Tests and linters / Tests with -race (pull_request) Successful in 3m58s
Since `frostfs-cli control shards rebuild` command was added, there is no need for background rebuild now. For failover tests used used value 1 to rebuild only schema change. Signed-off-by: Dmitrii Stepanov <d.stepanov@yadro.com>
27 lines
505 B
Go
27 lines
505 B
Go
package common
|
|
|
|
import (
|
|
"context"
|
|
|
|
oid "git.frostfs.info/TrueCloudLab/frostfs-sdk-go/object/id"
|
|
)
|
|
|
|
type RebuildRes struct {
|
|
ObjectsMoved uint64
|
|
FilesRemoved uint64
|
|
}
|
|
|
|
type RebuildPrm struct {
|
|
MetaStorage MetaStorage
|
|
WorkerLimiter ConcurrentWorkersLimiter
|
|
FillPercent int
|
|
}
|
|
|
|
type MetaStorage interface {
|
|
UpdateStorageID(ctx context.Context, addr oid.Address, storageID []byte) error
|
|
}
|
|
|
|
type ConcurrentWorkersLimiter interface {
|
|
AcquireWorkSlot(ctx context.Context) error
|
|
ReleaseWorkSlot()
|
|
}
|