-
Notifications
You must be signed in to change notification settings - Fork 3.8k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
105109: kv: remove `TxnCoordSender.PrepareRetryableError`, rationalize `ManualRestart` r=arulajmani a=nvanbenschoten This commit cleans up the implementation of `GenerateForcedRetryableError` by removing the `TxnCoordSender.PrepareRetryableError` method and having the `TxnCoordSender.ManualRestart` return a retryable error. The cleanup also ensures that the `TxnCoordSender` is left in a `txnRetryableError` state after a `ManualRestart`, so that `Txn.PrepareForRetry` must be called before continuing to use the transaction. The goal with both of these changes is to close the gap between the handling of error-driven txn restarts and manual restarts. It also reworks the code to construct the retry error in the same place that "handles" the error, which is important for future changes that plan to add more context to retry errors. Release note: None Epic: None Co-authored-by: Nathan VanBenschoten <[email protected]>
- Loading branch information
Showing
5 changed files
with
37 additions
and
53 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters