aboutsummaryrefslogtreecommitdiff
path: root/core
diff options
context:
space:
mode:
authorPatrick Wendell <pwendell@gmail.com>2014-05-08 22:26:17 -0700
committerPatrick Wendell <pwendell@gmail.com>2014-05-08 22:26:36 -0700
commit06b15baab25951d124bbe6b64906f4139e037deb (patch)
tree5d696f3f36535553478418c850882c0325e38af3 /core
parent3f779d872d8459b262b3db9e4d12b011910b6ce9 (diff)
downloadspark-06b15baab25951d124bbe6b64906f4139e037deb.tar.gz
spark-06b15baab25951d124bbe6b64906f4139e037deb.tar.bz2
spark-06b15baab25951d124bbe6b64906f4139e037deb.zip
SPARK-1565 (Addendum): Replace `run-example` with `spark-submit`.
Gives a nicely formatted message to the user when `run-example` is run to tell them to use `spark-submit`. Author: Patrick Wendell <pwendell@gmail.com> Closes #704 from pwendell/examples and squashes the following commits: 1996ee8 [Patrick Wendell] Feedback form Andrew 3eb7803 [Patrick Wendell] Suggestions from TD 2474668 [Patrick Wendell] SPARK-1565 (Addendum): Replace `run-example` with `spark-submit`.
Diffstat (limited to 'core')
-rw-r--r--core/src/main/scala/org/apache/spark/rdd/RDD.scala4
1 files changed, 2 insertions, 2 deletions
diff --git a/core/src/main/scala/org/apache/spark/rdd/RDD.scala b/core/src/main/scala/org/apache/spark/rdd/RDD.scala
index a1ca612cc9..9d8d8044f0 100644
--- a/core/src/main/scala/org/apache/spark/rdd/RDD.scala
+++ b/core/src/main/scala/org/apache/spark/rdd/RDD.scala
@@ -330,9 +330,9 @@ abstract class RDD[T: ClassTag](
if (shuffle) {
// include a shuffle step so that our upstream tasks are still distributed
new CoalescedRDD(
- new ShuffledRDD[T, Null, (T, Null)](map(x => (x, null)),
+ new ShuffledRDD[Int, T, (Int, T)](map(x => (Utils.random.nextInt(), x)),
new HashPartitioner(numPartitions)),
- numPartitions).keys
+ numPartitions).values
} else {
new CoalescedRDD(this, numPartitions)
}