Package io.deephaven.io.log.impl
Class LogSinkImpl<T extends LogSink.Element>
java.lang.Object
io.deephaven.io.log.impl.LogSinkImpl<T>
- All Implemented Interfaces:
LogSink<T>
-
Nested Class Summary
Nested classes/interfaces inherited from interface io.deephaven.io.log.LogSink
LogSink.Element, LogSink.Factory<T extends LogSink.Element>, LogSink.Interceptor<T extends LogSink.Element>, LogSink.LogSinkWriter<S extends LogSink<? extends LogSink.Element>>, LogSink.Null, LogSink.Shutdown
-
Field Summary
Modifier and TypeFieldDescriptionstatic final DateFormat
static final LogSinkImpl.BigWriterThread
static final int
-
Constructor Summary
ConstructorDescriptionLogSinkImpl
(String basePath, long rollIntervalMillis, Pool<T> elementPool) ConstructorLogSinkImpl
(String basePath, long rollIntervalMillis, Pool<T> elementPool, boolean append) ConstructorLogSinkImpl
(String basePath, long rollIntervalMillis, Pool<T> elementPool, boolean append, LogOutput outputBuffer) ConstructorLogSinkImpl
(String basePath, long rollIntervalMillis, Pool<T> elementPool, LogOutput outputBuffer) ConstructorLogSinkImpl
(String basePath, long rollIntervalMillis, DateFormat rollFormat, Pool<T> elementPool, boolean append) ConstructorLogSinkImpl
(String basePath, long rollIntervalMillis, DateFormat rollFormat, Pool<T> elementPool, boolean append, LogOutput outputBuffer, String header) ConstructorLogSinkImpl
(String basePath, long rollIntervalMillis, DateFormat rollFormat, Pool<T> elementPool, boolean append, LogOutput outputBuffer, String header, LogSink.LogSinkWriter<LogSinkImpl<T>> maybeWriter) Constructor -
Method Summary
Modifier and TypeMethodDescriptionvoid
addInterceptor
(LogSink.Interceptor<T> interceptor) Add an interceptorstatic <T extends LogSink.Element>
LogSink.Factory<T>FACTORY()
void
shutdown()
Shutdown the sink - does not return until all entries have been written.void
Terminate the sink - does not guarantee entries will ever be written, but will not block shutdown() calls.toString()
Return a string representationvoid
add a buffer to the output queue
-
Field Details
-
ROLL_INTERVAL
public static final int ROLL_INTERVAL- See Also:
-
DATE_FORMAT
-
globalWriterThread
-
-
Constructor Details
-
LogSinkImpl
Constructor -
LogSinkImpl
public LogSinkImpl(String basePath, long rollIntervalMillis, Pool<T> elementPool, LogOutput outputBuffer) Constructor -
LogSinkImpl
Constructor -
LogSinkImpl
public LogSinkImpl(String basePath, long rollIntervalMillis, Pool<T> elementPool, boolean append, LogOutput outputBuffer) Constructor -
LogSinkImpl
public LogSinkImpl(String basePath, long rollIntervalMillis, DateFormat rollFormat, Pool<T> elementPool, boolean append) Constructor -
LogSinkImpl
public LogSinkImpl(String basePath, long rollIntervalMillis, DateFormat rollFormat, Pool<T> elementPool, boolean append, LogOutput outputBuffer, String header) Constructor -
LogSinkImpl
public LogSinkImpl(String basePath, long rollIntervalMillis, DateFormat rollFormat, Pool<T> elementPool, boolean append, LogOutput outputBuffer, String header, LogSink.LogSinkWriter<LogSinkImpl<T>> maybeWriter) Constructor
-
-
Method Details
-
FACTORY
-
toString
Return a string representation -
write
add a buffer to the output queue- Specified by:
write
in interfaceLogSink<T extends LogSink.Element>
-
shutdown
public void shutdown()Shutdown the sink - does not return until all entries have been written.- Specified by:
shutdown
in interfaceLogSink<T extends LogSink.Element>
-
terminate
public void terminate()Terminate the sink - does not guarantee entries will ever be written, but will not block shutdown() calls.- Specified by:
terminate
in interfaceLogSink<T extends LogSink.Element>
-
addInterceptor
Add an interceptor- Specified by:
addInterceptor
in interfaceLogSink<T extends LogSink.Element>
-