GitHub user gengliangwang opened a pull request: https://github.com/apache/spark/pull/21873
[SPARK-24919][BUILD] New linter rule for sparkContext.hadoopConfiguration ## What changes were proposed in this pull request? In most cases, we should use `spark.sessionState.newHadoopConf()` instead of `sparkContext.hadoopConfiguration`, so that the hadoop configurations specified in Spark session configuration will come into effect. Add a rule matching `spark.sparkContext.hadoopConfiguration` or `spark.sqlContext.sparkContext.hadoopConfiguration` to prevent the usage. ## How was this patch tested? Unit test You can merge this pull request into a Git repository by running: $ git pull https://github.com/gengliangwang/spark linterRule Alternatively you can review and apply these changes as the patch at: https://github.com/apache/spark/pull/21873.patch To close this pull request, make a commit to your master/trunk branch with (at least) the following in the commit message: This closes #21873 ---- commit 8b5ad70c472ea4931dfd352b28044dd26bbed2a1 Author: Gengliang Wang <gengliang.wang@...> Date: 2018-07-25T11:59:36Z new linter rule for spark.sparkContext.hadoopConfiguration ---- --- --------------------------------------------------------------------- To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org For additional commands, e-mail: reviews-h...@spark.apache.org