Skip to content
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

Retry auths when using the "resty" http ng backend #961

Merged
merged 3 commits into from
Nov 28, 2018

Conversation

davidor
Copy link
Contributor

@davidor davidor commented Nov 23, 2018

This PR implements a change in the backend client module to retry authorizations when backend closes the connection and the client uses the resty implementation.

While testing the 3scale batcher policy, I got very sporadic errors because the authorization call to the 3scale backend failed. In those cases, APIcast was sending an auth request after backend closed the keep-alive connection because of a timeout. In those cases, when using the "resty" backend of the http client, the response has status = 0 and error = "closed". Authorizes are idempotent, so they can be retried safely in those cases.

@davidor davidor requested a review from a team as a code owner November 23, 2018 14:15
@davidor davidor requested a review from mikz November 23, 2018 14:25
@davidor davidor force-pushed the retry-auths-when-error-closed branch from 6de17cb to 46e1048 Compare November 28, 2018 15:00
@davidor
Copy link
Contributor Author

davidor commented Nov 28, 2018

Rebased and fixed the changelog conflict.

@davidor davidor merged commit a350650 into master Nov 28, 2018
@davidor davidor deleted the retry-auths-when-error-closed branch November 28, 2018 15:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants