mxm commented on code in PR #18739:
URL: https://github.com/apache/iceberg/pull/18739#discussion_r4631187786
##########
flink/v2.3/flink/src/main/java/org/apache/iceberg/flink/sink/dynamic/TableUpdater.java:
##########
@@ -153,8 +153,12 @@ private TableMetadataCache.ResolvedSchemaInfo
findOrCreateSchema(
LOG.info(
"Triggering schema update for table {} {} to {}", identifier,
tableSchema, schema);
UpdateSchema updateApi = table.updateSchema();
- EvolveSchemaVisitor.visit(
- identifier, updateApi, tableSchema, schema, caseSensitive,
dropUnusedColumns);
+ try {
+ EvolveSchemaVisitor.visit(
+ identifier, updateApi, tableSchema, schema, caseSensitive,
dropUnusedColumns);
+ } catch (IllegalArgumentException e) {
+ throw new DynamicRecordException(e.getMessage(), e);
Review Comment:
A single on / off knob is problematic because it diverts all kinds of
errors, even transient ones. I think we can only divert non-transient errors
directly caused by DynamicRecord's metadata (schema, equality fields, spec) and
the data itself.
--
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]