-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Do not stop the restore process after the "point of no return". #2310
Conversation
Once vttablet shuts down MySQL and starts deleting all files, it won't be able to recover if the context is cancelled (e.g. because the RPC got cancelled). That will render the tablet completely unusable. To avoid that let's just not interrupt the restore process once it passed that point of no return.
@@ -563,11 +563,11 @@ def start_vttablet( | |||
|
|||
return self.proc | |||
|
|||
def wait_for_vttablet_state(self, expected, timeout=60.0, port=None): | |||
def _wait_for_vttablet_var(self, var_name, expected, timeout=60.0, port=None): |
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.
Note that we already have poll_for_vars
in test/utils.py
.
After your change, this function sounds to be very similar to the other one? Maybe merge them?
(poll_for_vars
is mostly used in worker.py
.)
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.
It turned out that there's also utils.wait_for_tablet_type() that I can use instead of creating a new function. So I just reverted these changes and modified the test to use utils.wait_for_tablet_type().
For the record, the longer term fix we had talked about was to change the RPCs to a few RPCs: Short of that, this approach looks good to me, after addressing Michael's comments. |
…socket files are directly used (vitessio#2310) * cherry pick of 13198 * Fix conflicts Signed-off-by: Rohit Nayak <[email protected]> --------- Signed-off-by: Rohit Nayak <[email protected]> Co-authored-by: Rohit Nayak <[email protected]>
Once vttablet shuts down MySQL and starts deleting all files, it won't be able
to recover if the context is cancelled (e.g. because the RPC got cancelled).
That will render the tablet completely unusable. To avoid that let's just not
interrupt the restore process once it passed that point of no return.