Updated Branches:
  refs/heads/trunk 4a8b5c3f1 -> 4dd605a3a

GIRAPH-749: Update documentation according to the new EdgeOutputFormat API


Project: http://git-wip-us.apache.org/repos/asf/giraph/repo
Commit: http://git-wip-us.apache.org/repos/asf/giraph/commit/0be911bc
Tree: http://git-wip-us.apache.org/repos/asf/giraph/tree/0be911bc
Diff: http://git-wip-us.apache.org/repos/asf/giraph/diff/0be911bc

Branch: refs/heads/trunk
Commit: 0be911bc430d736befce5b3a272be485e835460c
Parents: 4a8b5c3
Author: Claudio Martella <[email protected]>
Authored: Wed Nov 13 01:06:15 2013 +0100
Committer: Claudio Martella <[email protected]>
Committed: Wed Nov 13 01:06:15 2013 +0100

----------------------------------------------------------------------
 src/site/xdoc/io.xml          | 14 +++++++++++++-
 src/site/xdoc/quick_start.xml | 18 ++++++++++++++----
 2 files changed, 27 insertions(+), 5 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/giraph/blob/0be911bc/src/site/xdoc/io.xml
----------------------------------------------------------------------
diff --git a/src/site/xdoc/io.xml b/src/site/xdoc/io.xml
index 38c74e0..6276de1 100644
--- a/src/site/xdoc/io.xml
+++ b/src/site/xdoc/io.xml
@@ -48,7 +48,7 @@
         To summarize, <code>VertexInputFormat</code> is usually used by 
itself, whereas <code>EdgeInputFormat</code> may be used in combination with 
<code>VertexValueInputFormat</code>.
       </p>
       <p>
-        Output is always done on a per-vertex basis: a 
<code>VertexOutputFormat</code> will specify what data to write for each 
vertex. This usually means (some function of) the vertex value, but nothing 
prevents us from writing back the edges instead.
+        Output can be done both on a per-vertex and a per-edge basis: a 
<code>VertexOutputFormat</code> will specify what data to write for each vertex 
while <code>EdgeOutputFormat</code> will specify what data to write for each 
edge. This usually means (some function of) the vertex value, but nothing 
prevents us from writing back the edges instead.
       </p>
       <p>
         Let's have a quick look at the base classes:
@@ -71,6 +71,18 @@
           <li>
             <code>EdgeReader&lt;I, E&gt;</code>: the main methods are 
<code>getCurrentSourceId()</code>, which returns the source vertex id, and 
<code>getCurrentEdge()</code>, which returns an <code>Edge&lt;I, E&gt;</code> 
(i.e., the target vertex id, possibly with an edge value).
           </li>
+          <li>
+            <code>VertexOutputFormat&lt;I, V, E&gt;</code>: modeled based on 
the Hadoop <code>OutputFormat</code> class, this class is intended for output 
vertices and related edges after the computation. The 
<code>createVertexWriter</code> returns a <code>VertexWriter</code> to save the 
vertices. Additionally <code>getOutputCommiter</code> returns an 
<code>OutputCommiter</code> used to guarantee that the output process is 
correctly committed and <code>checkOutputSpecs</code> is used to check that the 
correct setup before running the computation.
+          </li>
+          <li>
+            <code>VertexWriter&lt;I, V, E&gt;</code>: this is where the user 
defines how to write vertices and possibly edges. The infrastructure just 
provides an <code>initialize</code> and a <code>close</code> method to deal 
with the initial and final part of the output. It also inherits 
<code>SimpleVertexWriter#writeVertex</code> which is the main function used to 
actually save the vertices.
+          </li>
+          <li>
+            <code>EdgeOutputFormat&lt;I, V, E&gt;</code>: modeled similar to 
<code>VertexOutputFormat</code>, this class is intended for output edges after 
the computation. The <code>createEdgeWriter</code> returns a 
<code>EdgeWriter</code> to save the edges. Additionally 
<code>getOutputCommiter</code> returns an <code>OutputCommiter</code> used to 
guarantee that the output process is correctly committed and 
<code>checkOutputSpecs</code> is used to check that the correct setup before 
running the computation.
+          </li>
+          <li>
+            <code>EdgeWriter&lt;I, V, E&gt;</code>: this class is similar to 
<code>VertexWriter</code> providing initialization and closing facilities. It 
is inteded to save edges and the main function that needs to be extended by the 
user for such purpose is <code>writeEdge</code>.
+          </li>
         </ul>
       </p>
     </section>

http://git-wip-us.apache.org/repos/asf/giraph/blob/0be911bc/src/site/xdoc/quick_start.xml
----------------------------------------------------------------------
diff --git a/src/site/xdoc/quick_start.xml b/src/site/xdoc/quick_start.xml
index d704cba..cdef668 100644
--- a/src/site/xdoc/quick_start.xml
+++ b/src/site/xdoc/quick_start.xml
@@ -218,9 +218,10 @@ $HADOOP_HOME/bin/hadoop jar 
$GIRAPH_HOME/giraph-examples/target/giraph-examples-
       <p>This will output the following:</p>
       <source>
 usage: org.apache.giraph.utils.ConfigurationUtils [-aw &lt;arg&gt;] [-c 
&lt;arg&gt;]
-       [-ca &lt;arg&gt;] [-cf &lt;arg&gt;] [-eif &lt;arg&gt;] [-eip 
&lt;arg&gt;] [-h] [-la] [-mc
-       &lt;arg&gt;] [-vof &lt;arg&gt;] [-op &lt;arg&gt;] [-pc &lt;arg&gt;] 
[-q] [-ve &lt;arg&gt;] [-vif
-       &lt;arg&gt;] [-vip &lt;arg&gt;] [-vvf &lt;arg&gt;] [-w &lt;arg&gt;] 
[-wc &lt;arg&gt;] [-yh &lt;arg&gt;]
+       [-ca &lt;arg&gt;] [-cf &lt;arg&gt;] [-eif &lt;arg&gt;] [-eip 
&lt;arg&gt;] [-eof &lt;arg&gt;]
+       [-esd &lt;arg&gt;] [-h] [-jyc &lt;arg&gt;] [-la] [-mc &lt;arg&gt;] [-op 
&lt;arg&gt;] [-pc
+       &lt;arg&gt;] [-q] [-th &lt;arg&gt;] [-ve &lt;arg&gt;] [-vif 
&lt;arg&gt;] [-vip &lt;arg&gt;] [-vof
+       &lt;arg&gt;] [-vsd &lt;arg&gt;] [-vvf &lt;arg&gt;] [-w &lt;arg&gt;] 
[-wc &lt;arg&gt;] [-yh &lt;arg&gt;]
        [-yj &lt;arg&gt;]
  -aw,--aggregatorWriter &lt;arg&gt;           AggregatorWriter class
  -c,--messageCombiner &lt;arg&gt;             Message messageCombiner class
@@ -234,16 +235,25 @@ usage: org.apache.giraph.utils.ConfigurationUtils [-aw 
&lt;arg&gt;] [-c &lt;arg&
  -eif,--edgeInputFormat &lt;arg&gt;           Edge input format
  -eip,--edgeInputPath &lt;arg&gt;             Edge input path
  -eof,--vertexOutputFormat &lt;arg&gt;               Edge output format
+ -esd,--edgeSubDir &lt;arg&gt;                subdirectory to be used for the
+                                        edge output
  -h,--help                              Help
+ -jyc,--jythonClass &lt;arg&gt;               Jython class name, used if
+                                        computation passed in is a python
+                                        script
  -la,--listAlgorithms                   List supported algorithms
  -mc,--masterCompute &lt;arg&gt;              MasterCompute class
- -vof,--vertexOutputFormat &lt;arg&gt;               Vertex output format
  -op,--outputPath &lt;arg&gt;                 Vertex output path
  -pc,--partitionClass &lt;arg&gt;             Partition class
  -q,--quiet                             Quiet output
+ -th,--typesHolder &lt;arg&gt;                Class that holds types. Needed
+                                        only if Computation is not set
  -ve,--outEdges &lt;arg&gt;                   Vertex edges class
  -vif,--vertexInputFormat &lt;arg&gt;         Vertex input format
  -vip,--vertexInputPath &lt;arg&gt;           Vertex input path
+ -vof,--vertexOutputFormat &lt;arg&gt;        Vertex output format
+ -vsd,--vertexSubDir &lt;arg&gt;              subdirectory to be used for the
+                                        vertex output
  -vvf,--vertexValueFactoryClass &lt;arg&gt;   Vertex value factory class
  -w,--workers &lt;arg&gt;                     Number of workers
  -wc,--workerContext &lt;arg&gt;              WorkerContext class

Reply via email to