Skip to content
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-31603][table-planner] Line break should be removed in create t… #22276

Closed
wants to merge 1 commit into from

Conversation

paul8263
Copy link
Contributor

…able with-clauses, load module with-clauses and table hints for both keys and values

What is the purpose of the change

Line break should be removed in create table with-clauses, load module with-clauses and table hints for both keys and values.

Brief change log

  • changed FlinkTableOptions and FlinkHints key/value retrieving logic by replacing all line breaks before returning the actual values.

Files Updated:

  • flink-table/flink-sql-parser/src/main/java/org/apache/flink/sql/parser/ddl/SqlTableOption.java
  • flink-table/flink-table-planner/src/main/java/org/apache/flink/table/planner/hint/FlinkHints.java
  • flink-table/flink-table-planner/src/test/java/org/apache/flink/table/planner/operations/SqlDdlToOperationConverterTest.java
  • flink-table/flink-table-planner/src/test/java/org/apache/flink/table/planner/operations/SqlDmlToOperationConverterTest.java
  • flink-table/flink-table-planner/src/test/java/org/apache/flink/table/planner/operations/SqlOtherOperationConverterTest.java

Verifying this change

This change added tests and can be verified as follows:

Added tests for creating table ,loading modules and inserting into clauses with table hint.

UT updated:

  • flink-table/flink-table-planner/src/test/java/org/apache/flink/table/planner/operations/SqlDdlToOperationConverterTest.java
  • flink-table/flink-table-planner/src/test/java/org/apache/flink/table/planner/operations/SqlDmlToOperationConverterTest.java
  • flink-table/flink-table-planner/src/test/java/org/apache/flink/table/planner/operations/SqlOtherOperationConverterTest.java

Does this pull request potentially affect one of the following parts:

  • Dependencies (does it add or upgrade a dependency): no
  • The public API, i.e., is any changed class annotated with @Public(Evolving): no
  • The serializers: no
  • The runtime per-record code paths (performance sensitive): no
  • Anything that affects deployment or recovery: JobManager (and its components), Checkpointing, Kubernetes/Yarn, ZooKeeper: no
  • The S3 file system connector: no

Documentation

  • Does this pull request introduce a new feature? no

…able with-clauses, load module with-clauses and table hints for both keys and values
@flinkbot
Copy link
Collaborator

flinkbot commented Mar 27, 2023

CI report:

Bot commands The @flinkbot bot supports the following commands:
  • @flinkbot run azure re-run the last Azure build

Copy link
Contributor

@MartijnVisser MartijnVisser left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@paul8263 I'm inclined to give a -1 for this; why should we remove line breaks? This is not a bug in Flink, this is an error in the user submitted statement. I would prefer throwing a meaningful error to user instead of trying to fix this in Flink. We'll only introduce additional complexity with this in Flink.

@wuchong
Copy link
Member

wuchong commented Apr 8, 2023

I would like to close this PR first. The community suggests reaching a consensus before opening a pull request. Feel free to continue the discussion on the JIRA issue.

@wuchong wuchong closed this Apr 8, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
4 participants