com.atomikos.persistence
Interface StateRecoveryManager

All Known Implementing Classes:
StateRecoveryManagerImp, VolatileStateRecoveryManager

public interface StateRecoveryManager

A state recovery manager is responsible for reconstructing StateRecoverable instances based on the history.


Method Summary
 void close()
          Shutdown.
 void delete(Object id)
          Deletes a given image from the underlying logs.
 void init()
          Initialize the recovery mgr before calling the other methods.
 Vector recover()
          Recover all recorded recoverable instances in their latest state.
 StateRecoverable recover(Object id)
          Reconstruct an instance of a staterecoverable.
 void register(StateRecoverable staterecoverable)
          Register a staterecoverable with the recovery manager service.
 

Method Detail

recover

Vector recover()
               throws LogException
Recover all recorded recoverable instances in their latest state.

Returns:
Vector A vector of reconstructed StateRecoverables.
Throws:
LogException - If the log fails.

init

void init()
          throws LogException
Initialize the recovery mgr before calling the other methods.

Throws:
LogException - If the underlying log fails.

register

void register(StateRecoverable staterecoverable)
Register a staterecoverable with the recovery manager service.

Parameters:
staterecoverable - The object that wants recoverable states.

recover

StateRecoverable recover(Object id)
                         throws LogException
Reconstruct an instance of a staterecoverable.

Parameters:
Object - The staterecoverable's identifier.
Returns:
StateRecoverable The instance, or null if not found.
Throws:
LogException - If underlying object log fails.

close

void close()
           throws LogException
Shutdown.

Throws:
LogException - For underlying log failure.

delete

void delete(Object id)
            throws LogException
Deletes a given image from the underlying logs.

Parameters:
id - The id of the image to delete.
Throws:
LogException - On failure.


Copyright © 2011. All Rights Reserved.