-
Notifications
You must be signed in to change notification settings - Fork 25
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
feat: KV Connect protocol spec #6
Conversation
The server MAY perform quota checks on the request. If the request is rejected | ||
due to quota limits, the server MUST respond with a 4xx class response and a | ||
plain text body containing a human readable error message. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How about rate limiting?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I have added a note to the paragraph above about using 5xx responses for rate limiting, as those are retried with backoff.
exponential backoff strategy with unlimited retries. | ||
|
||
The client MUST verify that the response is a 200 OK response. If the response | ||
is a 4xx class error response, the client MUST fatally abort the request and |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Similar comment to above about rate limiting. Should the server be able to respond with 429? and should the client interpret that as retry with backoff?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think the server should respond with a 503 then. It's easier if 4xx == never retry, and 5xx == retry with backoff.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think there should be a mechanism to "gracefully" rate limit, like starting to throttle at 90% of the limit and when it reaches 100% wait until the end of the rate limit window
This commit adds a proper spec for the KV Connect protocol.