change server ping period to be less frequent

no need to ping ws every 10 sec
This commit is contained in:
Anton Kaliaev
2017-08-08 13:21:59 -04:00
parent 23a87304cc
commit 6c85e4be4f
2 changed files with 1 additions and 4 deletions

View File

@ -340,7 +340,7 @@ const (
writeChanCapacity = 1000
wsWriteWait = 30 * time.Second // each write times out after this.
defaultWSPongWait = 30 * time.Second
defaultWSPingPeriod = 10 * time.Second
defaultWSPingPeriod = (defaultWSPongWait * 9) / 10
)
// a single websocket connection