Github user HyukjinKwon commented on a diff in the pull request:

    https://github.com/apache/spark/pull/14960#discussion_r77747258
  
    --- Diff: core/src/main/scala/org/apache/spark/SparkContext.scala ---
    @@ -992,7 +992,7 @@ class SparkContext(config: SparkConf) extends Logging 
with ExecutorAllocationCli
     
         // This is a hack to enforce loading hdfs-site.xml.
         // See SPARK-11227 for details.
    -    FileSystem.get(new URI(path), hadoopConfiguration)
    +    FileSystem.get(new Path(path).toUri, hadoopConfiguration)
    --- End diff --
    
    Hm.. I didn't know it supports comma separated path. BTW, we still can use 
`spark.sparkContext.textFile(..)` though. 
    I took a look and it seems okay though (but it's ugly and hacky).
    
    If the first given path is okay, it seems working fine. It looks only 
`getScheme` and `getAuth` in `FileSystem.get(..)` (I track down the 
`FileSystem.get(..)` and related function calls.)
    
    So, iff the first path is correct, it seems `getAuthority` and `getScheme` 
give a correct ones to get a file system.
    
    For example, the path `http://localhost:8080/a/b,http://localhost:8081/c/d` 
parses the URI as below:
    
    ![2016-09-07 10 19 
11](https://cloud.githubusercontent.com/assets/6477701/18296462/d213126c-74e4-11e6-9859-e68e2d6f58cb.png)



---
If your project is set up for it, you can reply to this email and have your
reply appear on GitHub as well. If your project does not have this feature
enabled and wishes so, or if the feature is enabled but not working, please
contact infrastructure at infrastruct...@apache.org or file a JIRA ticket
with INFRA.
---

---------------------------------------------------------------------
To unsubscribe, e-mail: reviews-unsubscr...@spark.apache.org
For additional commands, e-mail: reviews-h...@spark.apache.org

Reply via email to