forked from TrueCloudLab/frostfs-node
[#1680] node/netmap: Support MaintenanceModeAllowed
config in RPC
After recent changes network configuration stored in the Netmap contract of the NeoFS Sidechain contains `MaintenanceModeAllowed` flag. There is a need to support this value in Storage node application. Make `NetmapService.NetworkInfo` RPC server of the storage node to set `MaintenanceModeAllowed` flag according to corresponding value in the Sidechain. Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
This commit is contained in:
parent
0826310b2a
commit
7a3a827d35
1 changed files with 4 additions and 0 deletions
|
@ -404,6 +404,10 @@ func (n *netInfo) Dump(ver version.Version) (*netmapSDK.NetworkInfo, error) {
|
|||
ni.DisableHomomorphicHashing()
|
||||
}
|
||||
|
||||
if netInfoMorph.MaintenanceModeAllowed {
|
||||
ni.AllowMaintenanceMode()
|
||||
}
|
||||
|
||||
for i := range netInfoMorph.Raw {
|
||||
ni.SetRawNetworkParameter(netInfoMorph.Raw[i].Name, netInfoMorph.Raw[i].Value)
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue