-
Notifications
You must be signed in to change notification settings - Fork 314
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
feat: support renaming table in the catalog manger #824
feat: support renaming table in the catalog manger #824
Conversation
I think you could implement rename for the local catalog manager first. The remote catalog manager is a bit more complicated and let's support it in the next pr. |
Ok, I will implement the remote part in the next PR. |
9fa1419
to
c232259
Compare
Codecov Report
@@ Coverage Diff @@
## develop #824 +/- ##
===========================================
- Coverage 86.32% 86.21% -0.12%
===========================================
Files 422 425 +3
Lines 55669 56097 +428
===========================================
+ Hits 48058 48365 +307
- Misses 7611 7732 +121
Flags with carried forward coverage won't be shown. Click here to find out more.
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. |
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.
I'm able to review this PR more carefully in the next week. But It seems the changes to the key in the system_catalog
table could cause unexpected problems: the database might not recover the correct table name after it restarts. I think you could address this problem first.
@e1ijah1 Hi, is this PR ready for review? I can review it if it's ready. |
Yes. It's ready to review. |
80e8e91
to
b0765ad
Compare
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.
Most comments are related to style and the API design of rename_table()
Co-authored-by: Yingwen <realevenyag@gmail.com>
9512df3
to
886c606
Compare
Thanks for your advice, I've fixed them all. |
There is a test failure:
|
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
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
* feat: support renaming table in the catalog manger * feat: implement rename table for local catalog manager * chore: fmt code * fix: update system catalog when renaming table in local catalog manager * chore: add instance test for rename table * chore: fix frontend test * chore: fix comment * chore: fix rename table test * fix: renaming a table with an existing name * fix: improve the system catalog's renaming process * chore: improve the code * chore: improve the comment Co-authored-by: Yingwen <realevenyag@gmail.com> * chore: improve the code * chore: fix tests * chore: fix instance_test * chore: improve the code Co-authored-by: Yingwen <realevenyag@gmail.com>
I hereby agree to the terms of the GreptimeDB CLA
What's changed and what's your intention?
support renaming table in the catalog manger
Checklist
Refer to a related PR or issue link (optional)
#723