Package com.helger.dao.wal
Class WALListener
java.lang.Object
com.helger.scope.singleton.AbstractSingleton
com.helger.scope.singleton.AbstractGlobalSingleton
com.helger.dao.wal.WALListener
- All Implemented Interfaces:
com.helger.scope.IScopeDestructionAware
public final class WALListener
extends com.helger.scope.singleton.AbstractGlobalSingleton
The global write ahead logging manager that schedules future writings of a
DAO.
- Author:
- Philip Helger
-
Field Summary
Fields inherited from class com.helger.scope.singleton.AbstractSingleton
m_aRWLock -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic WALListenerprotected voidonDestroy(com.helger.scope.IScope aScopeInDestruction) voidregisterForLaterWriting(AbstractWALDAO<?> aDAO, String sWALFilename, Duration aWaitingWime) This is the main method for registration of later writing.Methods inherited from class com.helger.scope.singleton.AbstractGlobalSingleton
getAllGlobalSingletons, getGlobalSingleton, getGlobalSingletonIfInstantiated, isGlobalSingletonInstantiatedMethods inherited from class com.helger.scope.singleton.AbstractSingleton
getAllSingletons, getSingleton, getSingletonIfInstantiated, getSingletonScopeKey, isDestroyed, isInDestruction, isInInstantiation, isInPreDestruction, isInstantiated, isSingletonInstantiated, isUsableObject, onAfterInstantiation, onBeforeDestroy, onBeforeScopeDestruction, onScopeDestruction, readAbstractSingletonFields, setDestroyed, setInDestruction, setInInstantiation, setInPreDestruction, setInstantiated, toString, writeAbstractSingletonFields
-
Constructor Details
-
WALListener
Deprecated.Called via reflection - don't call it yourselfConstructor
-
-
Method Details
-
getInstance
-
onDestroy
- Overrides:
onDestroyin classcom.helger.scope.singleton.AbstractSingleton
-
registerForLaterWriting
public void registerForLaterWriting(@Nonnull AbstractWALDAO<?> aDAO, @Nonnull String sWALFilename, @Nonnull Duration aWaitingWime) This is the main method for registration of later writing.- Parameters:
aDAO- The DAO to be writtensWALFilename- The filename of the WAL file for later deletion (in case the filename changes over time).aWaitingWime- The time to wait, until the file is physically written. May not benull.
-