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

release-20.2: backupccl: fix descriptor privilege restoration #54854

Merged
merged 1 commit into from
Sep 28, 2020

Conversation

pbardea
Copy link
Contributor

@pbardea pbardea commented Sep 28, 2020

Backport 1/1 commits from #54328.

/cc @cockroachdb/release


This commit ensures that the privilege descriptor on every restored
descriptor are properly reset based on the user that is performing the
import.

As always, the database descriptor will be reset as if it had just been
created. And the table descriptor will inherit the privileges of the
database that it is restoring into. The privileges of schemas and types
are also now reset.

Schemas will have the same behavior as tables and will inherit the
privileges of its database (like CREATE SCHEMA). Types will behave like
databases and will have privileges as if it was created by the restoring
user.

Release note (bug fix): Previous versions of 20.2 would not properly
clear grants and owners on non-cluster restores.

This commit ensures that the privilege descriptor on every restored
descriptor are properly reset based on the user that is performing the
import.

As always, the database descriptor will be reset as if it had just been
created. And the table descriptor will inherit the privileges of the
database that it is restoring into. The privileges of schemas and types
are also now reset.

Schemas will have the same behavior as tables and will inherit the
privileges of its database (like CREATE SCHEMA). Types will behave like
databases and will have privileges as if it was created by the restoring
user.

Release note (bug fix): Previous versions of 20.2 would not properly
clear grants and owners on non-cluster restores.
@pbardea pbardea requested review from dt and a team September 28, 2020 13:57
@cockroach-teamcity
Copy link
Member

This change is Reviewable

@pbardea pbardea merged commit 23260be into cockroachdb:release-20.2 Sep 28, 2020
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.

None yet

3 participants