all: new feature connection pool

This commit is contained in:
fatedier
2016-07-29 23:08:00 +08:00
parent fd6b94908b
commit 8f5f0b0a9a
11 changed files with 170 additions and 35 deletions

View File

@@ -276,6 +276,13 @@ func doLogin(req *msg.ControlReq, c *conn.Conn) (ret int64, info string) {
// set infomations from frpc
s.UseEncryption = req.UseEncryption
s.UseGzip = req.UseGzip
if req.PoolCount > server.MaxPoolCount {
s.PoolCount = server.MaxPoolCount
} else if req.PoolCount < 0 {
s.PoolCount = 0
} else {
s.PoolCount = req.PoolCount
}
// start proxy and listen for user connections, no block
err := s.Start(c)