Fixing backup tests flakiness#12655
Merged
deepthi merged 3 commits intovitessio:mainfrom Mar 23, 2023
Merged
Conversation
Signed-off-by: Rameez Sajwani <rameezwazirali@hotmail.com>
Signed-off-by: Rameez Sajwani <rameezwazirali@hotmail.com>
rsajwani
commented
Mar 21, 2023
| // Args: | ||
| // tablet_type: 'replica' or 'rdonly'. | ||
| func vtctlBackup(t *testing.T, tabletType string) { | ||
| // Start vtorc before running backups |
Contributor
Author
There was a problem hiding this comment.
This was creating multiple instances of VTorc during testing. I don't think this was intentional. If we want to test multi instance VTorc then we should write a separate test for it. This is backup test and should try to test backup functionality.
Contributor
There was a problem hiding this comment.
Yes, this wasn't intentional.
Signed-off-by: Rameez Sajwani <rameezwazirali@hotmail.com>
deepthi
approved these changes
Mar 22, 2023
Collaborator
|
I don't understand what the test was trying to do with deleting |
rsajwani
added a commit
to planetscale/vitess
that referenced
this pull request
Mar 27, 2023
* remove unnecessary vtorc process Signed-off-by: Rameez Sajwani <rameezwazirali@hotmail.com> * Adding vtorc disabling at right place Signed-off-by: Rameez Sajwani <rameezwazirali@hotmail.com> * Adding comments Signed-off-by: Rameez Sajwani <rameezwazirali@hotmail.com> --------- Signed-off-by: Rameez Sajwani <rameezwazirali@hotmail.com>
4 tasks
GuptaManan100
pushed a commit
that referenced
this pull request
Mar 28, 2023
Closed
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Description
Backup Tests
TestBackupMysqlctld/TestPrimaryBackupis flaky. Here is one such instance of failurehttps://github.com/vitessio/vitess/actions/runs/4477008834/jobs/7868010386
The failure is coming from this piece of test code
The reason is we have introduced VTOrc in the test which tries to fix Primary when it is down. When we delete the tablet, VTorc tries to elect a new primary. If it elect
replica1as new primary then we are good but if it electsprimaryas new one thenRestoreFromBackupfails.Related Issue(s)
closes #12687
Solution
There were few ways to resolve it.
I went with option#2, as it looked neat and doesn't result in a lot of changes in code.
Testing
Ran test few times locally and then on github action. It looked much stable now.
Checklist
Deployment Notes