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

Add "Retry-After" header #929

Merged
merged 5 commits into from
Oct 10, 2018
Merged

Add "Retry-After" header #929

merged 5 commits into from
Oct 10, 2018

Conversation

davidor
Copy link
Contributor

@davidor davidor commented Oct 10, 2018

Part of #335

This PR introduces a "Retry-After" header in the APIcast response.
When rate-limited by the 3scale backend, APIcast returns the number of seconds that the caller needs to wait before it's authorized again in the "Retry-After" header.

@davidor davidor requested a review from a team as a code owner October 10, 2018 13:36
Copy link
Contributor

@mikz mikz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

👍

@davidor davidor changed the title [WIP] Add "Retry-After" header Add "Retry-After" header Oct 10, 2018
@davidor davidor merged commit 9787ef4 into master Oct 10, 2018
@davidor davidor deleted the retry-after-header branch October 10, 2018 15:52
-- body has many information like metrics, limits, etc. This information is
-- parsed only when using oauth. By enabling this option will save some work
-- to the 3scale backend and reduce network traffic.
-- - limit_headers: when enabled and the request is rate-limited, backend
-- returns the number of seconds remaining until the limit expires. It
-- returns -1 when there are no limits. With this header, backend returns
Copy link

@ioggstream ioggstream Jan 24, 2019

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@davidor https://tools.ietf.org/html/rfc7231#section-7.1.3

A delay-seconds value is a non-negative decimal integer, representing time in seconds.

In extensions.md I'd add a notice on that difference with the specs.

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.

3 participants