|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectariba.util.core.ChecksumManager
public class ChecksumManager
Service that manages ComponentChecksums. Used during the startup process to verify that all nodes within a group are configured the same way. Each component needs to decide what constitutes that component's configuration, and what sort of checksum will be adequate to catch inconsistencies. This information is embodied in the ComponentChecksum abstract class. The ComponentChecksum consists of a component name, which must be unique, and an arbitrary length byte array. There are two concrete classes provided that extend ComponentChecksum: FileComponentChecksum, for handling components who's entire state is stored in files, and SimpleComponentChecksum that will accept a byte array as the checksum. Components will register specific ComponentChecksums with the manager. The BaseServer will get all the checksums and compare them with checksums on remote machines to decide whether or not a node is configured the same as the cluster. See http://development.ariba.com/PSS/CoreServer/multiserver/Component Checksum.doc and http://development.ariba.com/PSS/CoreServer/multiserver/Group Restart.doc for details on how all this works.
Constructor Summary | |
---|---|
ChecksumManager()
|
Method Summary | |
---|---|
boolean |
compareChecksums()
check to see if the component checksums from another node match the current component checksums. |
java.util.List |
getAll()
return the List of all component checksums. |
static ChecksumManager |
getChecksumManager()
Get the ChecksumManager service. |
java.util.List |
getRemoteChecksums()
get the remote checksum in the Checksum manager Return the List of ComponentChecksums from other nodes |
static State |
getState()
Get the State in which to store the instance. |
void |
register(ComponentChecksum cc)
register the component checksum with the manager. |
void |
reRegister(ComponentChecksum cc)
re-register the component checksum with the manager. |
static void |
setChecksumManager(ChecksumManager serv)
Set the instance of the checksum manager. |
void |
setRemoteChecksums(java.util.List checksums)
set the remote checksum in the Checksum manager, should be only be called by one thread |
static void |
setState(State s)
Set the state. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ChecksumManager()
Method Detail |
---|
public static ChecksumManager getChecksumManager()
public static void setChecksumManager(ChecksumManager serv)
serv
- The instancepublic static State getState()
public static void setState(State s)
s
- The state variablepublic void register(ComponentChecksum cc) throws ComponentChecksumException
cc
- the component checksum from some package
ComponentChecksumException
public void reRegister(ComponentChecksum cc) throws ComponentChecksumException
cc
- the component checksum from some package
ComponentChecksumException
public java.util.List getAll()
public boolean compareChecksums()
public void setRemoteChecksums(java.util.List checksums)
checksums
- the List of ComponentChecksums from other nodespublic java.util.List getRemoteChecksums()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |