Package one.microstream.storage.types
Interface StorageEventLogger
-
- All Known Implementing Classes:
StorageEventLogger.Debug,StorageEventLogger.Default,StorageEventLogger.NoOp
public interface StorageEventLogger
-
-
Nested Class Summary
Nested Classes Modifier and Type Interface Description static classStorageEventLogger.DebugDebug implementation of StorageEventLoggerstatic classStorageEventLogger.DefaultDefault implementation of StorageEventLoggerstatic classStorageEventLogger.NoOpNoOp StorageEventLogger
-
Method Summary
All Methods Static Methods Instance Methods Default Methods Modifier and Type Method Description static StorageEventLoggerDebug()Creates a Debug StorageEventLogger that prints to the console.static StorageEventLoggerDebug(Consumer<? super String> messageConsumer)Creates a Debug StorageEventLogger forwards its output to the supplied Consumerstatic StorageEventLoggerDefault()Creates a Default StorageEventLogger thats prints to the console.static StorageEventLoggerDefault(Consumer<? super String> messageConsumer)Creates a Default StorageEventLogger that forwards its output to the supplied Consumerdefault voidlogChannelProcessingDisabled(StorageChannel channel)default voidlogChannelStoppedWorking(StorageChannel channel)default voidlogDisruption(StorageChannel channel, Throwable t)Note that not all Throwables are Exceptions.default voidlogGarbageCollectorCompleted(long gcColdGeneration, long lastGcColdCompletion)default voidlogGarbageCollectorCompletedHotPhase(long gcHotGeneration, long lastGcHotCompletion)default voidlogGarbageCollectorEncounteredZombieObjectId(long objectId)default voidlogGarbageCollectorNotNeeded()default voidlogGarbageCollectorSweepingComplete(StorageEntityCache<?> entityCache)default voidlogLiveCheckComplete(StorageEntityCache<?> entityCache)static StorageEventLoggerNoOp()Creates a NoOp StorageEventLogger that does really nothing.
-
-
-
Method Detail
-
logChannelProcessingDisabled
default void logChannelProcessingDisabled(StorageChannel channel)
-
logChannelStoppedWorking
default void logChannelStoppedWorking(StorageChannel channel)
-
logDisruption
default void logDisruption(StorageChannel channel, Throwable t)
Note that not all Throwables are Exceptions. There are also Errors. And not all exceptions are problems. There are also program execution control vehicles likeInterruptedException. The actually fitting common term is "Disruption". Throwable is a very low-level technical, compiler-oriented expression.- Parameters:
channel- the affected channelt- the reason for the disruption
-
logLiveCheckComplete
default void logLiveCheckComplete(StorageEntityCache<?> entityCache)
-
logGarbageCollectorSweepingComplete
default void logGarbageCollectorSweepingComplete(StorageEntityCache<?> entityCache)
-
logGarbageCollectorNotNeeded
default void logGarbageCollectorNotNeeded()
-
logGarbageCollectorCompletedHotPhase
default void logGarbageCollectorCompletedHotPhase(long gcHotGeneration, long lastGcHotCompletion)
-
logGarbageCollectorCompleted
default void logGarbageCollectorCompleted(long gcColdGeneration, long lastGcColdCompletion)
-
logGarbageCollectorEncounteredZombieObjectId
default void logGarbageCollectorEncounteredZombieObjectId(long objectId)
-
NoOp
static StorageEventLogger NoOp()
Creates a NoOp StorageEventLogger that does really nothing.- Returns:
- a StorageEventLogger.NoOp instance
-
Default
static StorageEventLogger Default()
Creates a Default StorageEventLogger thats prints to the console.- Returns:
- a StorageEventLogger.Default instance
-
Default
static StorageEventLogger Default(Consumer<? super String> messageConsumer)
Creates a Default StorageEventLogger that forwards its output to the supplied Consumer- Parameters:
messageConsumer- a Consumer that processes the forwarded log messages- Returns:
- a StorageEventLogger.Default instance
-
Debug
static StorageEventLogger Debug()
Creates a Debug StorageEventLogger that prints to the console.- Returns:
- a StorageEventLogger.Debug instance
-
Debug
static StorageEventLogger Debug(Consumer<? super String> messageConsumer)
Creates a Debug StorageEventLogger forwards its output to the supplied Consumer- Parameters:
messageConsumer- a Consumer that processes the forwarded log messages- Returns:
- a StorageEventLogger.Debug instance
-
-