org.apache.giraph
Class TestBspBasic

java.lang.Object
  extended by org.apache.giraph.BspCase
      extended by org.apache.giraph.TestBspBasic
All Implemented Interfaces:
org.apache.zookeeper.Watcher

public class TestBspBasic
extends BspCase

Unit test for many simple BSP applications.


Nested Class Summary
 
Nested classes/interfaces inherited from interface org.apache.zookeeper.Watcher
org.apache.zookeeper.Watcher.Event
 
Field Summary
 
Fields inherited from class org.apache.giraph.BspCase
READER_VERTICES
 
Constructor Summary
TestBspBasic()
           
 
Method Summary
 void testBspCombiner()
          Run a sample BSP job locally with combiner and checkout output value.
 void testBspFail()
          Run a sample BSP job in JobTracker, kill a task, and make sure the job fails (not enough attempts to restart)
 void testBspMasterCompute()
          Run a sample BSP job locally and test MasterCompute.
 void testBspMsg()
          Run a sample BSP job locally and test messages.
 void testBspPageRankWithAggregatorWriter()
          Run a sample BSP job locally and test PageRank with AggregatorWriter.
 void testBspShortestPaths()
          Run a sample BSP job locally and test shortest paths.
 void testBspSuperStep()
          Run a sample BSP job locally and test supersteps.
 void testEmptyVertexInputFormat()
          Run a sample BSP job locally with no vertices and make sure it completes.
 void testInputSplitPathOrganizer()
          Run a test to see if the InputSplitPathOrganizer can correctly sort locality information from a mocked znode of data.
 void testInstantiateNullVertex()
          Test whether vertices with NullWritable for vertex value type, edge value type and message value type can be instantiated.
 void testInstantiateVertex()
          Just instantiate the vertex (all functions are implemented) and the VertexInputFormat using reflection.
 void testLocalJobRunnerConfig()
          Do some checks for local job runner.
 
Methods inherited from class org.apache.giraph.BspCase
getCallingMethodName, getNumResults, getNumWorkers, getSinglePartFileStatus, getTempPath, getZooKeeperList, prepareJob, prepareJob, process, removeAndSetOutput, runningInDistributedMode, setUp, setupConfiguration, tearDown
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TestBspBasic

public TestBspBasic()
Method Detail

testInstantiateVertex

public void testInstantiateVertex()
                           throws InstantiationException,
                                  IllegalAccessException,
                                  IOException,
                                  InterruptedException,
                                  IllegalArgumentException,
                                  InvocationTargetException,
                                  SecurityException,
                                  NoSuchMethodException
Just instantiate the vertex (all functions are implemented) and the VertexInputFormat using reflection.

Throws:
IllegalAccessException
InstantiationException
InterruptedException
IOException
InvocationTargetException
IllegalArgumentException
NoSuchMethodException
SecurityException

testInstantiateNullVertex

public void testInstantiateNullVertex()
                               throws IOException
Test whether vertices with NullWritable for vertex value type, edge value type and message value type can be instantiated.

Throws:
IOException

testLocalJobRunnerConfig

public void testLocalJobRunnerConfig()
                              throws IOException,
                                     InterruptedException,
                                     ClassNotFoundException
Do some checks for local job runner.

Throws:
IOException
ClassNotFoundException
InterruptedException

testBspFail

public void testBspFail()
                 throws IOException,
                        InterruptedException,
                        ClassNotFoundException
Run a sample BSP job in JobTracker, kill a task, and make sure the job fails (not enough attempts to restart)

Throws:
IOException
ClassNotFoundException
InterruptedException

testBspSuperStep

public void testBspSuperStep()
                      throws IOException,
                             InterruptedException,
                             ClassNotFoundException
Run a sample BSP job locally and test supersteps.

Throws:
IOException
ClassNotFoundException
InterruptedException

testBspMsg

public void testBspMsg()
                throws IOException,
                       InterruptedException,
                       ClassNotFoundException
Run a sample BSP job locally and test messages.

Throws:
IOException
ClassNotFoundException
InterruptedException

testEmptyVertexInputFormat

public void testEmptyVertexInputFormat()
                                throws IOException,
                                       InterruptedException,
                                       ClassNotFoundException
Run a sample BSP job locally with no vertices and make sure it completes.

Throws:
IOException
ClassNotFoundException
InterruptedException

testBspCombiner

public void testBspCombiner()
                     throws IOException,
                            InterruptedException,
                            ClassNotFoundException
Run a sample BSP job locally with combiner and checkout output value.

Throws:
IOException
ClassNotFoundException
InterruptedException

testInputSplitPathOrganizer

public void testInputSplitPathOrganizer()
                                 throws IOException,
                                        org.apache.zookeeper.KeeperException,
                                        InterruptedException
Run a test to see if the InputSplitPathOrganizer can correctly sort locality information from a mocked znode of data.

Throws:
IOException
org.apache.zookeeper.KeeperException
InterruptedException

testBspShortestPaths

public void testBspShortestPaths()
                          throws IOException,
                                 InterruptedException,
                                 ClassNotFoundException
Run a sample BSP job locally and test shortest paths.

Throws:
IOException
ClassNotFoundException
InterruptedException

testBspPageRankWithAggregatorWriter

public void testBspPageRankWithAggregatorWriter()
                                         throws IOException,
                                                InterruptedException,
                                                ClassNotFoundException
Run a sample BSP job locally and test PageRank with AggregatorWriter.

Throws:
IOException
ClassNotFoundException
InterruptedException

testBspMasterCompute

public void testBspMasterCompute()
                          throws IOException,
                                 InterruptedException,
                                 ClassNotFoundException
Run a sample BSP job locally and test MasterCompute.

Throws:
IOException
ClassNotFoundException
InterruptedException


Copyright © 2011-2013 The Apache Software Foundation. All Rights Reserved.