Github user szhem commented on the issue:

    https://github.com/apache/spark/pull/19294
  
    @gatorsmile I believe that in Spark SQL code path `path` cannot be null, 
because in that case `FileFormatWriter` [fails even 
before](https://github.com/apache/spark/blob/3f958a99921d149fb9fdf7ba7e78957afdad1405/sql/core/src/main/scala/org/apache/spark/sql/execution/datasources/FileFormatWriter.scala#L118)
 `setupJob` ([which in its order calls 
setupCommitter](https://github.com/apache/spark/blob/e47f48c737052564e92903de16ff16707fae32c3/core/src/main/scala/org/apache/spark/internal/io/HadoopMapReduceCommitProtocol.scala#L124))
 on the committer is called.
    
    The interesting part is that the [FileOutputCommitter allows null output 
paths](https://github.com/apache/hadoop/blob/5af572b6443715b7a741296c1bd520a1840f9a7c/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapreduce/lib/output/FileOutputCommitter.java#L96)
 and the line you highlighted is executed only in that case.


---

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to