wombatu-kun commented on code in PR #16655:
URL: https://github.com/apache/iceberg/pull/16655#discussion_r4244688861


##########
kafka-connect/kafka-connect/src/main/java/org/apache/iceberg/connect/data/RecordUtils.java:
##########
@@ -47,9 +47,12 @@
 
 class RecordUtils {
 
-  @SuppressWarnings("unchecked")
   static Object extractFromRecordValue(Object recordValue, String fieldName) {
-    List<String> fields = Splitter.on('.').splitToList(fieldName);
+    return extractFromRecordValue(recordValue, 
Splitter.on('.').splitToList(fieldName));
+  }
+
+  @SuppressWarnings("unchecked")
+  static Object extractFromRecordValue(Object recordValue, List<String> 
fields) {

Review Comment:
   Dropped the `String` overload in 23e1b0073a, and `TestRecordUtils` now 
splits with `Splitter.on('.').splitToList(...)`, so it exercises the production 
signature. Since the split now happens in the `SinkWriter` constructor, I also 
added `TestSinkWriter.dynamicRouteNestedField`, which routes on a nested 
`route.table` field and fails if the constructor stops splitting.



-- 
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]

Reply via email to