org.apache.jetspeed.cluster
Interface NodeManager


public interface NodeManager

Node Manager Interface

Version:
Author:
Hajo Birthelmer

Field Summary
static int INVALID_NODE_REQUEST
           
static int NODE_NEW
           
static int NODE_OUTDATED
           
static int NODE_SAVED
           
 
Method Summary
 void addNode(java.lang.Long revision, java.lang.String contextName)
          Add a new node or update the revision of an existing one...(i.e.
 int checkNode(java.lang.Long revision, java.lang.String contextName)
          Returns the current "knowledge" about a given node (i.e.
 int getNumberOfNodes()
          return the number of currently stored nodes
 void removeNode(java.lang.String contextName)
          Remove a node
 

Field Detail

INVALID_NODE_REQUEST

static final int INVALID_NODE_REQUEST
See Also:
Constant Field Values

NODE_SAVED

static final int NODE_SAVED
See Also:
Constant Field Values

NODE_OUTDATED

static final int NODE_OUTDATED
See Also:
Constant Field Values

NODE_NEW

static final int NODE_NEW
See Also:
Constant Field Values
Method Detail

checkNode

int checkNode(java.lang.Long revision,
              java.lang.String contextName)
Returns the current "knowledge" about a given node (i.e. the portlet application). If the contextName doesn't exist NODE_NEW is returned. An revision requested newer than what is stored is indicated by NODE_OUTDATED.

Parameters:
revision -
contextName -
Returns:

addNode

void addNode(java.lang.Long revision,
             java.lang.String contextName)
             throws java.lang.Exception
Add a new node or update the revision of an existing one...(i.e. the portlet application) to the local info

Parameters:
revision -
contextName -
Throws:
java.lang.Exception

getNumberOfNodes

int getNumberOfNodes()
return the number of currently stored nodes

Returns:

removeNode

void removeNode(java.lang.String contextName)
                throws java.lang.Exception
Remove a node

Parameters:
id -
contextName -
Throws:
java.lang.Exception


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