wzx140 commented on code in PR #6745: URL: https://github.com/apache/hudi/pull/6745#discussion_r990612384
########## hudi-client/hudi-spark-client/src/main/java/org/apache/hudi/util/HoodieSparkRecordUtils.java: ########## @@ -91,21 +65,20 @@ private static Option<String> getNullableValAsString(StructType structType, Inte * @param structType {@link StructType} instance. * @return Column value if a single column, or concatenated String values by comma. */ - public static Object getRecordColumnValues(InternalRow row, + public static ComparableList getRecordColumnValues(InternalRow row, String[] columns, StructType structType, boolean consistentLogicalTimestampEnabled) { - if (columns.length == 1) { - NestedFieldPath posList = HoodieInternalRowUtils.getCachedPosList(structType, columns[0]); - return HoodieUnsafeRowUtils.getNestedInternalRowValue(row, posList); - } else { - // TODO this is inefficient, instead we can simply return array of Comparable - StringBuilder sb = new StringBuilder(); - for (String col : columns) { - // TODO support consistentLogicalTimestampEnabled - NestedFieldPath posList = HoodieInternalRowUtils.getCachedPosList(structType, columns[0]); - return HoodieUnsafeRowUtils.getNestedInternalRowValue(row, posList); + List<Comparable> list = new LinkedList<>(); + for (String column : columns) { + NestedFieldPath posList = HoodieInternalRowUtils.getCachedPosList(structType, column); + Object value = HoodieUnsafeRowUtils.getNestedInternalRowValue(row, posList); + DataType dataType = posList.parts()[posList.parts().length - 1]._2.dataType(); + if (value instanceof InternalRow | value instanceof MapData | value instanceof ArrayData Review Comment: Removed ########## hudi-spark-datasource/hudi-spark-common/src/main/scala/org/apache/hudi/HoodieBaseRelation.scala: ########## @@ -461,6 +461,18 @@ abstract class HoodieBaseRelation(val sqlContext: SQLContext, } protected def getTableState: HoodieTableState = { + val mergerImpls = (if (optParams.contains(HoodieWriteConfig.MERGER_IMPLS.key())) { Review Comment: Fixed -- 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: commits-unsubscr...@hudi.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org