dongjoon-hyun commented on a change in pull request #24203: [SPARK-27269][SQL]
File source v2 should validate data schema only
URL: https://github.com/apache/spark/pull/24203#discussion_r268953505
##########
File path:
sql/core/src/main/scala/org/apache/spark/sql/execution/datasources/v2/orc/OrcDataSourceV2.scala
##########
@@ -42,19 +42,3 @@ class OrcDataSourceV2 extends FileDataSourceV2 {
}
}
-object OrcDataSourceV2 {
- def supportsDataType(dataType: DataType): Boolean = dataType match {
- case _: AtomicType => true
-
- case st: StructType => st.forall { f => supportsDataType(f.dataType) }
-
- case ArrayType(elementType, _) => supportsDataType(elementType)
-
- case MapType(keyType, valueType, _) =>
- supportsDataType(keyType) && supportsDataType(valueType)
-
- case udt: UserDefinedType[_] => supportsDataType(udt.sqlType)
-
- case _ => false
- }
-}
Review comment:
ditto.
```
-import org.apache.spark.sql.types._
+import org.apache.spark.sql.types.StructType
```
----------------------------------------------------------------
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.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]