You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@spark.apache.org by li...@apache.org on 2016/01/26 03:23:51 UTC

spark git commit: [SPARK-12934] use try-with-resources for streams

Repository: spark
Updated Branches:
  refs/heads/master 109061f7a -> fdcc3512f


[SPARK-12934] use try-with-resources for streams

liancheng please take a look

Author: tedyu <yu...@gmail.com>

Closes #10906 from tedyu/master.


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

Branch: refs/heads/master
Commit: fdcc3512f7b45e5b067fc26cb05146f79c4a5177
Parents: 109061f
Author: tedyu <yu...@gmail.com>
Authored: Mon Jan 25 18:23:47 2016 -0800
Committer: Cheng Lian <li...@databricks.com>
Committed: Mon Jan 25 18:23:47 2016 -0800

----------------------------------------------------------------------
 .../src/main/java/org/apache/spark/util/sketch/CountMinSketch.java | 2 ++
 1 file changed, 2 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/spark/blob/fdcc3512/common/sketch/src/main/java/org/apache/spark/util/sketch/CountMinSketch.java
----------------------------------------------------------------------
diff --git a/common/sketch/src/main/java/org/apache/spark/util/sketch/CountMinSketch.java b/common/sketch/src/main/java/org/apache/spark/util/sketch/CountMinSketch.java
index 6793864..9f4ff42 100644
--- a/common/sketch/src/main/java/org/apache/spark/util/sketch/CountMinSketch.java
+++ b/common/sketch/src/main/java/org/apache/spark/util/sketch/CountMinSketch.java
@@ -128,11 +128,13 @@ abstract public class CountMinSketch {
 
   /**
    * Writes out this {@link CountMinSketch} to an output stream in binary format.
+   * It is the caller's responsibility to close the stream
    */
   public abstract void writeTo(OutputStream out) throws IOException;
 
   /**
    * Reads in a {@link CountMinSketch} from an input stream.
+   * It is the caller's responsibility to close the stream
    */
   public static CountMinSketch readFrom(InputStream in) throws IOException {
     return CountMinSketchImpl.readFrom(in);


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@spark.apache.org
For additional commands, e-mail: commits-help@spark.apache.org