[
https://issues.apache.org/jira/browse/HTTPCLIENT-2094?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17156023#comment-17156023
]
ASF subversion and git services commented on HTTPCLIENT-2094:
-------------------------------------------------------------
Commit 517e5c8d94cf7e5bb9863d21ea89d284c46b7d38 in httpcomponents-client's
branch refs/heads/5.1.x from Carter Kozak
[ https://gitbox.apache.org/repos/asf?p=httpcomponents-client.git;h=517e5c8 ]
HTTPCLIENT-2094: ConnectionManager validateAfterInactivity zero duration
agreement
Both connection managers agree on the meaning of a zero-duration
validateAfterInactivity value. Previously the documentation for
both suggested that zero resulted in no validation, however
the classic client would validate prior to each request and
the async client would never validate.
This commit standardizes behavior on the classic client, which
is consistent with hc4.x, allowing zero to force validation prior
to every request.
> setValidateAfterInactivity disagreement between classic/async for duration
> zero
> -------------------------------------------------------------------------------
>
> Key: HTTPCLIENT-2094
> URL: https://issues.apache.org/jira/browse/HTTPCLIENT-2094
> Project: HttpComponents HttpClient
> Issue Type: Bug
> Components: Documentation, HttpClient (async), HttpClient (classic)
> Affects Versions: 5.0.1
> Reporter: Carter Kozak
> Priority: Major
> Fix For: 5.0.2
>
> Time Spent: 0.5h
> Remaining Estimate: 0h
>
> Pooling(Async|Http)ClientCOnnectionManager.setValidateAfterInactivity
> documentation says that non-positive values result in no validation.
> This is true of the asynchronous implementation, however the classic
> implementation only uses negative values to disable validation where zero
> results in validation prior to each request.
> Ideally the semantics would match between the two connection managers. My
> preference would be to update the documentation in both and the
> implementation of the asynchronous manager so that zero always validates
> connections for behavior similar to okhttp (while certainly not a good idea
> in most cases, has benefits in environments with poor connectivity). This
> approach would also match behavior of 4.x.
> Thoughts?
--
This message was sent by Atlassian Jira
(v8.3.4#803005)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]