hc-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "kumaran (JIRA)" <j...@apache.org>
Subject [jira] [Updated] (HTTPCLIENT-1838) HttpClient leaves connection in CLOSE_WAIT in a multithreaded environment
Date Fri, 07 Apr 2017 15:15:41 GMT

     [ https://issues.apache.org/jira/browse/HTTPCLIENT-1838?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

kumaran updated HTTPCLIENT-1838:
--------------------------------

Hi Oleg,

Thanks for your reply.

Due to this leak, our product is getting out of connections and need of restarting the product.
Can you please let us know whether is it a known issue with Apache HttpClient, if so, is there
any timeline to fix it?

Also I have attached our code, correct us if we implemented it wrong anyway which leaks the
connection.

Regards,
Kumaran.A.E

On 4/7/17, 8:02 AM, "Oleg Kalnichevski (JIRA)" <jira@apache.org> wrote:

    
        [ https://issues.apache.org/jira/browse/HTTPCLIENT-1838?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15960924#comment-15960924
] 
    
    Oleg Kalnichevski commented on HTTPCLIENT-1838:
    -----------------------------------------------
    
    I am sorry but what is it exactly are we expected to do about this issue?
    
    Oleg
    
    > HttpClient leaves connection in CLOSE_WAIT in a multithreaded environment
    > -------------------------------------------------------------------------
    >
    >                 Key: HTTPCLIENT-1838
    >                 URL: https://issues.apache.org/jira/browse/HTTPCLIENT-1838
    >             Project: HttpComponents HttpClient
    >          Issue Type: Bug
    >          Components: HttpClient (classic)
    >    Affects Versions: 4.5.3
    >         Environment: Centos6.3. Apache HttpClient 4.5.3. 
    >            Reporter: kumaran
    >             Fix For: 4.5.4
    >
    >         Attachments: CvHttpClientImpl.txt
    >
    >
    > We use HttpClient for all our internal http communications and below the code snippet,
    > val client: CloseableHttpClient = HttpClients.custom()
    > 			.setConnectionManager(clientConnectionManager)
    > 			.setRetryHandler(httpRequestRetryHandler)
    > 			.setDefaultCredentialsProvider(basicCredentialsProvider)
    > 			.evictExpiredConnections()
    > 			.evictIdleConnections(5, TimeUnit.SECONDS)
    > 		  .build()
    > Sometimes we could see a connection is created but not used and left in CLOSE_WAIT
state. we couldnt able to find the exact flow, since it happens randomly. 
    
    
    
    --
    This message was sent by Atlassian JIRA
    (v6.3.15#6346)
    



> HttpClient leaves connection in CLOSE_WAIT in a multithreaded environment
> -------------------------------------------------------------------------
>
>                 Key: HTTPCLIENT-1838
>                 URL: https://issues.apache.org/jira/browse/HTTPCLIENT-1838
>             Project: HttpComponents HttpClient
>          Issue Type: Bug
>          Components: HttpClient (classic)
>    Affects Versions: 4.5.3
>         Environment: Centos6.3. Apache HttpClient 4.5.3. 
>            Reporter: kumaran
>             Fix For: 4.5.4
>
>         Attachments: CvHttpClientImpl.txt
>
>
> We use HttpClient for all our internal http communications and below the code snippet,
> val client: CloseableHttpClient = HttpClients.custom()
> 			.setConnectionManager(clientConnectionManager)
> 			.setRetryHandler(httpRequestRetryHandler)
> 			.setDefaultCredentialsProvider(basicCredentialsProvider)
> 			.evictExpiredConnections()
> 			.evictIdleConnections(5, TimeUnit.SECONDS)
> 		  .build()
> Sometimes we could see a connection is created but not used and left in CLOSE_WAIT state.
we couldnt able to find the exact flow, since it happens randomly. 



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@hc.apache.org
For additional commands, e-mail: dev-help@hc.apache.org


Mime
View raw message