Package com.illumon.intradaylogger
Class LongLivedProcessBinaryStoreWriterFactory
java.lang.Object
com.illumon.intradaylogger.LongLivedProcessBinaryStoreWriterFactory
- All Implemented Interfaces:
IntradayLogger.TableWriterFactory
public class LongLivedProcessBinaryStoreWriterFactory
extends Object
implements IntradayLogger.TableWriterFactory
Extend the default factory to add date to the rolling format.
The default factory only appends the time portion, the date is part of the static prefix.
That breaks pretty badly since for processes that stay alive past midnight.
-
Constructor Summary
ConstructorsConstructorDescriptionDeprecated.LongLivedProcessBinaryStoreWriterFactory(String path, int version, com.fishlib.io.logger.Logger log) Create a long lived binary store writer factory using the specified path.LongLivedProcessBinaryStoreWriterFactory(String path, int version, com.fishlib.io.logger.Logger log, String timeZoneName) Create a long lived binary store writer factory using the specified path and time zone name.LongLivedProcessBinaryStoreWriterFactory(String path, int version, com.fishlib.io.logger.Logger log, TimeZone timeZone) Create a long lived binary store writer factory using the specified path and time zone.LongLivedProcessBinaryStoreWriterFactory(String path, com.fishlib.io.logger.Logger log) Create a long lived binary store writer factory using the specified path. -
Method Summary
Modifier and TypeMethodDescriptionbuildWriter(String[] columnNames, SupportedType[] loggerTypes, Class[] columnTypes, Object[] typeMetadata) Creates a new table writer.buildWriter(String[] columnNames, SupportedType[] loggerTypes, Class[] columnTypes, Object[] typeMetadata, Map<String, Object> constantValues) Creates a new table writer.buildWriter(String[] columnNames, SupportedType[] loggerTypes, Class[] columnTypes, Object[] typeMetadata, Map<String, Object> constantValues, int applicationVersion) Creates a new table writer.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface com.illumon.intradaylogger.IntradayLogger.TableWriterFactory
supportsDynamicPartitioning
-
Constructor Details
-
LongLivedProcessBinaryStoreWriterFactory
Deprecated.CallLongLivedProcessBinaryStoreWriterFactory(String, Logger), adding a fabricated Logger.- Parameters:
path- path for the output log file.
-
LongLivedProcessBinaryStoreWriterFactory
Create a long lived binary store writer factory using the specified path. The binarystore.defaultversion property will be used to select the file format version.- Parameters:
path- path for the output log file.log- the Logger instance for errors.
-
LongLivedProcessBinaryStoreWriterFactory
public LongLivedProcessBinaryStoreWriterFactory(String path, int version, com.fishlib.io.logger.Logger log) Create a long lived binary store writer factory using the specified path.- Parameters:
path- path for the output log file.version- the format for the binary store.log- the Logger instance for errors.
-
LongLivedProcessBinaryStoreWriterFactory
public LongLivedProcessBinaryStoreWriterFactory(String path, int version, com.fishlib.io.logger.Logger log, String timeZoneName) Create a long lived binary store writer factory using the specified path and time zone name.- Parameters:
path- path for the output log file.version- the format for the binary store.log- the Logger instance for errors.timeZoneName- a valid time zone name, such as "America/New_York" or "Asia/Tokyo"
-
LongLivedProcessBinaryStoreWriterFactory
public LongLivedProcessBinaryStoreWriterFactory(String path, int version, com.fishlib.io.logger.Logger log, TimeZone timeZone) Create a long lived binary store writer factory using the specified path and time zone.- Parameters:
path- path for the output log file.version- the format for the binary store.log- the Logger instance for errors.timeZone- the TimeZone to use for file names
-
-
Method Details
-
buildWriter
public TableWriter buildWriter(String[] columnNames, SupportedType[] loggerTypes, Class[] columnTypes, Object[] typeMetadata) throws IOException Description copied from interface:IntradayLogger.TableWriterFactoryCreates a new table writer.- Specified by:
buildWriterin interfaceIntradayLogger.TableWriterFactory- Parameters:
columnNames- column namesloggerTypes- column types for the intraday loggercolumnTypes- column types for the tabletypeMetadata- metadata for encoding and decoding a type- Returns:
- new table writer
- Throws:
IOException- problem creating the table writer
-
buildWriter
public TableWriter buildWriter(String[] columnNames, SupportedType[] loggerTypes, Class[] columnTypes, Object[] typeMetadata, Map<String, Object> constantValues) throws IOExceptionDescription copied from interface:IntradayLogger.TableWriterFactoryCreates a new table writer.- Specified by:
buildWriterin interfaceIntradayLogger.TableWriterFactory- Parameters:
columnNames- column namesloggerTypes- column types for the intraday loggercolumnTypes- column types for the tabletypeMetadata- metadata for encoding and decoding a typeconstantValues- values that do not change for each row- Returns:
- new table writer
- Throws:
IOException- problem creating the table writer
-
buildWriter
public TableWriter buildWriter(String[] columnNames, SupportedType[] loggerTypes, Class[] columnTypes, Object[] typeMetadata, Map<String, Object> constantValues, int applicationVersion) throws IOExceptionDescription copied from interface:IntradayLogger.TableWriterFactoryCreates a new table writer.- Specified by:
buildWriterin interfaceIntradayLogger.TableWriterFactory- Parameters:
columnNames- column namesloggerTypes- column types for the intraday loggercolumnTypes- column types for the tabletypeMetadata- metadata for encoding and decoding a typeconstantValues- values that do not change for each rowapplicationVersion- application version number used to select listener for reading this file- Returns:
- new table writer
- Throws:
IOException- problem creating the table writer
-