kumarpritam863 commented on code in PR #18739:
URL: https://github.com/apache/iceberg/pull/18739#discussion_r4520131702
##########
flink/v2.3/flink/src/main/java/org/apache/iceberg/flink/sink/dynamic/DynamicIcebergSink.java:
##########
@@ -589,6 +667,32 @@ private Configuration fromReadableConfig() {
? (Configuration) readableConfig
: Configuration.fromMap(readableConfig.toMap());
}
+
+ /**
+ * Rebuilds the public {@link DynamicRecord} handed to the error stream
from the internal
+ * record, preserving {@code upsertMode} and {@code equalityFields}
(mapping the internal
+ * field-ids back to column names via the record schema). Routing hints
(distribution mode,
+ * write parallelism) are not meaningful for an errored record and are
left at their defaults.
+ */
+ private static DynamicRecord toDynamicRecord(DynamicRecordInternal
internal) {
+ Schema schema = internal.schema();
+ DynamicRecord record =
+ new DynamicRecord(
+ TableIdentifier.parse(internal.tableName()),
+ internal.branch(),
+ schema,
+ internal.rowData(),
+ internal.spec(),
+ null,
+ -1);
Review Comment:
Done. Thanks for pointing this out.
--
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]