[#1031] morph: Add maxConnPerHost
option
Signed-off-by: Pavel Karpy <carpawell@nspcc.ru>
This commit is contained in:
parent
63e035bd8a
commit
c49e53ba9d
3 changed files with 18 additions and 3 deletions
|
@ -25,7 +25,8 @@ type multiClient struct {
|
|||
// note: must be wrapped into mutex lock.
|
||||
func (x *multiClient) createForAddress(addr string) (*Client, error) {
|
||||
cli, err := client.New(x.cfg.ctx, addr, client.Options{
|
||||
DialTimeout: x.cfg.dialTimeout,
|
||||
DialTimeout: x.cfg.dialTimeout,
|
||||
MaxConnsPerHost: x.cfg.maxConnPerHost,
|
||||
})
|
||||
if err != nil {
|
||||
return nil, err
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue