-
Notifications
You must be signed in to change notification settings - Fork 266
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
[ARCTIC-495]remove unnecessary properties when sync and commit properties to ams #496
Conversation
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.
@hameizi I left some comments. PTAL.
@@ -47,5 +48,14 @@ public class ServerTableProperties { | |||
HIDDEN_EXPOSED.add(TableProperties.READ_DISTRIBUTION_MODE_HASH); | |||
HIDDEN_EXPOSED.add(TableProperties.PROTECTED_PROPERTIES.toString()); | |||
HIDDEN_EXPOSED.add(TableProperties.TABLE_EVENT_TIME_FIELD); | |||
|
|||
HIDDEN_INTERNAL.add("meta_store_site"); |
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 change these value with constant variables?
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.
Should we add a CatalogProperties class in core module?
@@ -303,6 +305,8 @@ public void syncDDl(ArcticTable arcticTable) { | |||
|
|||
public void syncProperties(TableMetadata tableMetadata, ArcticTable arcticTable) { | |||
Table table = arcticTable.isKeyedTable() ? arcticTable.asKeyedTable().baseTable() : arcticTable.asUnkeyedTable(); | |||
PropertiesUtil.removeHiddenProperties(tableMetadata.getProperties(), ServerTableProperties.HIDDEN_INTERNAL); |
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.
This map is an immutable map, can not execute remove operation
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.
fixed in new commit
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.
…ties to ams (apache#496) * remove unnecessary properties when sync and commit properties to ams * fix immutable map can not remove and add unit test * fix code style * change log
…ties to ams (#496) * remove unnecessary properties when sync and commit properties to ams * fix immutable map can not remove and add unit test * fix code style * change log
Why are the changes needed?
resolve #495
remove unnecessary properties when sync and commit properties to ams
Brief change log
remove unnecessary properties when sync and commit properties to ams
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