spark-reviews mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From srowen <>
Subject [GitHub] spark pull request: Getting absloute path instead of relative path...
Date Fri, 25 Apr 2014 05:21:03 GMT
Github user srowen commented on a diff in the pull request:
    --- Diff: core/src/main/scala/org/apache/spark/broadcast/HttpBroadcast.scala ---
    @@ -213,7 +213,7 @@ private[spark] object HttpBroadcast extends Logging {
         SparkEnv.get.blockManager.master.removeBroadcast(id, removeFromDriver, blocking)
         if (removeFromDriver) {
           val file = getFile(id)
    -      files.remove(file.toString)
    +      files.remove(file.getCanonicalPath)
    --- End diff --
    Hmm and also note that the file names are added using the value of `getAbsolutePath()`.
If its absolute path were not-canonicalized it would not work. 
    Why not just have `File` objects in the set `files`? They implement the desired `equals()`

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 or file a JIRA ticket
with INFRA.

View raw message