Skip to content

Commit 7e29e02

Browse files
mengxrrxin
authored andcommitted
Merge pull request apache#591 from mengxr/transient-new.
SPARK-1076: [Fix apache#578] add @transient to some vals I'll try to be more careful next time. Author: Xiangrui Meng <[email protected]> Closes apache#591 and squashes the following commits: 2b4f044 [Xiangrui Meng] add @transient to prev in ZippedWithIndexRDD add @transient to seed in PartitionwiseSampledRDD
1 parent 2bea070 commit 7e29e02

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

core/src/main/scala/org/apache/spark/rdd/PartitionwiseSampledRDD.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ class PartitionwiseSampledRDDPartition(val prev: Partition, val seed: Long)
4545
class PartitionwiseSampledRDD[T: ClassTag, U: ClassTag](
4646
prev: RDD[T],
4747
sampler: RandomSampler[T, U],
48-
seed: Long = System.nanoTime)
48+
@transient seed: Long = System.nanoTime)
4949
extends RDD[U](prev) {
5050

5151
override def getPartitions: Array[Partition] = {

core/src/main/scala/org/apache/spark/rdd/ZippedWithIndexRDD.scala

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -37,7 +37,7 @@ class ZippedWithIndexRDDPartition(val prev: Partition, val startIndex: Long)
3737
* @tparam T parent RDD item type
3838
*/
3939
private[spark]
40-
class ZippedWithIndexRDD[T: ClassTag](prev: RDD[T]) extends RDD[(T, Long)](prev) {
40+
class ZippedWithIndexRDD[T: ClassTag](@transient prev: RDD[T]) extends RDD[(T, Long)](prev) {
4141

4242
override def getPartitions: Array[Partition] = {
4343
val n = prev.partitions.size

0 commit comments

Comments
 (0)