Skip to content

BodyDefferingAsyncHandler should not retry #1555

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
jogoussard opened this issue Jul 3, 2018 · 8 comments
Closed

BodyDefferingAsyncHandler should not retry #1555

jogoussard opened this issue Jul 3, 2018 · 8 comments

Comments

@jogoussard
Copy link
Contributor

Hi
I found out that the BodyDefferingAsyncHandler does not play well with the default retries on GET.
If the connection is closed after the caller thread has started consuming the body, the default behavior of the client is to retry the request, pouring the new body into the same output stream as the first request.
Unless I'm mistaken BodyDefferingAsyncHandler should overwrite 'onRetry' and throw an exception there, unless there's a cleaner way to do this.
The current workaround is to configure the client with 0 retries, but as it is global, that's not a good solution.

@slandelle
Copy link
Contributor

Contribution would be greatly appreciated.

@jogoussard
Copy link
Contributor Author

I would but I cannot push the branch it seems.

git push origin fixes/issue_30
remote: Permission to AsyncHttpClient/async-http-client.git denied to jogoussard.
fatal: unable to access 'https://github.com/AsyncHttpClient/async-http-client.git/': The requested URL returned error: 403

@slandelle
Copy link
Contributor

Of course you can't push on this repository!
You need to fork it and then open a pull request.

@jogoussard
Copy link
Contributor Author

Fork a complete repo under my account and then push a PR on this fork? Then you grab the changes? Sounds quite overkill to me - here's a patch.
issue_30.patch.zip

@slandelle
Copy link
Contributor

Please understand that pull requests are the more convenient for people who maintain open source projects (and who are usually swamped and do OSS on their free time):

  • easier to review and provide feedback/request for changes
  • easier to merge

So please go with the standard process.

@jogoussard
Copy link
Contributor Author

#1560

@slandelle
Copy link
Contributor

Great, thanks!

@slandelle slandelle added this to the 2.5.1 milestone Jul 11, 2018
@slandelle
Copy link
Contributor

Closed by #1560

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants