Skip to content

Commit

Permalink
changed partitionsRDD in EdgeRDDImpl, VertexRDDImpl to be non-transient
Browse files Browse the repository at this point in the history
  • Loading branch information
jkbradley committed Jan 29, 2015
1 parent cc00767 commit 695b7a3
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ import org.apache.spark.storage.StorageLevel
import org.apache.spark.graphx._

class EdgeRDDImpl[ED: ClassTag, VD: ClassTag] private[graphx] (
@transient override val partitionsRDD: RDD[(PartitionID, EdgePartition[ED, VD])],
override val partitionsRDD: RDD[(PartitionID, EdgePartition[ED, VD])],
val targetStorageLevel: StorageLevel = StorageLevel.MEMORY_ONLY)
extends EdgeRDD[ED](partitionsRDD.context, List(new OneToOneDependency(partitionsRDD))) {

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@ import org.apache.spark.storage.StorageLevel
import org.apache.spark.graphx._

class VertexRDDImpl[VD] private[graphx] (
@transient val partitionsRDD: RDD[ShippableVertexPartition[VD]],
val partitionsRDD: RDD[ShippableVertexPartition[VD]],
val targetStorageLevel: StorageLevel = StorageLevel.MEMORY_ONLY)
(implicit override protected val vdTag: ClassTag[VD])
extends VertexRDD[VD](partitionsRDD.context, List(new OneToOneDependency(partitionsRDD))) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -385,6 +385,8 @@ class GraphSuite extends FunSuite with LocalSparkContext {
val verticesDependencies = graph.vertices.partitionsRDD.dependencies
assert(edgesDependencies.forall(_.rdd.isInstanceOf[CheckpointRDD[_]]))
assert(verticesDependencies.forall(_.rdd.isInstanceOf[CheckpointRDD[_]]))
assert(graph.isCheckpointed)
assert(graph.getCheckpointFiles.size === 2)
}
}

Expand Down

0 comments on commit 695b7a3

Please sign in to comment.