[#422] pkg/services: Cache clients by address only
Signed-off-by: Evgenii Stratonikov <evgeniy@nspcc.ru>
This commit is contained in:
parent
55dec28bbb
commit
cc7287d6f7
19 changed files with 55 additions and 68 deletions
|
@ -2,7 +2,6 @@ package getsvc
|
|||
|
||||
import (
|
||||
"context"
|
||||
"crypto/ecdsa"
|
||||
"crypto/rand"
|
||||
"crypto/sha256"
|
||||
"fmt"
|
||||
|
@ -81,7 +80,7 @@ func (p *testPlacementBuilder) BuildPlacement(addr *objectSDK.Address, _ *netmap
|
|||
return vs, nil
|
||||
}
|
||||
|
||||
func (c *testClientCache) get(_ *ecdsa.PrivateKey, addr string) (getClient, error) {
|
||||
func (c *testClientCache) get(addr string) (getClient, error) {
|
||||
v, ok := c.clients[addr]
|
||||
if !ok {
|
||||
return nil, errors.New("could not construct client")
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue