Skip to content
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Next Next commit
[SPARK-14557][SQL] Reading textfile (created though CTAS) doesn't wor…
…k when

pathFilter is enabled.
1) A bug in HadoopFileReader. Resolved by passing the directory instead
of a list of files in case of pathFilter also, since it gets triggerred in
FileInputFormat. This also saves multiple filterings in the codePath.
2) Not using the applyFilterIfApplicable
  • Loading branch information
kasjain committed Apr 13, 2016
commit 48a598efe78ef1c9560a6af2d74e98b3bfaa8819
Original file line number Diff line number Diff line change
Expand Up @@ -108,7 +108,7 @@ class HadoopTableReader(
val broadcastedHiveConf = _broadcastedHiveConf

val tablePath = hiveTable.getPath
val inputPathStr = applyFilterIfNeeded(tablePath, filterOpt)
val inputPathStr = tablePath.toString

// logDebug("Table input: %s".format(tablePath))
val ifc = hiveTable.getInputFormatClass
Expand Down Expand Up @@ -190,7 +190,7 @@ class HadoopTableReader(
.map { case (partition, partDeserializer) =>
val partDesc = Utilities.getPartitionDesc(partition)
val partPath = partition.getDataLocation
val inputPathStr = applyFilterIfNeeded(partPath, filterOpt)
val inputPathStr = partPath.toString
val ifc = partDesc.getInputFileFormatClass
.asInstanceOf[java.lang.Class[InputFormat[Writable, Writable]]]
// Get partition field info
Expand Down