Skip to content
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

backupccl, restoreccl: include system.privileges in full cluster restore #86830

Merged

Conversation

RichardJCai
Copy link
Contributor

@RichardJCai RichardJCai commented Aug 24, 2022

Release justification: Minor enhancement to not yet released feature

Release note: None

Fixes #84762

@RichardJCai RichardJCai requested review from adityamaru and a team August 24, 2022 22:55
@cockroach-teamcity
Copy link
Member

This change is Reviewable

Copy link
Collaborator

@stevendanna stevendanna left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:lgtm:

There are a few other tests to update:

  • TestClusterRestoreFailCleanup has a some lists of tables that should transition to a DROP state on revert. We need to add this new table to that list:


https://github.com/cockroachdb/cockroach/blob/master/pkg/ccl/backupccl/full_cluster_backup_restore_test.go#L732

If you are feeling generous, you could also add it to:

https://github.com/cockroachdb/cockroach/blob/master/pkg/ccl/backupccl/full_cluster_backup_restore_test.go#L732

@@ -538,7 +538,7 @@ var systemTableBackupConfiguration = map[string]systemBackupConfiguration{
expectMissingInSystemTenant: true,
},
systemschema.SystemPrivilegeTable.GetName(): {
shouldIncludeInClusterBackup: optOutOfClusterBackup,
shouldIncludeInClusterBackup: optInToClusterBackup, // No desc ID columns.
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ Double checked that it looks like the format for the path element in the table also doesn't use any IDs that need rewritting.

Release justification: Minor enhancement to not yet released feature

Release note: None
@RichardJCai RichardJCai force-pushed the include_system_privileges_in_restore branch from 1b8d983 to 2d485fb Compare August 26, 2022 19:46
@RichardJCai
Copy link
Contributor Author

CI failure is flake
Thanks for reviewing!

bors r=stevendanna

@craig
Copy link
Contributor

craig bot commented Aug 26, 2022

👎 Rejected by too few approved reviews

@RichardJCai
Copy link
Contributor Author

Nvm need github approval @stevendanna

@stevendanna
Copy link
Collaborator

bors r=stevendanna

@craig
Copy link
Contributor

craig bot commented Aug 27, 2022

Build succeeded:

@craig craig bot merged commit 92b550b into cockroachdb:master Aug 27, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

sql, bulkio: support backup restore for system.privileges table
3 participants