-
Notifications
You must be signed in to change notification settings - Fork 325
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
Set v7 protocol as current version in docs #272
Conversation
… other implementations to this doc
…e was generated by an older version of the generator
draft_release_notes.md
Outdated
@@ -0,0 +1,15 @@ | |||
A major release that includes a protocol spec update. The jump from v5 to v7 is to avoid confusion with issues and comments that were targeting v6 and were never released (see [achieved protocol spec v6](https://twitchtv.github.io/twirp/docs/spec_v6.html)). |
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.
achieved => archived?
draft_release_notes.md
Outdated
|
||
Changes in the Protocol spec v7: | ||
|
||
* Twirp routes can have any prefix: `<prefix>/<package>.<Service>/<Method>` section. In v5 the prefix was mandatory was always `/twirp`. |
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.
was mandatory was always => was mandatory, always
draft_release_notes.md
Outdated
|
||
* #264 Optional Twirp Prefix. Implements the proposal #263 with the optional prefix, using an option to specify a different prefix than the default value "/twirp". The default value ensures backwards compatibility when updating the service. Using different prefixes, it is now possible to mount the same Twirp service in multiple routes, which may help migrating existing services from the "/twirp" prefix to a new one. | ||
* #264 also introduces [server options on the server constructor](https://github.com/twitchtv/twirp/pull/264#issuecomment-686170407). Adding server hooks should now done through a server option. The server options are available in the new version of the `twirp` package, servers generated with the new version require the `twirp` package to be updated as well. | ||
* #270 ResourceExhausted error code to HTTP 429 status code. To implement the new spec for this error, so it is clear that this error code can be used for rate limiting. This change may affect middleware if it depends on a specific status code being used. |
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.
To implement the new spec for this error, so it is clear that this error code can be used for rate limiting.
This sentence doesn't quite make sense.
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.
😄 what was I thinking? Updated. Thanks!
PROTOCOL.md
Outdated
| already_exists | 409 | An attempt to create an entity failed because one already exists. | ||
| permission_denied | 403 | The caller does not have permission to execute the specified operation. It must not be used if the caller cannot be identified (use "unauthenticated" instead). | ||
| unauthenticated | 401 | The request does not have valid authentication credentials for the operation. | ||
| resource_exhausted | 403 | Some resource has been exhausted, perhaps a per-user quota, or perhaps the entire file system is out of space. |
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.
Does this need to be updated to 429?
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.
Yes, this entire file should be a copy-paste form the spec in the docs. Which I though I did already 🤔 good catch. I wonder if this should just contain a link to the docs ... but realistically it almost never changes, so it's fine to have some duplication 🤷
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.
oh.. I see. I need to merge #270 first
Set the v7 protocol as the current version. Include differences with v5 so we can link other implementations to this doc. This should be merged along with a new release that enumerates all the changes that were included in this release:
By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.