public class DirectPersistencyRecoveryHelper extends Object implements IStorageConsistency, ISpaceModeListener
Modifier and Type | Field and Description |
---|---|
static String |
LAST_PRIMARY_ZOOKEEPER_PATH_DEFAULT |
Constructor and Description |
---|
DirectPersistencyRecoveryHelper(SpaceImpl spaceImpl,
Logger logger) |
Modifier and Type | Method and Description |
---|---|
void |
afterSpaceModeChange(SpaceMode newMode)
Called right after the space mode changes.
|
void |
beforePrimaryElectionProcess() |
void |
beforeSpaceModeChange(SpaceMode newMode)
Called right before the space mode changes.
Implementors usually use it to allow specific service initializations. |
StorageConsistencyModes |
getStorageState() |
void |
handleDirectPersistencyRecoverFailure(int retryCount) |
boolean |
isInconsistentStorage() |
boolean |
isMeLastPrimary() |
boolean |
isPendingBackupRecovery() |
boolean |
isPerInstancePersistency() |
void |
setMeAsLastPrimary() |
void |
setPendingBackupRecovery(boolean pendingRecovery) |
void |
setStorageState(StorageConsistencyModes s) |
public static final String LAST_PRIMARY_ZOOKEEPER_PATH_DEFAULT
public StorageConsistencyModes getStorageState()
getStorageState
in interface IStorageConsistency
public void setStorageState(StorageConsistencyModes s)
setStorageState
in interface IStorageConsistency
public boolean isPerInstancePersistency()
isPerInstancePersistency
in interface IStorageConsistency
public void beforePrimaryElectionProcess()
public boolean isInconsistentStorage()
public void setMeAsLastPrimary()
public boolean isMeLastPrimary()
public void beforeSpaceModeChange(SpaceMode newMode) throws RemoteException
ISpaceModeListener
beforeSpaceModeChange
in interface ISpaceModeListener
newMode
- the new mode change before it's published.RemoteException
- if an exception occurred during execution of a remote call.public void afterSpaceModeChange(SpaceMode newMode) throws RemoteException
ISpaceModeListener
afterSpaceModeChange
in interface ISpaceModeListener
newMode
- the new mode change after it was published.RemoteException
- if an exception occurred during execution of a remote call.public void setPendingBackupRecovery(boolean pendingRecovery)
public boolean isPendingBackupRecovery()
public void handleDirectPersistencyRecoverFailure(int retryCount)
Copyright © GigaSpaces.