Skip to content

Commit

Permalink
[MINOR][SQL] Locality does not need to be implemented
Browse files Browse the repository at this point in the history
## What changes were proposed in this pull request?
`HadoopFileWholeTextReader` and  `HadoopFileLinesReader` will be eventually called in `FileSourceScanExec`.
In fact,  locality has been implemented in `FileScanRDD`,  even if we implement it in `HadoopFileWholeTextReader ` and  `HadoopFileLinesReader`,  it would be useless.
So I think these `TODO` can be removed.

## How was this patch tested?
N/A

Closes apache#23339 from 10110346/noneededtodo.

Authored-by: liuxian <[email protected]>
Signed-off-by: Wenchen Fan <[email protected]>
  • Loading branch information
10110346 authored and cloud-fan committed Dec 21, 2018
1 parent aa0d4ca commit 98ecda3
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ class HadoopFileLinesReader(
new Path(new URI(file.filePath)),
file.start,
file.length,
// TODO: Implement Locality
// The locality is decided by `getPreferredLocations` in `FileScanRDD`.
Array.empty)
val attemptId = new TaskAttemptID(new TaskID(new JobID(), TaskType.MAP, 0), 0)
val hadoopAttemptContext = new TaskAttemptContextImpl(conf, attemptId)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ class HadoopFileWholeTextReader(file: PartitionedFile, conf: Configuration)
Array(new Path(new URI(file.filePath))),
Array(file.start),
Array(file.length),
// TODO: Implement Locality
// The locality is decided by `getPreferredLocations` in `FileScanRDD`.
Array.empty[String])
val attemptId = new TaskAttemptID(new TaskID(new JobID(), TaskType.MAP, 0), 0)
val hadoopAttemptContext = new TaskAttemptContextImpl(conf, attemptId)
Expand Down

0 comments on commit 98ecda3

Please sign in to comment.