-
Notifications
You must be signed in to change notification settings - Fork 9.9k
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
etcdserverpb: add "retry" flag to WatchResponse #15253
Conversation
Problem: client relies on string value of CancelReason to determine if watcher should be retried. This is too fragile. See etcd-io#14992 Solution: add explicit `retry` flag fixes: etcd-io#15058 Signed-off-by: Bogdan Kanivets <[email protected]>
807ea23
to
7404574
Compare
@@ -834,6 +834,9 @@ message WatchResponse { | |||
// framgment is true if large watch response was split over multiple responses. | |||
bool fragment = 7 [(versionpb.etcd_version_field)="3.4"]; | |||
|
|||
// retry is true if watcher should be retried on cancel. | |||
bool retry = 8 [(versionpb.etcd_version_field)="3.5"]; |
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'll backport to 3.5, so setting version 3.5 here
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.
No backports of fields!
This code is covered by TestV3AuthWatchAndTokenExpire integration test. |
This is a small change but with a big impact on important API semantics. Please start with creating issue discussing problem you want to solve and why solution you propose is worth adopting. |
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.
Would like to first discuss different options before picking a solution.
@serathius do you mind continuing discussion in #15058? Here is my comment explainig |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed after 21 days if no further activity occurs. Thank you for your contributions. |
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.
After having consensus about the approach, I think we should update the changelog for describing the new field (or changes for other approach): https://github.com/etcd-io/etcd/blob/main/CHANGELOG/CHANGELOG-3.6.md
Problem: client relies on string value of CancelReason to determine if watcher should be retried. This is too fragile. See #14992
Solution: add explicit
retry
flagfixes: #15058
Signed-off-by: Bogdan Kanivets [email protected]
Please read https://github.com/etcd-io/etcd/blob/main/CONTRIBUTING.md#contribution-flow.