You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@hc.apache.org by "Oleg Kalnichevski (Jira)" <ji...@apache.org> on 2023/08/31 09:31:00 UTC

[jira] [Comment Edited] (HTTPCLIENT-2291) RetryStrategy: AsyncExecChainHandler and ExecChainHandler behavior should be identical

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

Oleg Kalnichevski edited comment on HTTPCLIENT-2291 at 8/31/23 9:30 AM:
------------------------------------------------------------------------

[~cachescrubber] We are not working for a Fortune 500 shop. Just a PR would suffice.

Oleg


was (Author: olegk):
[~cachescrubber] We are not working a Fortune 500 shop. Just a PR would suffice.

Oleg

> RetryStrategy: AsyncExecChainHandler and ExecChainHandler behavior should be identical
> --------------------------------------------------------------------------------------
>
>                 Key: HTTPCLIENT-2291
>                 URL: https://issues.apache.org/jira/browse/HTTPCLIENT-2291
>             Project: HttpComponents HttpClient
>          Issue Type: Bug
>          Components: HttpClient (async), HttpClient (classic)
>    Affects Versions: 5.2
>            Reporter: Lars Uffmann
>            Priority: Major
>             Fix For: 5.3-alpha2
>
>
> A RetryStrategy is enabled by default in both classic and async.
>  
> If an exec chain handler is placed *after* the retry handler, the behavior between async and classic is consistent. The behavior of an Async- and  a classic ExecChainHandler placed *before* the (Async)HttpRequestRetryExec is different when a retry is actually executed.
>  
> In case of a retry, the classic HttpRequestRetryExec will split the exec chain and proceed with all handlers configured after itself. Any handler registered before would be called exactly one time with the final outcome of the last retry attempt.
>  
> The Async version, however, will call any handler registered before itself with every retry. The order of events is counter intuitive as well. All closing events will be emitted after the last attempt.
>  
> {*}Workaround{*}: In async, ignore all but the first invocation of a handler when the handler is placed before the retry handler.
>  
> {*}Expected Bahaviour{*}: Both Async and Classic ExecChainHandler behavior should be identical.



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

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