8000 正确的关闭client Socket · Issue #189 · vipshop/vjtools · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content
正确的关闭client Socket #189
Open
@firebook

Description

@firebook

期待加个类,正确的关闭client Socket

直接调用java.net.Socket#close(),会导致服务端报:java.net.SocketException: Connection reset

原因是close会先发FIN,再发RST,客户端没有等待服务端的FIN

相关链接:https://docs.oracle.com/javase/8/docs/technotes/guides/net/articles/connection_release.html

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0