Repository: spark
Updated Branches:
  refs/heads/branch-1.2 d1d6de630 -> e0a20994f


[Spark-4432]close InStream after the block is accessed

InStream is not closed after data is read from Tachyon. which makes the blocks 
in Tachyon locked after accessed.

Author: Mingfei <[email protected]>

Closes #3290 from shimingfei/lockFix and squashes the following commits:

fffe345 [Mingfei] close InStream after the block is accessed


Project: http://git-wip-us.apache.org/repos/asf/spark/repo
Commit: http://git-wip-us.apache.org/repos/asf/spark/commit/e0a20994
Tree: http://git-wip-us.apache.org/repos/asf/spark/tree/e0a20994
Diff: http://git-wip-us.apache.org/repos/asf/spark/diff/e0a20994

Branch: refs/heads/branch-1.2
Commit: e0a20994f4deead62b4c038500bb1a98992f9974
Parents: d1d6de6
Author: Mingfei <[email protected]>
Authored: Tue Nov 18 22:17:06 2014 -0800
Committer: Patrick Wendell <[email protected]>
Committed: Tue Nov 18 22:17:35 2014 -0800

----------------------------------------------------------------------
 core/src/main/scala/org/apache/spark/storage/TachyonStore.scala | 2 ++
 1 file changed, 2 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/spark/blob/e0a20994/core/src/main/scala/org/apache/spark/storage/TachyonStore.scala
----------------------------------------------------------------------
diff --git a/core/src/main/scala/org/apache/spark/storage/TachyonStore.scala 
b/core/src/main/scala/org/apache/spark/storage/TachyonStore.scala
index 6dbad5f..233d1e2 100644
--- a/core/src/main/scala/org/apache/spark/storage/TachyonStore.scala
+++ b/core/src/main/scala/org/apache/spark/storage/TachyonStore.scala
@@ -116,6 +116,8 @@ private[spark] class TachyonStore(
       case ioe: IOException =>
         logWarning(s"Failed to fetch the block $blockId from Tachyon", ioe)
         None
+    } finally {
+      is.close()
     }
   }
 


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

Reply via email to