This commit is contained in:
crusader
2018-07-01 02:43:56 +09:00
parent 8a0bee1589
commit 56914142e9
5 changed files with 24 additions and 27 deletions

View File

@@ -1,6 +1,7 @@
package server
import (
crc "git.loafle.net/commons/rpc-go/codec"
crpj "git.loafle.net/commons/rpc-go/protocol/json"
cssw "git.loafle.net/commons/server-go/socket/web"
"git.loafle.net/overflow/probe_gateway_rpc/config"
@@ -8,7 +9,7 @@ import (
)
func New(_config *config.Config) *cssw.Server {
rpcServerCodec := crpj.NewServerCodec()
rpcServerCodec := crpj.NewCustomServerCodec(crc.NewCompressionCodecSelector(_config.ServerHandler.GetCompressionThreshold()))
as := &servlet.AuthServlets{}
as.RPCServerCodec = rpcServerCodec