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

ASF subversion and git services commented on HTTPCORE-613:
----------------------------------------------------------

Commit 2b3c7c388fdb8b74ca296920c78365ce52ec4925 in httpcomponents-core's branch 
refs/heads/master from Peter Frank
[ https://gitbox.apache.org/repos/asf?p=httpcomponents-core.git;h=2b3c7c3 ]

HTTPCORE-613_2: Now allowing 0 for validaterAfterInactivity (#160)

HTTPCORE-613: Now allowing 0 for validaterAfterInactivity

> Add staleConnectionCheckEnabled=true semantic behavior in 
> validateAfterInactivity config
> ----------------------------------------------------------------------------------------
>
>                 Key: HTTPCORE-613
>                 URL: https://issues.apache.org/jira/browse/HTTPCORE-613
>             Project: HttpComponents HttpCore
>          Issue Type: Improvement
>          Components: HttpCore
>    Affects Versions: 4.4.12
>            Reporter: Peter Frank
>            Priority: Major
>          Time Spent: 40m
>  Remaining Estimate: 0h
>
> Between HttpClient 4.4.x and 4.5.x setStaleConnectionCheckEnabled was 
> deprecated in favor of setValidateAfterInactivity.  That's all fine, however, 
> the implementation of setValidateAfterInactivity has no ability to check if a 
> connection is stale all the time.  The closest one can get is 1 ms, and 
> that's unfortunately not short enough in a test environment scenario when a 
> test Http Server is being restarted between Tests to clear out state.
> This is a common issue on the internet for people that use something like 
> Wiremock, the irony is troubleshooting the situation makes it go away (cause 
> logging slows the tests).
> I would suggest making 0 a special value to "turn on" validation all the time.
> With HttpClient 5 removing the old staleConnectionCheckEnabled completely 
> with a piece of what that feature actually did also being removed I fear it 
> will leave me, and perhaps others, in a bit of a lurch.  Thanks!



--
This message was sent by Atlassian Jira
(v8.3.4#803005)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to