frostfs-node/pkg/innerring/processors/netmap/nodevalidation
Leonard Lyubich f64ae55806 [#1681] ir/netmap: Require MAINTENANCE mode to be allowed by network
There is a need to prevent limitless abuse of MAINTENANCE status of the
storage nodes. To do this, configuration of the NeoFS network is going
to be extended with the flag which allows the state. Until this is done,
it makes sense to prepare a site for this in the code.

Define `state.NetworkSettings` interface as an abstraction of global
network configuration within the `state` package. Make
`NetMapCandidateValidator` to depend on `NetworkSettings` and provide
corresponding field setter. Change `VerifyAndUpdate` method's behavior
to return an error for candidates with MAINTENANCE state if this state
is disallowed by the network configuration. Provide `NetworkSettings`
from the wrapper over Netmap contract's client on Inner Ring application
side. The provider is implemented to statically disallow MAINTENANCE
mode in order to save previous behavior.

Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
Signed-off-by: Leonard Lyubich <ctulhurider@gmail.com>
2022-10-05 11:41:49 +03:00
..
locode [#1687] *: Perform go fmt using go v1.19 2022-08-22 18:59:57 +03:00
maddress [#1513] Upgrade NeoFS SDK Go with changed netmap package 2022-06-17 15:53:18 +03:00
state [#1681] ir/netmap: Require MAINTENANCE mode to be allowed by network 2022-10-05 11:41:49 +03:00
subnet [#1518] Upgrade NeoFS SDK Go with changed subnet package 2022-06-15 17:02:49 +03:00
validator.go *: replace neofs-api-go with neofs-sdk-go 2021-11-12 17:29:09 +03:00