aboutsummaryrefslogtreecommitdiff
path: root/examples/src
diff options
context:
space:
mode:
authorLiwei Lin <lwlin7@gmail.com>2016-06-02 11:07:15 -0500
committerSean Owen <sowen@cloudera.com>2016-06-02 11:07:15 -0500
commita0eec8e8ffd5a43cae67aa0f5dbcf7ca19a4f3aa (patch)
treeade45af40121ff673c5f44c1632e55e851815ee8 /examples/src
parent5eea332307cbed5fc44427959f070afc16a12c02 (diff)
downloadspark-a0eec8e8ffd5a43cae67aa0f5dbcf7ca19a4f3aa.tar.gz
spark-a0eec8e8ffd5a43cae67aa0f5dbcf7ca19a4f3aa.tar.bz2
spark-a0eec8e8ffd5a43cae67aa0f5dbcf7ca19a4f3aa.zip
[SPARK-15208][WIP][CORE][STREAMING][DOCS] Update Spark examples with AccumulatorV2
## What changes were proposed in this pull request? The patch updates the codes & docs in the example module as well as the related doc module: - [ ] [docs] `streaming-programming-guide.md` - [x] scala code part - [ ] java code part - [ ] python code part - [x] [examples] `RecoverableNetworkWordCount.scala` - [ ] [examples] `JavaRecoverableNetworkWordCount.java` - [ ] [examples] `recoverable_network_wordcount.py` ## How was this patch tested? Ran the examples and verified results manually. Author: Liwei Lin <lwlin7@gmail.com> Closes #12981 from lw-lin/accumulatorV2-examples.
Diffstat (limited to 'examples/src')
-rw-r--r--examples/src/main/scala/org/apache/spark/examples/streaming/RecoverableNetworkWordCount.scala3
1 files changed, 1 insertions, 2 deletions
diff --git a/examples/src/main/scala/org/apache/spark/examples/streaming/RecoverableNetworkWordCount.scala b/examples/src/main/scala/org/apache/spark/examples/streaming/RecoverableNetworkWordCount.scala
index acbcb0c4b7..49c0427321 100644
--- a/examples/src/main/scala/org/apache/spark/examples/streaming/RecoverableNetworkWordCount.scala
+++ b/examples/src/main/scala/org/apache/spark/examples/streaming/RecoverableNetworkWordCount.scala
@@ -27,8 +27,7 @@ import org.apache.spark.{SparkConf, SparkContext}
import org.apache.spark.broadcast.Broadcast
import org.apache.spark.rdd.RDD
import org.apache.spark.streaming.{Seconds, StreamingContext, Time}
-import org.apache.spark.util.IntParam
-import org.apache.spark.util.LongAccumulator
+import org.apache.spark.util.{IntParam, LongAccumulator}
/**
* Use this singleton to get or register a Broadcast variable.