forked from TrueCloudLab/frostfs-api-go
[#312] netmap: Support multiple addresses in NodeInfo
In latest NeoFS API changes `NodeInfo` message carries list of network addresses. There is a need Add `SetAddresses` / `IterateAddresses` / `NumberOfAddresses` methods to provide the access to node's address group. Mark `Address` / `SetAddress` methods as deprecated. Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
This commit is contained in:
parent
6d531a07a5
commit
07fcaa4ba5
9 changed files with 159 additions and 70 deletions
|
@ -84,7 +84,7 @@ func NodeAttribute() *netmap.NodeAttribute {
|
|||
func NodeInfo() *netmap.NodeInfo {
|
||||
x := netmap.NewNodeInfo()
|
||||
|
||||
x.SetAddress("address")
|
||||
x.SetAddresses("address 1", "address 2")
|
||||
x.SetPublicKey([]byte("public key"))
|
||||
x.SetState(netmap.NodeStateOnline)
|
||||
x.SetAttributes(NodeAttribute(), NodeAttribute())
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue