incubator-giraph-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From clau...@apache.org
Subject svn commit: r1228691 - in /incubator/giraph/trunk: ./ src/main/java/org/apache/giraph/graph/
Date Sat, 07 Jan 2012 18:10:08 GMT
Author: claudio
Date: Sat Jan  7 18:10:07 2012
New Revision: 1228691

URL: http://svn.apache.org/viewvc?rev=1228691&view=rev
Log:
GIRAPH-118: Clarify messages behavior in BasicVertex

Modified:
    incubator/giraph/trunk/CHANGELOG
    incubator/giraph/trunk/src/main/java/org/apache/giraph/graph/BasicVertex.java
    incubator/giraph/trunk/src/main/java/org/apache/giraph/graph/BspServiceWorker.java
    incubator/giraph/trunk/src/main/java/org/apache/giraph/graph/EdgeListVertex.java
    incubator/giraph/trunk/src/main/java/org/apache/giraph/graph/HashMapVertex.java
    incubator/giraph/trunk/src/main/java/org/apache/giraph/graph/IntIntNullIntVertex.java
    incubator/giraph/trunk/src/main/java/org/apache/giraph/graph/LongDoubleFloatDoubleVertex.java

Modified: incubator/giraph/trunk/CHANGELOG
URL: http://svn.apache.org/viewvc/incubator/giraph/trunk/CHANGELOG?rev=1228691&r1=1228690&r2=1228691&view=diff
==============================================================================
--- incubator/giraph/trunk/CHANGELOG (original)
+++ incubator/giraph/trunk/CHANGELOG Sat Jan  7 18:10:07 2012
@@ -2,6 +2,8 @@ Giraph Change Log
 
 Release 0.70.0 - unreleased
 
+  GIRAPH-118: Clarify messages behavior in BasicVertex (claudio)
+
   GIRAPH-119: VertexCombiner should work on Iterable<M> instead of 
   List<M>. (claudio)
 

Modified: incubator/giraph/trunk/src/main/java/org/apache/giraph/graph/BasicVertex.java
URL: http://svn.apache.org/viewvc/incubator/giraph/trunk/src/main/java/org/apache/giraph/graph/BasicVertex.java?rev=1228691&r1=1228690&r2=1228691&view=diff
==============================================================================
--- incubator/giraph/trunk/src/main/java/org/apache/giraph/graph/BasicVertex.java (original)
+++ incubator/giraph/trunk/src/main/java/org/apache/giraph/graph/BasicVertex.java Sat Jan
 7 18:10:07 2012
@@ -188,21 +188,22 @@ public abstract class BasicVertex<I exte
         return halt;
     }
 
-     /**
-      *  Get the list of incoming messages from the previous superstep.  Same as
-      *  the message iterator passed to compute().
-      */
+    /**
+     *  Get the list of incoming messages from the previous superstep.  Same as
+     *  the message iterator passed to compute().
+     */
     public abstract Iterable<M> getMessages();
 
     /**
-     * Set the messages this vertex should process in the current superstep
+     * Copy the messages this vertex should process in the current superstep
      *
      * @param messages the messages sent to this vertex in the previous superstep
      */
-    abstract void setMessages(Iterable<M> messages);
+    abstract void putMessages(Iterable<M> messages);
 
     /**
-     * Release unnecessary resources (will be called after vertex chose to halt)
+     * Release unnecessary resources (will be called after vertex returns from
+     * {@link #compute()})
      */
     abstract void releaseResources();
 

Modified: incubator/giraph/trunk/src/main/java/org/apache/giraph/graph/BspServiceWorker.java
URL: http://svn.apache.org/viewvc/incubator/giraph/trunk/src/main/java/org/apache/giraph/graph/BspServiceWorker.java?rev=1228691&r1=1228690&r2=1228691&view=diff
==============================================================================
--- incubator/giraph/trunk/src/main/java/org/apache/giraph/graph/BspServiceWorker.java (original)
+++ incubator/giraph/trunk/src/main/java/org/apache/giraph/graph/BspServiceWorker.java Sat
Jan  7 18:10:07 2012
@@ -502,7 +502,7 @@ public class BspServiceWorker<
     @Override
     public void assignMessagesToVertex(BasicVertex<I, V, E, M> vertex,
             Iterable<M> messageIterator) {
-        vertex.setMessages(messageIterator);
+        vertex.putMessages(messageIterator);
     }
 
     @Override

Modified: incubator/giraph/trunk/src/main/java/org/apache/giraph/graph/EdgeListVertex.java
URL: http://svn.apache.org/viewvc/incubator/giraph/trunk/src/main/java/org/apache/giraph/graph/EdgeListVertex.java?rev=1228691&r1=1228690&r2=1228691&view=diff
==============================================================================
--- incubator/giraph/trunk/src/main/java/org/apache/giraph/graph/EdgeListVertex.java (original)
+++ incubator/giraph/trunk/src/main/java/org/apache/giraph/graph/EdgeListVertex.java Sat Jan
 7 18:10:07 2012
@@ -285,7 +285,7 @@ public abstract class EdgeListVertex<I e
     }
 
     @Override
-    void setMessages(Iterable<M> messages) {
+    void putMessages(Iterable<M> messages) {
         msgList.clear();
         for (M message : messages) {
             msgList.add(message);

Modified: incubator/giraph/trunk/src/main/java/org/apache/giraph/graph/HashMapVertex.java
URL: http://svn.apache.org/viewvc/incubator/giraph/trunk/src/main/java/org/apache/giraph/graph/HashMapVertex.java?rev=1228691&r1=1228690&r2=1228691&view=diff
==============================================================================
--- incubator/giraph/trunk/src/main/java/org/apache/giraph/graph/HashMapVertex.java (original)
+++ incubator/giraph/trunk/src/main/java/org/apache/giraph/graph/HashMapVertex.java Sat Jan
 7 18:10:07 2012
@@ -216,7 +216,7 @@ public abstract class HashMapVertex<I ex
     }
 
     @Override
-    void setMessages(Iterable<M> messages) {
+    void putMessages(Iterable<M> messages) {
         msgList.clear();
         for (M message : messages) {
             msgList.add(message);

Modified: incubator/giraph/trunk/src/main/java/org/apache/giraph/graph/IntIntNullIntVertex.java
URL: http://svn.apache.org/viewvc/incubator/giraph/trunk/src/main/java/org/apache/giraph/graph/IntIntNullIntVertex.java?rev=1228691&r1=1228690&r2=1228691&view=diff
==============================================================================
--- incubator/giraph/trunk/src/main/java/org/apache/giraph/graph/IntIntNullIntVertex.java
(original)
+++ incubator/giraph/trunk/src/main/java/org/apache/giraph/graph/IntIntNullIntVertex.java
Sat Jan  7 18:10:07 2012
@@ -118,7 +118,7 @@ public abstract class IntIntNullIntVerte
     }
 
     @Override
-    public void setMessages(Iterable<IntWritable> newMessages) {
+    public void putMessages(Iterable<IntWritable> newMessages) {
         messages = new int[Iterables.size(newMessages)];
         int n = 0;
         for (IntWritable message : newMessages) {

Modified: incubator/giraph/trunk/src/main/java/org/apache/giraph/graph/LongDoubleFloatDoubleVertex.java
URL: http://svn.apache.org/viewvc/incubator/giraph/trunk/src/main/java/org/apache/giraph/graph/LongDoubleFloatDoubleVertex.java?rev=1228691&r1=1228690&r2=1228691&view=diff
==============================================================================
--- incubator/giraph/trunk/src/main/java/org/apache/giraph/graph/LongDoubleFloatDoubleVertex.java
(original)
+++ incubator/giraph/trunk/src/main/java/org/apache/giraph/graph/LongDoubleFloatDoubleVertex.java
Sat Jan  7 18:10:07 2012
@@ -251,7 +251,7 @@ public abstract class LongDoubleFloatDou
     }
 
     @Override
-    void setMessages(Iterable<DoubleWritable> messages) {
+    void putMessages(Iterable<DoubleWritable> messages) {
         messageList.clear();
         for (DoubleWritable message : messages) {
             messageList.add(message.get());



Mime
View raw message