Package one.microstream.storage.types
Class StorageManager.Default
- java.lang.Object
-
- one.microstream.storage.types.StorageManager.Default
-
- All Implemented Interfaces:
Unpersistable
,StorageActivePart
,StorageController
,StorageKillable
,StorageManager
- Enclosing interface:
- StorageManager
public static final class StorageManager.Default extends Object implements StorageManager, Unpersistable, StorageKillable
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface one.microstream.storage.types.StorageManager
StorageManager.Default
-
-
Constructor Summary
-
Method Summary
Modifier and Type Method Description void
checkAcceptingTasks()
StorageConfiguration
configuration()
StorageRequestAcceptor
createRequestAcceptor()
StorageIdAnalysis
initializationIdAnalysis()
long
initializationTime()
boolean
isAcceptingTasks()
boolean
isActive()
Queries whether the part is actually active right now.boolean
isRunning()
boolean
isShuttingDown()
boolean
isStartingUp()
void
killStorage(Throwable cause)
Stops all threads, releases all resources (e.g.StorageObjectIdRangeEvaluator
objectIdRangeEvaluator()
StorageOperationController
operationController()
long
operationModeTime()
boolean
shutdown()
StorageManager.Default
start()
StorageTypeDictionary
typeDictionary()
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface one.microstream.storage.types.StorageController
initializationDuration, isShutdown
-
Methods inherited from interface one.microstream.storage.types.StorageManager
channelCountProvider
-
-
-
-
Constructor Detail
-
Default
public Default(StorageConfiguration storageConfiguration, StorageOperationController.Creator ocCreator, StorageDataFileValidator.Creator backupDataFileValidatorCreator, StorageFileWriter.Provider writerProvider, StorageFileReader.Provider readerProvider, StorageInitialDataFileNumberProvider initialDataFileNumberProvider, StorageRequestAcceptor.Creator requestAcceptorCreator, StorageTaskBroker.Creator taskBrokerCreator, StorageDataChunkValidator.Provider dataChunkValidatorProvider, StorageChannelsCreator channelCreator, StorageThreadProvider threadProvider, StorageRequestTaskCreator requestTaskCreator, StorageTypeDictionary typeDictionary, StorageRootTypeIdProvider rootTypeIdProvider, StorageTimestampProvider timestampProvider, StorageObjectIdRangeEvaluator objectIdRangeEvaluator, StorageGCZombieOidHandler zombieOidHandler, StorageRootOidSelector.Provider rootOidSelectorProvider, StorageobjectIdMarkQueue.Creator oidMarkQueueCreator, StorageEntityMarkMonitor.Creator entityMarkMonitorCreator, boolean switchByteOrder, StorageLockFileSetup lockFileSetup, StorageLockFileManager.Creator lockFileManagerCreator, StorageExceptionHandler exceptionHandler, StorageEventLogger eventLogger)
-
-
Method Detail
-
configuration
public final StorageConfiguration configuration()
- Specified by:
configuration
in interfaceStorageManager
-
isRunning
public final boolean isRunning()
- Specified by:
isRunning
in interfaceStorageController
-
isActive
public final boolean isActive()
Description copied from interface:StorageActivePart
Queries whether the part is actually active right now. This might returntrue
even despite some "running" flag being set tofalse
because there might be one last loop cycle execution before checking the "running" flag again.- Specified by:
isActive
in interfaceStorageActivePart
- Returns:
- if the part is actually active right now.
-
isAcceptingTasks
public final boolean isAcceptingTasks()
- Specified by:
isAcceptingTasks
in interfaceStorageController
-
isStartingUp
public final boolean isStartingUp()
- Specified by:
isStartingUp
in interfaceStorageController
-
isShuttingDown
public final boolean isShuttingDown()
- Specified by:
isShuttingDown
in interfaceStorageController
-
initializationTime
public final long initializationTime()
- Specified by:
initializationTime
in interfaceStorageController
-
operationModeTime
public final long operationModeTime()
- Specified by:
operationModeTime
in interfaceStorageController
-
checkAcceptingTasks
public final void checkAcceptingTasks()
- Specified by:
checkAcceptingTasks
in interfaceStorageController
-
start
public final StorageManager.Default start()
- Specified by:
start
in interfaceStorageController
- Specified by:
start
in interfaceStorageManager
-
initializationIdAnalysis
public final StorageIdAnalysis initializationIdAnalysis()
- Specified by:
initializationIdAnalysis
in interfaceStorageManager
-
shutdown
public final boolean shutdown()
- Specified by:
shutdown
in interfaceStorageController
- Specified by:
shutdown
in interfaceStorageManager
-
typeDictionary
public final StorageTypeDictionary typeDictionary()
- Specified by:
typeDictionary
in interfaceStorageManager
-
operationController
public StorageOperationController operationController()
- Specified by:
operationController
in interfaceStorageManager
-
objectIdRangeEvaluator
public StorageObjectIdRangeEvaluator objectIdRangeEvaluator()
- Specified by:
objectIdRangeEvaluator
in interfaceStorageManager
-
createRequestAcceptor
public final StorageRequestAcceptor createRequestAcceptor()
- Specified by:
createRequestAcceptor
in interfaceStorageManager
-
killStorage
public void killStorage(Throwable cause)
Description copied from interface:StorageKillable
Stops all threads, releases all resources (e.g. close files) without considering any internal state or waiting for any action to be completed.Useful only in simple error cases, for example
- Specified by:
killStorage
in interfaceStorageKillable
-
-