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(Long id, String contextName)
          Add a new node or update the id of an existing one...(i.e.
 int checkNode(Long id, String contextName)
          Returns the current "knowledge" about a given node (i.e.
 int getNumberOfNodes()
          return the number of currently stored nodes
 void removeNode(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(Long id,
              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 id requested newer than what is stored is indicated by NODE_OUTDATED.

Parameters:
id -
contextName -
Returns:

addNode

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

Parameters:
id -
contextName -
Throws:
Exception

getNumberOfNodes

int getNumberOfNodes()
return the number of currently stored nodes

Returns:

removeNode

void removeNode(String contextName)
                throws Exception
Remove a node

Parameters:
id -
contextName -
Throws:
Exception


Copyright © 1999-2007 Apache Software Foundation. All Rights Reserved.