• 博客园logo
  • 会员
  • 众包
  • 新闻
  • 博问
  • 闪存
  • 赞助商
  • HarmonyOS
  • Chat2DB
    • 搜索
      所有博客
    • 搜索
      当前博客
  • 写随笔 我的博客 短消息 简洁模式
    用户头像
    我的博客 我的园子 账号设置 会员中心 简洁模式 ... 退出登录
    注册 登录
云飞
博客园    首页    新随笔    联系   管理    订阅  订阅

Play Framework WebSocket 问题

  今天遇到非常不理解问题,WebSocket 发送消息,不成功,分析之后,发现WebSocket 的消息体的大小限制,可以修改Play的配置来修改该配制

WebSocket 消息大小限制:

play.websocket.buffer.limit

与此相同的还有:

HTTP 解析最大内存限制:

play.http.parser.maxMemoryBuffer

HTTP 磁盘文件最大限制:

play.http.parser.maxDiskBuffer

附加Akka 配额:

netty.tcp {
hostname = "127.0.0.1"
port = 2552

# Sets the send buffer size of the Sockets,
# set to 0b for platform default
send-buffer-size = 32768k

# Sets the receive buffer size of the Sockets,
# set to 0b for platform default
receive-buffer-size = 32768k

# Maximum message size the transport will accept, but at least
# 32000 bytes.
# Please note that UDP does not support arbitrary large datagrams,
# so this setting has to be chosen carefully when using UDP.
# Both send-buffer-size and receive-buffer-size settings has to
# be adjusted to be able to buffer messages of maximum size.
maximum-frame-size = 16384k
}

 

 

Connection reset by peer的常见原因 :  http://blog.sina.com.cn/s/blog_43eb83b90102dseg.html

posted @ 2017-04-01 16:58  映日荷花别样红  阅读(694)  评论(0)    收藏  举报
刷新页面返回顶部
博客园  ©  2004-2025
浙公网安备 33010602011771号 浙ICP备2021040463号-3