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

Adds Grant Role support from non-main db #7404

Merged
merged 52 commits into from
Feb 19, 2024
Merged

Adds Grant Role support from non-main db #7404

merged 52 commits into from
Feb 19, 2024

Conversation

gurkanindibay
Copy link
Contributor

@gurkanindibay gurkanindibay commented Jan 5, 2024

DESCRIPTION: Adds support for distributed role-membership management commands from the databases where Citus is not installed (GRANT <role> TO <role>)

This PR also refactors the code-path that allows executing some of the node-wide commands so that we use send deparsed query string to other nodes instead of the queryString passed into utility hook.
Hence fixes #7448.

Copy link

codecov bot commented Jan 5, 2024

Codecov Report

Merging #7404 (4ef4bad) into main (9a0cdbf) will decrease coverage by 0.58%.
The diff coverage is 95.23%.

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #7404      +/-   ##
==========================================
- Coverage   89.60%   89.03%   -0.58%     
==========================================
  Files         282      282              
  Lines       60323    60347      +24     
  Branches     7512     7517       +5     
==========================================
- Hits        54051    53727     -324     
- Misses       4117     4416     +299     
- Partials     2155     2204      +49     

src/test/regress/sql/grant_role_2pc.sql Outdated Show resolved Hide resolved
src/test/regress/sql/grant_role_2pc.sql Outdated Show resolved Hide resolved
src/test/regress/sql/grant_role_2pc.sql Outdated Show resolved Hide resolved
src/backend/distributed/commands/utility_hook.c Outdated Show resolved Hide resolved
src/backend/distributed/commands/utility_hook.c Outdated Show resolved Hide resolved
src/backend/distributed/commands/utility_hook.c Outdated Show resolved Hide resolved
src/backend/distributed/commands/utility_hook.c Outdated Show resolved Hide resolved
src/test/regress/sql/grant_role_2pc.sql Outdated Show resolved Hide resolved
src/test/regress/sql/grant_role_2pc.sql Outdated Show resolved Hide resolved
src/test/regress/sql/grant_role_2pc.sql Outdated Show resolved Hide resolved
src/test/regress/sql/grant_role_2pc.sql Outdated Show resolved Hide resolved
gurkanindibay and others added 2 commits January 29, 2024 13:16
Co-authored-by: Onur Tirtir <onurcantirtir@gmail.com>
Co-authored-by: Onur Tirtir <onurcantirtir@gmail.com>
@onurctirtir onurctirtir self-requested a review February 15, 2024 11:52
@onurctirtir onurctirtir self-requested a review February 15, 2024 12:10
Copy link
Member

@onurctirtir onurctirtir left a comment

Choose a reason for hiding this comment

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

We're close to merging this.

Copy link
Member

@onurctirtir onurctirtir left a comment

Choose a reason for hiding this comment

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

In summary, let's merge those two one-liner fixes in separate two PRs and then we're good to merge this:
#7404 (comment)
#7404 (comment)

@onurctirtir
Copy link
Member

Let's merge #7517 and then rebase this onto main. Then we can finally merge this one.

@gurkanindibay
Copy link
Contributor Author

Let's merge #7517 and then rebase this onto main. Then we can finally merge this one.

Merged #7517 Kindly request your review

@gurkanindibay gurkanindibay enabled auto-merge (squash) February 19, 2024 13:04
Co-authored-by: Onur Tirtir <onurcantirtir@gmail.com>
@gurkanindibay gurkanindibay merged commit 2cbfdbf into main Feb 19, 2024
157 checks passed
@gurkanindibay gurkanindibay deleted the grant_role_2pc branch February 19, 2024 14:53
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.

Deparse DDL commands instead of directly executing queryString on main-db
3 participants