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
[FLINK-23069][table-api-java] Support schemaless #executeInsert(TableDescriptor) #16470
Conversation
Thanks a lot for your contribution to the Apache Flink project. I'm the @flinkbot. I help the community Automated ChecksLast check on commit aa234d9 (Thu Sep 23 18:03:12 UTC 2021) Warnings:
Mention the bot in a comment to re-run the automated checks. Review Progress
Please see the Pull Request Review Guide for a full explanation of the review process. The Bot is tracking the review progress through labels. Labels are applied according to the order of the review items. For consensus, approval by a Flink committer of PMC member is required Bot commandsThe @flinkbot bot supports the following commands:
|
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 @Airblader. This will be a quite useful feature. We should add more tests however.
...k-table-api-java/src/main/java/org/apache/flink/table/api/internal/TableEnvironmentImpl.java
Outdated
Show resolved
Hide resolved
...nk-table-api-java/src/main/java/org/apache/flink/table/catalog/ExternalSchemaTranslator.java
Show resolved
Hide resolved
...nk-table-api-java/src/main/java/org/apache/flink/table/catalog/ExternalSchemaTranslator.java
Outdated
Show resolved
Hide resolved
...nk-table-api-java/src/main/java/org/apache/flink/table/catalog/ExternalSchemaTranslator.java
Outdated
Show resolved
Hide resolved
...ner/src/test/scala/org/apache/flink/table/planner/runtime/stream/table/TableSinkITCase.scala
Outdated
Show resolved
Hide resolved
6623074
to
533cbed
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.
LGTM, I had some minor comments that I will fix while merging.
...main/scala/org/apache/flink/table/api/bridge/scala/internal/StreamTableEnvironmentImpl.scala
Outdated
Show resolved
Hide resolved
a772300
to
bb6e928
Compare
As discussed offline, I also added schema-less |
What is the purpose of the change
For
Table#executeInsert
, the schema can actually be inferred and thus is not required to be defined in the table descriptor, which simplifies the API usage in this case. However, we apply the same "merging" strategy between resolved and declared schema as we do during Table API <-> DataStream conversion.Brief change log
TableDescriptor
optional.#executeInsert
and build a new descriptor.Verifying this change
This change is already covered by existing tests, such as (please describe tests).
TableSinkITCase
(adjusted to use this new functionality)Does this pull request potentially affect one of the following parts:
@Public(Evolving)
: yesDocumentation