Package org.komamitsu.fluency.buffer
Class Buffer
java.lang.Object
org.komamitsu.fluency.buffer.Buffer
- All Implemented Interfaces:
Closeable,AutoCloseable
-
Nested Class Summary
Nested Classes -
Constructor Summary
ConstructorsConstructorDescriptionBuffer(Buffer.Config config, RecordFormatter recordFormatter) Buffer(RecordFormatter recordFormatter) -
Method Summary
Modifier and TypeMethodDescriptionvoidvoidvoidappendMessagePackMapValue(String tag, long timestamp, byte[] mapValue, int offset, int len) voidappendMessagePackMapValue(String tag, long timestamp, ByteBuffer mapValue) voidappendMessagePackMapValue(String tag, EventTime timestamp, byte[] mapValue, int offset, int len) voidappendMessagePackMapValue(String tag, EventTime timestamp, ByteBuffer mapValue) voidvoidclose()protected voidvoidprotected voidflushInternal(Ingester ingester, boolean force) longlongfloatfloatintintintbooleanlongprotected voidloadBufferFromFile(List<String> params, FileChannel channel) protected voidprotected voidsaveBuffer(List<String> params, ByteBuffer buffer) toString()
-
Constructor Details
-
Buffer
-
Buffer
-
-
Method Details
-
saveBuffer
-
flush
- Throws:
IOException
-
close
public void close()- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceCloseable
-
getBufferUsage
public float getBufferUsage() -
clearBackupFiles
public void clearBackupFiles() -
getMaxBufferSize
public long getMaxBufferSize() -
getFileBackupPrefix
-
getFileBackupDir
-
loadBufferFromFile
-
saveAllBuffersToFile
- Throws:
IOException
-
append
- Throws:
IOException
-
append
- Throws:
IOException
-
appendMessagePackMapValue
public void appendMessagePackMapValue(String tag, long timestamp, byte[] mapValue, int offset, int len) throws IOException - Throws:
IOException
-
appendMessagePackMapValue
public void appendMessagePackMapValue(String tag, EventTime timestamp, byte[] mapValue, int offset, int len) throws IOException - Throws:
IOException
-
appendMessagePackMapValue
public void appendMessagePackMapValue(String tag, long timestamp, ByteBuffer mapValue) throws IOException - Throws:
IOException
-
appendMessagePackMapValue
public void appendMessagePackMapValue(String tag, EventTime timestamp, ByteBuffer mapValue) throws IOException - Throws:
IOException
-
flushInternal
- Throws:
IOException
-
closeInternal
protected void closeInternal() -
getAllocatedSize
public long getAllocatedSize() -
getBufferedDataSize
public long getBufferedDataSize() -
getJvmHeapBufferMode
public boolean getJvmHeapBufferMode() -
bufferFormatType
-
getChunkInitialSize
public int getChunkInitialSize() -
getChunkExpandRatio
public float getChunkExpandRatio() -
getChunkRetentionSize
public int getChunkRetentionSize() -
getChunkRetentionTimeMillis
public int getChunkRetentionTimeMillis() -
toString
-