[#1448] container/ape: Ignore an error when getting a role
All checks were successful
Tests and linters / Run gofumpt (pull_request) Successful in 1m26s
DCO action / DCO (pull_request) Successful in 1m39s
Vulncheck / Vulncheck (pull_request) Successful in 2m9s
Pre-commit hooks / Pre-commit (pull_request) Successful in 2m22s
Build / Build Components (pull_request) Successful in 2m28s
Tests and linters / gopls check (pull_request) Successful in 2m54s
Tests and linters / Staticcheck (pull_request) Successful in 2m56s
Tests and linters / Lint (pull_request) Successful in 4m12s
Tests and linters / Tests (pull_request) Successful in 4m44s
Tests and linters / Tests with -race (pull_request) Successful in 6m5s
All checks were successful
Tests and linters / Run gofumpt (pull_request) Successful in 1m26s
DCO action / DCO (pull_request) Successful in 1m39s
Vulncheck / Vulncheck (pull_request) Successful in 2m9s
Pre-commit hooks / Pre-commit (pull_request) Successful in 2m22s
Build / Build Components (pull_request) Successful in 2m28s
Tests and linters / gopls check (pull_request) Successful in 2m54s
Tests and linters / Staticcheck (pull_request) Successful in 2m56s
Tests and linters / Lint (pull_request) Successful in 4m12s
Tests and linters / Tests (pull_request) Successful in 4m44s
Tests and linters / Tests with -race (pull_request) Successful in 6m5s
When getting a role in the APE checker for the container services, an error may be returned if network maps of the previous two epochs don't have enough nodes to fulfil a container placement policy. It's a logical error, so we should ignore it. Signed-off-by: Aleksey Savchuk <a.savchuk@yadro.com>
This commit is contained in:
parent
e70c2cedbe
commit
6daa1fda7f
1 changed files with 3 additions and 4 deletions
|
@ -550,10 +550,9 @@ func (ac *apeChecker) isContainerKey(pk []byte, cnrID cid.ID, cont *containercor
|
|||
}
|
||||
|
||||
func isContainerNode(nm *netmapSDK.NetMap, pk, binCnrID []byte, cont *containercore.Container) bool {
|
||||
// An error may be returned if network maps of the previous two epochs
|
||||
// don't have enough nodes to fulfil a container placement policy.
|
||||
// It's a logical error, so we should ignore it.
|
||||
// See https://git.frostfs.info/TrueCloudLab/frostfs-node/issues/1448.
|
||||
// It could an error only if the network map doesn't have enough nodes to
|
||||
// fulfil the policy. It's a logical error that doesn't affect an actor role
|
||||
// determining, so we ignore it
|
||||
cnrVectors, _ := nm.ContainerNodes(cont.Value.PlacementPolicy(), binCnrID)
|
||||
|
||||
for i := range cnrVectors {
|
||||
|
|
Loading…
Reference in a new issue