[ 
https://issues.apache.org/jira/browse/THRIFT-3789?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15246409#comment-15246409
 ] 

ASF GitHub Bot commented on THRIFT-3789:
----------------------------------------

GitHub user jamesreggio opened a pull request:

    https://github.com/apache/thrift/pull/989

    THRIFT-3789 Add `destroy` to Connection instance

    This commit proxies the `destroy` method from the Thrift Connection object 
to its underlying socket, akin to the existing `end` method.
    
    Without `destroy`, it's possible for a failed TLS socket to hold the 
Node.js process open. (Calling `end` is not sufficient to close the OS handle 
because `end` sends a `FIN` packet, which is never acknowledged by the server.)

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/jamesreggio/thrift THRIFT-3789

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/thrift/pull/989.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #989
    
----
commit b2907fd207736ec95f37919528f6dc6990f007c8
Author: James Reggio <james.reg...@gmail.com>
Date:   2016-04-18T19:49:50Z

    THRIFT-3789 Add `destroy` to Connection instance
    
    This commit proxies the `destroy` method from the Thrift Connection
    object to its underlying socket, akin to the existing `end` method.
    
    Without `destroy`, it's possible for a failed TLS socket to hold the
    Node.js process open. (Calling `end` is not sufficient to close the OS
    handle because `end` sends a FIN packet, which is never acknowledged by
    the server.)

----


> Node.js lacks ability to destroy connection
> -------------------------------------------
>
>                 Key: THRIFT-3789
>                 URL: https://issues.apache.org/jira/browse/THRIFT-3789
>             Project: Thrift
>          Issue Type: Bug
>          Components: Node.js - Library
>            Reporter: James Reggio
>            Priority: Trivial
>
> At present, there is no means for destroying the socket underlying a Node.js 
> Thrift Connection. When using TLS, If the socket fails to connect, calling 
> end() is insufficient to release its resources. (end() sends a FIN packet, 
> which is never acknowledged, holding the socket open.) This unreleased socket 
> will prevent Node.js from exiting cleanly.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to