Flink: Support table-name as fallback key for catalog-table in connector options#15673
Open
lilei1128 wants to merge 2 commits intoapache:mainfrom
Open
Flink: Support table-name as fallback key for catalog-table in connector options#15673lilei1128 wants to merge 2 commits intoapache:mainfrom
lilei1128 wants to merge 2 commits intoapache:mainfrom
Conversation
mxm
reviewed
Apr 1, 2026
Contributor
mxm
left a comment
There was a problem hiding this comment.
Thanks @lilei1128! I wonder, why would we add another way of doing the same thing? Is this option widely used?
Comment on lines
+64
to
+70
| public static final ConfigOption<String> TABLE_NAME = | ||
| ConfigOptions.key("table-name") | ||
| .stringType() | ||
| .noDefaultValue() | ||
| .withDescription( | ||
| "Alias for 'catalog-table'. Table name managed in the underlying iceberg catalog" | ||
| + " and database."); |
Contributor
There was a problem hiding this comment.
Instead of adding a new ConfigOption, we can add "table-name" via withFallbackKey("table-name") to the existing catalog-name option.
Contributor
Author
There was a problem hiding this comment.
Thanks for the suggestion! Updated to use withFallbackKeys("table-name") on the existing
CATALOG_TABLE option instead of adding a separate ConfigOption.
Contributor
Author
There was a problem hiding this comment.
The modification is complete. Could you please check it for me
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
When using the Flink Iceberg connector with 'connector'='iceberg', the
'table-name' option in the WITH clause was silently ignored. The connector
only recognized 'catalog-table' to specify the Iceberg table name, causing
it to fall back to the Flink DDL table name, auto-create a new empty table,
and return 0 rows on reads with no error.
This commit adds 'table-name' as a fallback key for the existing CATALOG_TABLE
ConfigOption via withFallbackKeys("table-name"), letting the Flink framework
handle the lookup natively with the following precedence:
catalog-table > table-name > Flink DDL table name
A WARN log is emitted when both options are set with conflicting values.
Changes are applied to all supported Flink versions (1.20, 2.0, 2.1).