-
Notifications
You must be signed in to change notification settings - Fork 290
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
[AMORO-1865]build a rule of relationship between table and resource group #3300
base: master
Are you sure you want to change the base?
Conversation
@@ -123,6 +123,10 @@ public String toString() { | |||
return String.format("%s.%s.%s(tableId=%d)", catalog, database, tableName, id); | |||
} | |||
|
|||
public String getTableFullName() { |
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.
Is this method nessessary? How about invoke getIdentifier().toString()
to get full name?
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.
Is this method nessessary? How about invoke
getIdentifier().toString()
to get full name?
getIdentifier().toString()
returns TableIdentifier[catalog.db.table]
, So it's not suitable.
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.
Okay, It not org.apache.amoro.table.TableIdentifier
. I perfer use the following method, WDYT?
public org.apache.amoro.table.TableIdentifier getTableIdentifier() {
return org.apache.amoro.table.TableIdentifier.of(catalog, database, tableName);
}
.collect(Collectors.toList()); | ||
|
||
final String tableName = | ||
String.format( |
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.
tableIdentifier.toString()
This implementation method will be contrary to the current advanced issue of splitting the rest service and the scheduling service. It makes the update of the group have to occur at the master node. |
Why are the changes needed?
Close #1865.
Brief change log
Backend:
And traverse the table corresponding to the catalog default value of the current optimize-group to see if it matches the current rule and assign the value.
When the group of the above table is changed, the tableConfigureChange responsibility chain call of the table will be triggered.
Special note
We support manually adding the table name to the rules of a group, which is equivalent to the original manual configuration of the group. Because in our practice, there are some situations that require manual specification.
How was this patch tested?
Add some test cases that check the changes thoroughly including negative and positive cases if possible
Add screenshots for manual tests if appropriate
Run test locally before making a pull request
Documentation