From 978f7fe6179a8eac46ac0ec242980c2914f4214f Mon Sep 17 00:00:00 2001 From: binwei Date: Tue, 20 Aug 2024 21:36:41 +0000 Subject: [PATCH] enable all complex data type --- .../backendsapi/velox/VeloxBackend.scala | 32 +++++++++---------- 1 file changed, 16 insertions(+), 16 deletions(-) diff --git a/backends-velox/src/main/scala/org/apache/gluten/backendsapi/velox/VeloxBackend.scala b/backends-velox/src/main/scala/org/apache/gluten/backendsapi/velox/VeloxBackend.scala index 21175f20eb647..7aa6112181f4b 100644 --- a/backends-velox/src/main/scala/org/apache/gluten/backendsapi/velox/VeloxBackend.scala +++ b/backends-velox/src/main/scala/org/apache/gluten/backendsapi/velox/VeloxBackend.scala @@ -127,28 +127,28 @@ object VeloxBackendSettings extends BackendSettingsApi { case ParquetReadFormat => val typeValidator: PartialFunction[StructField, String] = { // Parquet scan of nested array with struct/array as element type is unsupported in Velox. - case StructField(_, arrayType: ArrayType, _, _) - if arrayType.elementType.isInstanceOf[StructType] => - "StructType as element in ArrayType" - case StructField(_, arrayType: ArrayType, _, _) - if arrayType.elementType.isInstanceOf[ArrayType] => - "ArrayType as element in ArrayType" + // case StructField(_, arrayType: ArrayType, _, _) + // if arrayType.elementType.isInstanceOf[StructType] => + // "StructType as element in ArrayType" + // case StructField(_, arrayType: ArrayType, _, _) + // if arrayType.elementType.isInstanceOf[ArrayType] => + // "ArrayType as element in ArrayType" // Parquet scan of nested map with struct as key type, // or array type as value type is not supported in Velox. - case StructField(_, mapType: MapType, _, _) if mapType.keyType.isInstanceOf[StructType] => - "StructType as Key in MapType" - case StructField(_, mapType: MapType, _, _) - if mapType.valueType.isInstanceOf[ArrayType] => - "ArrayType as Value in MapType" + // case StructField(_, mapType: MapType, _, _) if mapType.keyType.isInstanceOf[StructType] => + // "StructType as Key in MapType" + // case StructField(_, mapType: MapType, _, _) + // if mapType.valueType.isInstanceOf[ArrayType] => + // "ArrayType as Value in MapType" case StructField(_, TimestampType, _, _) if GlutenConfig.getConf.forceParquetTimestampTypeScanFallbackEnabled => "TimestampType" } - if (!GlutenConfig.getConf.forceComplexTypeScanFallbackEnabled) { - validateTypes(typeValidator) - } else { - validateTypes(parquetTypeValidatorWithComplexTypeFallback) - } + // if (!GlutenConfig.getConf.forceComplexTypeScanFallbackEnabled) { + validateTypes(typeValidator) + // } else { + // validateTypes(parquetTypeValidatorWithComplexTypeFallback) + // } case DwrfReadFormat => ValidationResult.succeeded case OrcReadFormat => if (!GlutenConfig.getConf.veloxOrcScanEnabled) {