-
Notifications
You must be signed in to change notification settings - Fork 13.9k
[FLINK-38766][table] Add support for ALTER MATERIALIZED TABLE ADD support
#27302
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
Conversation
raminqaf
left a comment
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.
Thanks for the contribution @snuyanzin! Excellent PR, with many improvements and cleanups! Left some nit comments. Should be good for the merge in the next round!
...y/src/test/java/org/apache/flink/table/gateway/service/MaterializedTableStatementITCase.java
Outdated
Show resolved
Hide resolved
...pache/flink/table/planner/operations/converters/AbstractAlterMaterializedTableConverter.java
Outdated
Show resolved
Hide resolved
.../apache/flink/table/planner/operations/SqlMaterializedTableNodeToOperationConverterTest.java
Outdated
Show resolved
Hide resolved
...table-planner/src/main/java/org/apache/flink/table/planner/utils/MaterializedTableUtils.java
Outdated
Show resolved
Hide resolved
...y/src/test/java/org/apache/flink/table/gateway/service/MaterializedTableStatementITCase.java
Outdated
Show resolved
Hide resolved
twalthr
left a comment
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.
Thank you @snuyanzin. I added a couple of minor comments to make code a bit more readability and improve error messages. Overall the PR looks great!
...y/src/test/java/org/apache/flink/table/gateway/service/MaterializedTableStatementITCase.java
Outdated
Show resolved
Hide resolved
...y/src/test/java/org/apache/flink/table/gateway/service/MaterializedTableStatementITCase.java
Outdated
Show resolved
Hide resolved
...pache/flink/table/planner/operations/converters/AbstractAlterMaterializedTableConverter.java
Show resolved
Hide resolved
.../table/planner/operations/converters/SqlAlterMaterializedTableDropDistributionConverter.java
Outdated
Show resolved
Hide resolved
...ache/flink/table/planner/operations/converters/SqlAlterMaterializedTableSchemaConverter.java
Show resolved
Hide resolved
.../apache/flink/table/planner/operations/SqlMaterializedTableNodeToOperationConverterTest.java
Outdated
Show resolved
Hide resolved
.../apache/flink/table/planner/operations/SqlMaterializedTableNodeToOperationConverterTest.java
Outdated
Show resolved
Hide resolved
.../apache/flink/table/planner/operations/SqlMaterializedTableNodeToOperationConverterTest.java
Outdated
Show resolved
Hide resolved
| + "FRESHNESS = INTERVAL '30' SECOND\n" | ||
| + "REFRESH_MODE = FULL\n" | ||
| + "AS SELECT * FROM t3", | ||
| "Column 'c' referenced by materialized table option 'partition.fields.c.date-formatter' isn't a partition column. Available partition columns: ['']."), |
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.
[''] bug?
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.
No, here in SQL there is a table option partition.fields.c.date-formatter referencing column c, however at the same time there is no any partition defined for the materialized table and as a result no available partition columns
| + "FROM `builtin`.`default`.`t1` AS `t1`"); | ||
| } | ||
|
|
||
| private static class TestSpec { |
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.
thank you for setting up more test infra!
...s/src/test/java/org/apache/flink/table/file/testutils/catalog/TestFileSystemCatalogTest.java
Outdated
Show resolved
Hide resolved
raminqaf
left a comment
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.
Thanks for the contribution! LGTM!
...ble/flink-table-planner/src/test/scala/org/apache/flink/table/api/TableEnvironmentTest.scala
Show resolved
Hide resolved
d20fe7b to
7555eb4
Compare
...table-planner/src/main/java/org/apache/flink/table/planner/utils/MaterializedTableUtils.java
Show resolved
Hide resolved
twalthr
left a comment
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.
Thanks for the update @snuyanzin. I just had some minor comments. Maybe you can address them before merging. But overall the PR looks good to me.
...ache/flink/table/planner/operations/converters/AbstractCreateMaterializedTableConverter.java
Outdated
Show resolved
Hide resolved
...ache/flink/table/planner/operations/converters/AbstractCreateMaterializedTableConverter.java
Outdated
Show resolved
Hide resolved
...k/table/planner/operations/converters/SqlAlterMaterializedTableAddDistributionConverter.java
Outdated
Show resolved
Hide resolved
….RefreshStatus` instead of long names" This reverts commit 306b9c8.
…upport This closes apache#27302.
…upport This closes apache#27302.
What is the purpose of the change
Part of FLIP-550
The PR to add support for operations like
Brief change log
converters and tests
Verifying this change
there are tests added
Does this pull request potentially affect one of the following parts:
@Public(Evolving): (no)Documentation