loserwang1024 commented on code in PR #4584:
URL: https://github.com/apache/flink-cdc/pull/4584#discussion_r4356063089
##########
flink-cdc-connect/flink-cdc-pipeline-connectors/flink-cdc-pipeline-connector-fluss/src/test/java/org/apache/flink/cdc/connectors/fluss/sink/FlussMetadataApplierTest.java:
##########
@@ -729,6 +729,37 @@ void
testExistingPrimaryKeyTableWithCustomBucketKeys(String bucketKeys) throws E
}
}
+ @Test
+ void testCreateTableWithDataLakeProperties() throws Exception {
+ Map<String, String> tableProperties = new HashMap<>();
+ tableProperties.put("paimon.file.format", "orc");
+ tableProperties.put("iceberg.write.format.default", "parquet");
+ Schema schema =
+ Schema.newBuilder()
+ .physicalColumn("id", DataTypes.BIGINT().notNull())
+ .primaryKey("id")
+ .build();
+ TableId tableId = TableId.tableId(DATABASE_NAME, "table1");
+
+ try (FlussMetaDataApplier applier =
+ new FlussMetaDataApplier(
+ FLUSS_CLUSTER_EXTENSION.getClientConfig(),
+ tableProperties,
+ Collections.emptyMap(),
+ Collections.emptyMap())) {
+ applier.applySchemaChange(new CreateTableEvent(tableId, schema));
+
+ TableDescriptor tableDescriptor =
+ admin.getTableInfo(new TablePath(DATABASE_NAME, "table1"))
+ .get()
+ .toTableDescriptor();
+ assertThat(tableDescriptor.getCustomProperties())
Review Comment:
Thanks for the suggestion. I agree that an end-to-end test would be
valuable, but it would require introducing Paimon dependencies and substantial
additional test setup. Could we track this in a separate follow-up task for
lake integration testing, keeping this PR focused on passing custom properties
through the pipeline sink?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]