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/26 00:35:10 UTC
incubator-tinkerpop git commit: no incoming message should be
available once the step has executed.
Repository: incubator-tinkerpop
Updated Branches:
refs/heads/master 74123046b -> 8375104d8
no incoming message should be available once the step has executed.
Project: http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/commit/8375104d
Tree: http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/tree/8375104d
Diff: http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/diff/8375104d
Branch: refs/heads/master
Commit: 8375104d8619d0fa1301a2aba18d5e8551523ecd
Parents: 7412304
Author: Marko A. Rodriguez <ok...@gmail.com>
Authored: Wed Mar 25 17:35:06 2015 -0600
Committer: Marko A. Rodriguez <ok...@gmail.com>
Committed: Wed Mar 25 17:35:06 2015 -0600
----------------------------------------------------------------------
.../gremlin/hadoop/process/computer/spark/util/SparkHelper.java | 3 ++-
1 file changed, 2 insertions(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-tinkerpop/blob/8375104d/hadoop-gremlin/src/main/java/org/apache/tinkerpop/gremlin/hadoop/process/computer/spark/util/SparkHelper.java
----------------------------------------------------------------------
diff --git a/hadoop-gremlin/src/main/java/org/apache/tinkerpop/gremlin/hadoop/process/computer/spark/util/SparkHelper.java b/hadoop-gremlin/src/main/java/org/apache/tinkerpop/gremlin/hadoop/process/computer/spark/util/SparkHelper.java
index f928172..cbccc58 100644
--- a/hadoop-gremlin/src/main/java/org/apache/tinkerpop/gremlin/hadoop/process/computer/spark/util/SparkHelper.java
+++ b/hadoop-gremlin/src/main/java/org/apache/tinkerpop/gremlin/hadoop/process/computer/spark/util/SparkHelper.java
@@ -74,9 +74,10 @@ public final class SparkHelper {
// emit messages by appending them to the graph as message payloads
current = current.<Object, SparkPayload<M>>flatMapToPair(keyValue -> {
+ keyValue._2().asVertexPayload().getMessages().clear(); // there should be no incoming messages at this point
final List<Tuple2<Object, SparkPayload<M>>> list = new ArrayList<>();
list.add(keyValue); // this is a vertex
- keyValue._2().asVertexPayload().getOutgoingMessages().forEach(message -> list.add(new Tuple2<>(message._1(), new SparkMessagePayload<>((M) message._2())))); // this is a message
+ keyValue._2().asVertexPayload().getOutgoingMessages().forEach(message -> list.add(new Tuple2<>(message._1(), new SparkMessagePayload<>(message._2())))); // this is a message
return list;
});