public class ReclaimableMemoryRecords
extends org.apache.kafka.common.record.MemoryRecords
Modifier and Type | Field and Description |
---|---|
static ReclaimableMemoryRecords |
EMPTY |
Constructor and Description |
---|
ReclaimableMemoryRecords(ByteBuffer buffer,
Optional<MemoryTracker.MemoryLease> lease) |
Modifier and Type | Method and Description |
---|---|
Iterable<org.apache.kafka.common.record.MutableRecordBatch> |
batches() |
org.apache.kafka.common.utils.AbstractIterator<org.apache.kafka.common.record.MutableRecordBatch> |
batchIterator() |
ByteBuffer |
buffer() |
org.apache.kafka.common.record.ConvertedRecords<org.apache.kafka.common.record.MemoryRecords> |
downConvert(byte toMagic,
long firstOffset,
org.apache.kafka.common.utils.Time time) |
boolean |
equals(Object o) |
org.apache.kafka.common.record.MemoryRecords.FilterResult |
filterTo(org.apache.kafka.common.TopicPartition partition,
org.apache.kafka.common.record.MemoryRecords.RecordFilter filter,
ByteBuffer destinationBuffer,
int maxRecordBatchSize,
org.apache.kafka.common.utils.BufferSupplier decompressionBufferSupplier) |
org.apache.kafka.common.record.RecordBatch |
firstBatch() |
Integer |
firstBatchSize() |
int |
hashCode() |
boolean |
hasMatchingMagic(byte magic) |
Iterable<org.apache.kafka.common.record.Record> |
records() |
void |
release() |
int |
sizeInBytes() |
org.apache.kafka.common.record.DefaultRecordsSend |
toSend() |
String |
toString() |
int |
validBytes() |
int |
writeFullyTo(GatheringByteChannel channel) |
int |
writeTo(org.apache.kafka.common.network.TransferableChannel channel,
int position,
int length) |
builder, builder, builder, builder, builder, builder, builder, builder, builder, idempotentBuilder, readableRecords, withEndTransactionMarker, withEndTransactionMarker, withEndTransactionMarker, withIdempotentRecords, withIdempotentRecords, withIdempotentRecords, withLeaderChangeMessage, withRecords, withRecords, withRecords, withRecords, withRecords, withRecords, withRecords, withRecords, withSnapshotFooterRecord, withSnapshotHeaderRecord, withTransactionalRecords, withTransactionalRecords, withTransactionalRecords, writeEndTransactionalMarker
public static final ReclaimableMemoryRecords EMPTY
public ReclaimableMemoryRecords(ByteBuffer buffer, Optional<MemoryTracker.MemoryLease> lease)
public int sizeInBytes()
sizeInBytes
in interface org.apache.kafka.common.record.BaseRecords
sizeInBytes
in class org.apache.kafka.common.record.MemoryRecords
public int writeTo(org.apache.kafka.common.network.TransferableChannel channel, int position, int length) throws IOException
writeTo
in interface org.apache.kafka.common.record.TransferableRecords
writeTo
in class org.apache.kafka.common.record.MemoryRecords
IOException
public int writeFullyTo(GatheringByteChannel channel) throws IOException
writeFullyTo
in class org.apache.kafka.common.record.MemoryRecords
IOException
public int validBytes()
validBytes
in class org.apache.kafka.common.record.MemoryRecords
public org.apache.kafka.common.record.ConvertedRecords<org.apache.kafka.common.record.MemoryRecords> downConvert(byte toMagic, long firstOffset, org.apache.kafka.common.utils.Time time)
downConvert
in interface org.apache.kafka.common.record.Records
downConvert
in class org.apache.kafka.common.record.MemoryRecords
public org.apache.kafka.common.utils.AbstractIterator<org.apache.kafka.common.record.MutableRecordBatch> batchIterator()
batchIterator
in interface org.apache.kafka.common.record.Records
batchIterator
in class org.apache.kafka.common.record.MemoryRecords
public Integer firstBatchSize()
firstBatchSize
in class org.apache.kafka.common.record.MemoryRecords
public org.apache.kafka.common.record.MemoryRecords.FilterResult filterTo(org.apache.kafka.common.TopicPartition partition, org.apache.kafka.common.record.MemoryRecords.RecordFilter filter, ByteBuffer destinationBuffer, int maxRecordBatchSize, org.apache.kafka.common.utils.BufferSupplier decompressionBufferSupplier)
filterTo
in class org.apache.kafka.common.record.MemoryRecords
public ByteBuffer buffer()
buffer
in class org.apache.kafka.common.record.MemoryRecords
public Iterable<org.apache.kafka.common.record.MutableRecordBatch> batches()
batches
in interface org.apache.kafka.common.record.Records
batches
in class org.apache.kafka.common.record.MemoryRecords
public boolean hasMatchingMagic(byte magic)
hasMatchingMagic
in interface org.apache.kafka.common.record.Records
hasMatchingMagic
in class org.apache.kafka.common.record.AbstractRecords
public org.apache.kafka.common.record.RecordBatch firstBatch()
firstBatch
in class org.apache.kafka.common.record.AbstractRecords
public Iterable<org.apache.kafka.common.record.Record> records()
records
in interface org.apache.kafka.common.record.Records
records
in class org.apache.kafka.common.record.AbstractRecords
public org.apache.kafka.common.record.DefaultRecordsSend toSend()
toSend
in interface org.apache.kafka.common.record.BaseRecords
toSend
in class org.apache.kafka.common.record.AbstractRecords
public void release()
release
in interface org.apache.kafka.common.record.BaseRecords
release
in class org.apache.kafka.common.record.MemoryRecords
public String toString()
toString
in class org.apache.kafka.common.record.MemoryRecords
public boolean equals(Object o)
equals
in class org.apache.kafka.common.record.MemoryRecords
public int hashCode()
hashCode
in class org.apache.kafka.common.record.MemoryRecords