Skip to content

Add redirection awareness for SHOW GRANTS statement#11270

Merged
findepi merged 1 commit intotrinodb:masterfrom
findinpath:show-grants-redirection-awareness
Mar 9, 2022
Merged

Add redirection awareness for SHOW GRANTS statement#11270
findepi merged 1 commit intotrinodb:masterfrom
findinpath:show-grants-redirection-awareness

Conversation

@findinpath
Copy link
Copy Markdown
Contributor

@findinpath findinpath commented Mar 2, 2022

Description

Disallow table redirection for the SHOW GRANTS statement.

Is this change a fix, improvement, new feature, refactoring, or other?

New feature.

Is this a change to the core query engine, a connector, client library, or the SPI interfaces? (be specific)

This change affects the core query engine.

How would you describe this change to a non-technical end user or system administrator?

Performing automatic table redirection behind the scenes within the SHOW GRANTS statement is disallowed as pointed out in #11202

Related issues, pull requests, and links

Documentation

(x) No documentation is needed.
( ) Sufficient documentation is included in this PR.
( ) Documentation PR is available with #prnumber.
( ) Documentation issue #issuenumber is filed, and can be handled later.

Release notes

( ) No release notes entries required.
(x) Release notes entries required with the following suggested text:

# Main
* Disallow table redirections in SHOW GRANTS statement

@cla-bot cla-bot bot added the cla-signed label Mar 2, 2022
Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

@phd3 there is also a TODO comment here:

// TODO support table redirection
@Override
public List<GrantInfo> listTablePrivileges(Session session, QualifiedTablePrefix prefix)

Am I correct in assuming that handling the MetadataManager#listTablePrivileges is not in the scope of this PR ?

@findinpath findinpath requested review from electrum, findepi and phd3 March 2, 2022 07:06
@findinpath
Copy link
Copy Markdown
Contributor Author

@phd3

In the comment #10577 (comment) the why? for disallowing redirects on SHOW GRANTS statement is: coherent with future select.
Could you please add more detail to the reasoning behind this choice?

@findinpath findinpath force-pushed the show-grants-redirection-awareness branch from 2360409 to c65eaf2 Compare March 2, 2022 13:24
@findinpath findinpath requested a review from findepi March 8, 2022 11:57
@findepi findepi requested review from kokosing and removed request for findepi and kokosing March 9, 2022 10:10
@findepi findepi merged commit 8d0ff22 into trinodb:master Mar 9, 2022
@github-actions github-actions bot added this to the 373 milestone Mar 9, 2022
This was referenced Mar 9, 2022
@phd3
Copy link
Copy Markdown
Member

phd3 commented Mar 9, 2022

@findinpath sorry for the delayed response here.

Am I correct in assuming that handling the MetadataManager#listTablePrivileges is not in the scope of this PR

seems reasonable.

In the comment #10577 (comment) the why? for disallowing redirects on SHOW GRANTS statement is: coherent with future select.

IIRC the coherency point was only for show-create, and not grants.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Development

Successfully merging this pull request may close these issues.

3 participants