Rice Pastry API

rice.p2p.past.testing
Class RawPastRegrTest

java.lang.Object
  extended byrice.p2p.commonapi.testing.CommonAPITest
      extended byrice.p2p.past.testing.RawPastRegrTest

public class RawPastRegrTest
extends CommonAPITest

Version:
$Id: PastRegrTest.java 3157 2006-03-19 12:16:58Z jeffh $
Author:
Alan Mislove

Nested Class Summary
protected static class RawPastRegrTest.NonMutableTestPastContent
          DESCRIBE THE CLASS
protected static class RawPastRegrTest.NonOverwritingTestPastContent
          DESCRIBE THE CLASS
protected  class RawPastRegrTest.TestCommand
          Common superclass for test commands.
protected  class RawPastRegrTest.TestExceptionCommand
          Common superclass for test commands which should throw an exception
protected static class RawPastRegrTest.TestPastContent
          Utility class for past content objects
protected static class RawPastRegrTest.TestPastContentHandle
          Utility class for past content object handles
protected static class RawPastRegrTest.TestRouteMessage
          Utility class which simulates a route message
protected static class RawPastRegrTest.VersionedTestPastContent
          DESCRIBE THE CLASS
 
Field Summary
static java.lang.String INSTANCE
          DESCRIBE THE FIELD
protected  PastImpl[] pasts
          DESCRIBE THE FIELD
static int REPLICATION_FACTOR
          DESCRIBE THE FIELD
protected  boolean running
          DESCRIBE THE FIELD
protected  StorageManager[] storages
          DESCRIBE THE FIELD
 
Fields inherited from class rice.p2p.commonapi.testing.CommonAPITest
BOOTSTRAP, BOOTSTRAP_PORT, environment, factory, FACTORY, FAILURE, idFactory, INSTANCE_NAME, logger, nodes, NUM_NODES, PAD_SIZE, params, PORT, PROTOCOL, PROTOCOL_DIRECT, simulator, SIMULATOR, SIMULATOR_EUCLIDEAN, SIMULATOR_GT_ITM, SIMULATOR_SPHERE, SUCCESS
 
Constructor Summary
RawPastRegrTest(Environment env)
          Constructor which sets up all local variables
 
Method Summary
protected  void cleanUp()
          DESCRIBE THE METHOD
static void main(java.lang.String[] args)
          Usage: DistPastTest [-port p] [-bootstrap host[:port]] [-nodes n] [-protocol (direct|socket)] [-help]
protected  void processNode(int num, Node node)
          Method which should process the given newly-created node
protected  void runTest()
          Method which should run the test - this is called once all of the nodes have been created and are ready.
protected  void testCaching()
          Tests the dynamic caching function in Past.
protected  void testFetch()
          Tests the fetch function in Past.
protected  void testLookupHandles()
          Tests the lookup handles function in Past.
protected  void testRouteRequest()
          Tests routing a Past request to a particular node.
protected  void testVersionControl()
          Tests overwriting an exiting object with a new one
 
Methods inherited from class rice.p2p.commonapi.testing.CommonAPITest
assertEquals, assertTrue, createNode, createNodes, getBootstrap, kill, parseArgs, pause, sectionDone, sectionStart, simulate, start, stepDone, stepDone, stepDone, stepException, stepStart
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

storages

protected StorageManager[] storages
DESCRIBE THE FIELD


pasts

protected PastImpl[] pasts
DESCRIBE THE FIELD


running

protected boolean running
DESCRIBE THE FIELD


INSTANCE

public static java.lang.String INSTANCE
DESCRIBE THE FIELD


REPLICATION_FACTOR

public static int REPLICATION_FACTOR
DESCRIBE THE FIELD

Constructor Detail

RawPastRegrTest

public RawPastRegrTest(Environment env)
                throws java.io.IOException
Constructor which sets up all local variables

Parameters:
env - DESCRIBE THE PARAMETER
Throws:
java.io.IOException - DESCRIBE THE EXCEPTION
Method Detail

processNode

protected void processNode(int num,
                           Node node)
Method which should process the given newly-created node

Specified by:
processNode in class CommonAPITest
Parameters:
node - The newly created node
num - The number of this node

runTest

protected void runTest()
Method which should run the test - this is called once all of the nodes have been created and are ready.

Specified by:
runTest in class CommonAPITest

testRouteRequest

protected void testRouteRequest()
Tests routing a Past request to a particular node.


testVersionControl

protected void testVersionControl()
Tests overwriting an exiting object with a new one


testFetch

protected void testFetch()
Tests the fetch function in Past.


testLookupHandles

protected void testLookupHandles()
Tests the lookup handles function in Past.


testCaching

protected void testCaching()
Tests the dynamic caching function in Past.


cleanUp

protected void cleanUp()
DESCRIBE THE METHOD


main

public static void main(java.lang.String[] args)
                 throws java.lang.Exception
Usage: DistPastTest [-port p] [-bootstrap host[:port]] [-nodes n] [-protocol (direct|socket)] [-help]

Parameters:
args - DESCRIBE THE PARAMETER
Throws:
java.lang.Exception - DESCRIBE THE EXCEPTION

Rice Pastry API

Copyright © 2001-2005 - Rice Pastry.


Imprint-Dataprotection