You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@tinkerpop.apache.org by ok...@apache.org on 2015/03/30 21:07:10 UTC

incubator-tinkerpop git commit: testing the use of mid-iteration caching on Spark consistency.

Repository: incubator-tinkerpop
Updated Branches:
  refs/heads/master ce5a16990 -> c5d69a17c


testing the use of mid-iteration caching on Spark consistency.


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

Branch: refs/heads/master
Commit: c5d69a17cf027089a8b96f59b580d5fff3b53f37
Parents: ce5a169
Author: Marko A. Rodriguez <ok...@gmail.com>
Authored: Mon Mar 30 13:07:07 2015 -0600
Committer: Marko A. Rodriguez <ok...@gmail.com>
Committed: Mon Mar 30 13:07:07 2015 -0600

----------------------------------------------------------------------
 .../hadoop/process/computer/spark/SparkGraphComputer.java        | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/blob/c5d69a17/hadoop-gremlin/src/main/java/org/apache/tinkerpop/gremlin/hadoop/process/computer/spark/SparkGraphComputer.java
----------------------------------------------------------------------
diff --git a/hadoop-gremlin/src/main/java/org/apache/tinkerpop/gremlin/hadoop/process/computer/spark/SparkGraphComputer.java b/hadoop-gremlin/src/main/java/org/apache/tinkerpop/gremlin/hadoop/process/computer/spark/SparkGraphComputer.java
index f7f5929..9ee22cc 100644
--- a/hadoop-gremlin/src/main/java/org/apache/tinkerpop/gremlin/hadoop/process/computer/spark/SparkGraphComputer.java
+++ b/hadoop-gremlin/src/main/java/org/apache/tinkerpop/gremlin/hadoop/process/computer/spark/SparkGraphComputer.java
@@ -182,7 +182,7 @@ public final class SparkGraphComputer implements GraphComputer {
                             // execute the vertex program
                             while (true) {
                                 memory.setInTask(true);
-                                graphRDD = SparkExecutor.executeVertexProgramIteration(graphRDD, memory, vertexProgramConfiguration);
+                                graphRDD = SparkExecutor.executeVertexProgramIteration(graphRDD, memory, vertexProgramConfiguration).cache();
                                 memory.setInTask(false);
                                 if (this.vertexProgram.terminate(memory))
                                     break;
@@ -208,7 +208,7 @@ public final class SparkGraphComputer implements GraphComputer {
                                 vertex.getOutgoingMessages().clear();
                                 vertex.getVertex().edges(Direction.BOTH).forEachRemaining(Edge::remove);
                                 return vertex;
-                            });   // todo: cache()?
+                            }).cache();
                             for (final MapReduce mapReduce : this.mapReducers) {
                                 // execute the map reduce job
                                 final HadoopConfiguration newApacheConfiguration = new HadoopConfiguration(apacheConfiguration);