Package com.linkedin.davinci.utils
Class ChunkAssembler
java.lang.Object
com.linkedin.davinci.utils.ChunkAssembler
- Direct Known Subclasses:
InMemoryChunkAssembler
,RocksDBChunkAssembler
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionChunkAssembler
(AbstractStorageEngine bufferStorageEngine, boolean skipFailedToAssembleRecords) -
Method Summary
Modifier and TypeMethodDescriptionbufferAndAssembleRecord
(PubSubTopicPartition pubSubTopicPartition, int schemaId, byte[] keyBytes, ByteBuffer valueBytes, long recordOffset, VeniceCompressor compressor) Buffers and assembles chunks of a record.void
-
Field Details
-
bufferStorageEngine
-
-
Constructor Details
-
ChunkAssembler
public ChunkAssembler(AbstractStorageEngine bufferStorageEngine, boolean skipFailedToAssembleRecords)
-
-
Method Details
-
bufferAndAssembleRecord
public ByteBufferValueRecord<ByteBuffer> bufferAndAssembleRecord(PubSubTopicPartition pubSubTopicPartition, int schemaId, byte[] keyBytes, ByteBuffer valueBytes, long recordOffset, VeniceCompressor compressor) Buffers and assembles chunks of a record. If the record is chunked, it stores the chunks and returns null. Once all chunks of a record are received, it returns the compressed and serialized assembled record. -
clearBuffer
public void clearBuffer()
-