HeartSaVioR commented on pull request #30780:
URL: https://github.com/apache/spark/pull/30780#issuecomment-745814806
I agree this is a good improvement. Thanks!
Regardless of approval of the PR, I wonder your experiment result, though.
`rootPath` is supposed to be just a file, so 17 minutes to get status of the
file sounds really odd.
Could you add log message around lazy val to ensure the experiment is only
affected by your change? Like,
> Before
```
private lazy val status = {
val startNs = System.nanoTime()
val s = fileSystem.getFileStatus(rootPath)
println(s"DEBUG: elapsed = ${System.nanoTime() - startNs} ns")
s
}
```
> After
```
private lazy val status = {
val startNs = System.nanoTime()
val s = maybeStatus.getOrElse(fileSystem.getFileStatus(rootPath))
println(s"DEBUG: elapsed = ${System.nanoTime() - startNs} ns")
s
}
```
Again I'll approve this even the gain is not that significant. Just curious
about the accurate measurement of the change.
----------------------------------------------------------------
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]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]