public final class AvroDataFileAppender
extends ch.qos.logback.core.UnsynchronizedAppenderBase<ch.qos.logback.classic.spi.ILoggingEvent>
| Constructor and Description |
|---|
AvroDataFileAppender() |
| Modifier and Type | Method and Description |
|---|---|
protected void |
append(ch.qos.logback.classic.spi.ILoggingEvent eventObject) |
void |
cleanup() |
long |
flush() |
Path |
getCurrentFile() |
org.apache.avro.file.FileReader<org.spf4j.base.avro.LogRecord> |
getCurrentLogs() |
Path |
getDestinationPath() |
List<org.spf4j.base.avro.LogRecord> |
getFilteredLogs(String originPrefix,
long ptailOffset,
int limit,
Predicate<org.spf4j.base.avro.LogRecord> pred) |
List<Path> |
getLogFiles() |
List<org.spf4j.base.avro.LogRecord> |
getLogs(String originPrefix,
long ptailOffset,
int limit) |
long |
getNrLogs() |
static long |
getNrLogs(Path file) |
List<Path> |
getOldLogFiles() |
static boolean |
isValidFile(Path file) |
void |
setCodec(String codec) |
void |
setDestinationPath(String destinationPath) |
void |
setFileNameBase(String fileNameBase) |
void |
setMaxLogsBytes(long maxLogsBytes) |
void |
setMaxNrFiles(int maxNrFiles) |
void |
setPartitionZoneID(String zoneIdStr) |
static void |
skip(org.apache.avro.file.FileReader<org.spf4j.base.avro.LogRecord> it,
long count) |
void |
start() |
void |
stop() |
String |
toString() |
addFilter, clearAllFilters, doAppend, getCopyOfAttachedFiltersList, getFilterChainDecision, getName, isStarted, setNameaddError, addError, addInfo, addInfo, addStatus, addWarn, addWarn, getContext, getDeclaredOrigin, getStatusManager, setContextpublic void setMaxNrFiles(int maxNrFiles)
public void setMaxLogsBytes(long maxLogsBytes)
public void setCodec(String codec)
public void setFileNameBase(String fileNameBase)
public void setDestinationPath(String destinationPath)
public void setPartitionZoneID(String zoneIdStr)
public Path getDestinationPath()
public void cleanup()
throws IOException
IOExceptionpublic List<Path> getLogFiles() throws IOException
IOExceptionpublic List<Path> getOldLogFiles() throws IOException
IOExceptionpublic Path getCurrentFile()
public long flush()
throws IOException
IOExceptionpublic long getNrLogs()
throws IOException
IOExceptionpublic org.apache.avro.file.FileReader<org.spf4j.base.avro.LogRecord> getCurrentLogs()
throws IOException
IOExceptionpublic List<org.spf4j.base.avro.LogRecord> getLogs(String originPrefix, long ptailOffset, int limit) throws IOException
IOExceptionpublic List<org.spf4j.base.avro.LogRecord> getFilteredLogs(String originPrefix, long ptailOffset, int limit, Predicate<org.spf4j.base.avro.LogRecord> pred) throws IOException
IOExceptionpublic static void skip(org.apache.avro.file.FileReader<org.spf4j.base.avro.LogRecord> it,
long count)
throws IOException
IOExceptionpublic static long getNrLogs(Path file) throws IOException
IOExceptionpublic void stop()
stop in interface ch.qos.logback.core.spi.LifeCyclestop in class ch.qos.logback.core.UnsynchronizedAppenderBase<ch.qos.logback.classic.spi.ILoggingEvent>public void start()
start in interface ch.qos.logback.core.spi.LifeCyclestart in class ch.qos.logback.core.UnsynchronizedAppenderBase<ch.qos.logback.classic.spi.ILoggingEvent>public static boolean isValidFile(Path file) throws IOException
IOExceptionprotected void append(ch.qos.logback.classic.spi.ILoggingEvent eventObject)
append in class ch.qos.logback.core.UnsynchronizedAppenderBase<ch.qos.logback.classic.spi.ILoggingEvent>public String toString()
toString in class ch.qos.logback.core.UnsynchronizedAppenderBase<ch.qos.logback.classic.spi.ILoggingEvent>Copyright © 2019 SPF4J. All rights reserved.