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

Alexey Sviridov edited comment on THRIFT-1523 at 2/27/12 2:57 AM:
------------------------------------------------------------------

I'm have a simple patch, but dunno how to attach it here...
so i'm post it right here
{noformat}
== begin of file clientTimeout.patch ===============
--- TSSLTransportFactory-orig.java      2011-11-06 16:40:42.000000000 +0700
+++ TSSLTransportFactory-patched.java   2012-02-25 22:54:12.000000000 +0700
@@ -112,7 +112,7 @@
       if (params != null && params.cipherSuites != null) {
         serverSocket.setEnabledCipherSuites(params.cipherSuites);
       }
-      return new TServerSocket(serverSocket);
+      return new TServerSocket(serverSocket,timeout);
     } catch (Exception e) {
       throw new TTransportException("Could not bind to port " + port, e);
     }

== end of file clientTimeout.patch ===============
{noformat} 
Please, correct me if i'm wrong 
                
      was (Author: sviridov_alexey):
    I'm have a simple patch, but dunno how to attach it here...
so i'm post it right here
{noformat}
== begin of file clientTimeout.patch ===============
115c115
<       return new TServerSocket(serverSocket);
---
>       return new TServerSocket(serverSocket,timeout);
== end of file clientTimeout.patch ===============
{noformat} 
Please, correct me if i'm wrong 
                  
> clientTimeout not worked as expected in TServerSocket created by 
> TSSLTransportFactory
> -------------------------------------------------------------------------------------
>
>                 Key: THRIFT-1523
>                 URL: https://issues.apache.org/jira/browse/THRIFT-1523
>             Project: Thrift
>          Issue Type: Bug
>          Components: Java - Library
>    Affects Versions: 0.6.1, 0.7, 0.8, 0.9
>            Reporter: Alexey Sviridov
>            Priority: Blocker
>
> TSSLTransportFactory has method 
>    public static TServerSocket getServerSocket(int port, int clientTimeout) 
> there is parameter clientTimeout that need to close idle client connections 
> (after clientTimeout amount of millis of client inactivity server closes 
> opened connection themself, not waiting while client called close() method). 
> This parameter work fine when create TServerSocket through new, but not 
> working at all when creating TServerSocket through 
> TSSLTransportFactory.getServerSocket

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to