Package com.qfs.multiversion
Interface IAdvancedEpochManager
- All Superinterfaces:
Cloneable,IClone<IAdvancedEpochManager>,IEpochManager
- All Known Implementing Classes:
AEpochManager,DistributedEpochManager,EpochManager
Globally manages the epochs for an application instance.
Controls the creation of new epochs, gives access to the latest epoch, and can create version history for multiversion components that want to record their versions.
- Author:
- ActiveViam
-
Nested Class Summary
Nested classes/interfaces inherited from interface com.qfs.multiversion.IEpochManager
IEpochManager.IVersionLifecycleHandler<V extends IVersion> -
Field Summary
Fields inherited from interface com.qfs.multiversion.IEpochManager
IDENTIFIER -
Method Summary
Modifier and TypeMethodDescriptionMap<String,? extends IVersionHistory<?>> Gets the underlying histories indexed by theirids.Gets the root history.booleanIndicates whether this epoch manager has beenstartedor not.voidNotifies the epoch manager that a new epoch has been committed.voidstart()Starts the thread executing the epoch managementplan.voidstop()Stops the thread started bystart().Methods inherited from interface com.qfs.multiversion.IEpochManager
createVersionHistory, discard, forceDiscardEpochs, getBranches, releaseBranch, releaseEpochs, releaseHistory
-
Method Details
-
onCommit
Notifies the epoch manager that a new epoch has been committed.This method should NOT call
IVersionHistory.onCommit(IEpoch)as the commit may not affect all the histories.- Parameters:
epoch- the epoch of the commit
-
start
void start()Starts the thread executing the epoch managementplan.This method does nothing when
IEpochManagementPolicy.getInvokeInterval()returns a negative value. -
isStarted
boolean isStarted()Indicates whether this epoch manager has beenstartedor not.- Returns:
trueif this epoch manager has been started,falseotherwise
-
stop
void stop()Stops the thread started bystart(). -
getRootHistory
IVersionHistory<?> getRootHistory()Description copied from interface:IEpochManagerGets the root history. The root history is the single history whose versions are followed by other histories.- Specified by:
getRootHistoryin interfaceIEpochManager- Returns:
- the root history
-
getHistories
Map<String,? extends IVersionHistory<?>> getHistories()Description copied from interface:IEpochManagerGets the underlying histories indexed by theirids.- Specified by:
getHistoriesin interfaceIEpochManager
-