From 1c044280d6cee759383f6db79bcac46cf8650bd8 Mon Sep 17 00:00:00 2001 From: Chris Lu Date: Sun, 16 Mar 2014 13:49:49 -0700 Subject: [PATCH] reusing http connections in raft server --- go/weed/weed_server/raft_server.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/go/weed/weed_server/raft_server.go b/go/weed/weed_server/raft_server.go index 882bb23f9..15ec99726 100644 --- a/go/weed/weed_server/raft_server.go +++ b/go/weed/weed_server/raft_server.go @@ -44,6 +44,8 @@ func NewRaftServer(r *mux.Router, version string, peers []string, httpAddr strin var err error transporter := raft.NewHTTPTransporter("/cluster") + transporter.Transport.MaxIdleConnsPerHost = 1024 + s.raftServer, err = raft.NewServer(s.httpAddr, s.dataDir, transporter, nil, topo, "") if err != nil { glog.V(0).Infoln(err)