-
Notifications
You must be signed in to change notification settings - Fork 5.9k
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
executor: add DROP ROLE
support
#9616
Conversation
parser pr: pingcap/parser#237 |
/run-all-tests |
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.
Could drop role
statement drop an user, or drop user
statement drop an role in MySQL? @imtbkcat
@tiancaiamao yes, |
LGTM |
pingcap/parser#237 is merged @imtbkcat |
/run-all-tests |
Codecov Report
@@ Coverage Diff @@
## master #9616 +/- ##
================================================
- Coverage 67.3912% 67.3544% -0.0369%
================================================
Files 377 377
Lines 79353 79383 +30
================================================
- Hits 53477 53468 -9
- Misses 21104 21134 +30
- Partials 4772 4781 +9 |
PTAL @jackysp |
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.
LGTM
What problem does this PR solve?
add
DROP ROLE
function for parser and executor.What is changed and how it works?
Role is same as user, is store in
mysql.user
table. We do same action asDROP USER
when we need to drop a role. Also, as we has added some system table for RBAC, likemysql.role_edges
andmysql.default_role
. We have to delete information from these tables when executeDROP ROLE
Check List
Tests
Code changes
Side effects