forked from TrueCloudLab/frostfs-node
[#607] object/put: Make client constructor to work with group address
Make Object Put service to work with `AddressGroup` instead of `Address` in order to support multiple addresses of the storage node. Signed-off-by: Leonard Lyubich <leonard@nspcc.ru>
This commit is contained in:
parent
6e5d7f84af
commit
8972f84672
8 changed files with 89 additions and 49 deletions
|
@ -20,7 +20,7 @@ type remoteTarget struct {
|
|||
|
||||
commonPrm *util.CommonPrm
|
||||
|
||||
addr network.Address
|
||||
addr network.AddressGroup
|
||||
|
||||
obj *object.Object
|
||||
|
||||
|
@ -37,7 +37,7 @@ type RemoteSender struct {
|
|||
|
||||
// RemotePutPrm groups remote put operation parameters.
|
||||
type RemotePutPrm struct {
|
||||
node network.Address
|
||||
node network.AddressGroup
|
||||
|
||||
obj *object.Object
|
||||
}
|
||||
|
@ -86,7 +86,7 @@ func NewRemoteSender(keyStorage *util.KeyStorage, cons ClientConstructor) *Remot
|
|||
}
|
||||
|
||||
// WithNodeAddress sets network address of the remote node.
|
||||
func (p *RemotePutPrm) WithNodeAddress(v network.Address) *RemotePutPrm {
|
||||
func (p *RemotePutPrm) WithNodeAddress(v network.AddressGroup) *RemotePutPrm {
|
||||
if p != nil {
|
||||
p.node = v
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue