-
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
[vtctld] Migrate ListBackups as GetBackups in new vtctld server #7352
[vtctld] Migrate ListBackups as GetBackups in new vtctld server #7352
Conversation
Signed-off-by: Andrew Mason <amason@slack-corp.com>
…oproto Signed-off-by: Andrew Mason <amason@slack-corp.com>
…d tests Signed-off-by: Andrew Mason <amason@slack-corp.com>
The reason this should not be exported is that we want to enforce a singleton usage for these testutil implementations, and the best way to ensure that is to make it impossible for users to create a new instance by hiding the type away. Signed-off-by: Andrew Mason <amason@slack-corp.com>
Signed-off-by: Andrew Mason <amason@slack-corp.com>
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.
Looks good to me. I trust your judgement on whether you want to try testing this locally before it's merged!
} | ||
|
||
// ListBackups is part of the backupstorage.BackupStorage interface. | ||
func (bs *backupStorage) ListBackups(ctx context.Context, dir string) ([]backupstorage.BackupHandle, error) { |
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.
Implementing a whole new fake is so much work but it will definitely pay off 🏆 thank you!
[vtctld] Migrate ListBackups as GetBackups in new vtctld server
[vtctld] Migrate ListBackups as GetBackups in new vtctld server
[vtctld] Migrate ListBackups as GetBackups in new vtctld server Signed-off-by: Andrew Mason <amason@slack-corp.com>
Description
Migrates
ListBackups
asGetBackups
in the new rpcs. Functionality is the same. I also added a util package for going from abackupstorage.BackupHandle
to a proto message, and I un-exported theTestTabletManagerClient
type I added in #7346 because I want to enforce the singleton pattern I documented through the type system.Example:
Related Issue(s)
Checklist
Deployment Notes
Impacted Areas in Vitess
Components that this PR will affect: