Package ubic.gemma.cli.batch
Class LoggingBatchTaskSummaryWriter
java.lang.Object
ubic.gemma.cli.batch.LoggingBatchTaskSummaryWriter
- All Implemented Interfaces:
Closeable
,AutoCloseable
,BatchTaskSummaryWriter
Task summary writer that logs the result of a batch task to a logger.
- Author:
- poirigui
-
Constructor Summary
ConstructorsConstructorDescriptionLoggingBatchTaskSummaryWriter
(String logCategory) LoggingBatchTaskSummaryWriter
(String logCategory, boolean useDebugForSuccess) -
Method Summary
Modifier and TypeMethodDescriptionvoid
close()
Close the writer and write any remaining results.void
write
(BatchTaskProcessingResult result) Write the result of a batch task.
-
Constructor Details
-
LoggingBatchTaskSummaryWriter
-
LoggingBatchTaskSummaryWriter
- Parameters:
logCategory
- log category to use to report batch processing resultsuseDebugForSuccess
- if true, success are reported as debug logs
-
-
Method Details
-
write
Description copied from interface:BatchTaskSummaryWriter
Write the result of a batch task.The actual writing may be deferred until the writer is closed in
BatchTaskSummaryWriter.close()
.- Specified by:
write
in interfaceBatchTaskSummaryWriter
- Throws:
IOException
-
close
Description copied from interface:BatchTaskSummaryWriter
Close the writer and write any remaining results.- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceBatchTaskSummaryWriter
- Specified by:
close
in interfaceCloseable
- Throws:
IOException
-