Package elf4j.engine.service.writer
Class ConseqWriterGroup
- java.lang.Object
-
- elf4j.engine.service.writer.ConseqWriterGroup
-
- All Implemented Interfaces:
Stoppable,Stoppable.Process,LogWriter,PerformanceSensitive
public class ConseqWriterGroup extends Object implements LogWriter, Stoppable.Process
In general, log events are asynchronously written/rendered in parallel by multiple concurrent threads. However, events issued by the same caller application thread are rendered sequentially with theConseqExecutorAPI. Thus, logs by different caller threads may arrive at the final destination (e.g. system Console or a log file) in any order; meanwhile, logs from the same caller thread will arrive sequentially in the same order as they are called in the orginal thread.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface elf4j.engine.service.writer.LogWriter
LogWriter.TypedLogWriterFactory
-
Nested classes/interfaces inherited from interface elf4j.engine.service.Stoppable
Stoppable.Intake, Stoppable.Output, Stoppable.Process
-
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description static @NonNull ConseqWriterGroupfrom(LogServiceConfiguration logServiceConfiguration)elf4j.LevelgetMinimumOutputLevel()booleanincludeCallerDetail()booleanincludeCallerThread()booleanisStopped()voidstop()voidwrite(LogEvent logEvent)
-
-
-
Method Detail
-
from
@NonNull public static @NonNull ConseqWriterGroup from(LogServiceConfiguration logServiceConfiguration)
- Parameters:
logServiceConfiguration- entire configuration- Returns:
- the composite writer containing all writers configured in the specified properties
-
getMinimumOutputLevel
public elf4j.Level getMinimumOutputLevel()
- Specified by:
getMinimumOutputLevelin interfaceLogWriter- Returns:
- the minimum output level of this writer
-
write
public void write(LogEvent logEvent)
-
includeCallerDetail
public boolean includeCallerDetail()
- Specified by:
includeCallerDetailin interfacePerformanceSensitive- Returns:
- true if log should include caller detail such as method, line number...
-
includeCallerThread
public boolean includeCallerThread()
- Specified by:
includeCallerThreadin interfacePerformanceSensitive- Returns:
- true if log should include call thread information such thread name and id
-
-