Package com.linkedin.venice.writer
Interface ChunkAwareCallback
-
- All Superinterfaces:
PubSubProducerCallback
- All Known Implementing Classes:
ActiveActiveProducerCallback
,LeaderProducerCallback
public interface ChunkAwareCallback extends PubSubProducerCallback
TheVeniceWriter
, upon detecting an instance of this class being passed to it, will always callsetChunkingInfo(byte[], ByteBuffer[], ChunkedValueManifest, ByteBuffer[], ChunkedValueManifest, ChunkedValueManifest, ChunkedValueManifest)
whenever processing aMessageType.PUT
, whether it is chunked or not.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
setChunkingInfo(byte[] key, java.nio.ByteBuffer[] valueChunks, ChunkedValueManifest chunkedValueManifest, java.nio.ByteBuffer[] rmdChunks, ChunkedValueManifest chunkedRmdManifest, ChunkedValueManifest oldValueManifest, ChunkedValueManifest oldRmdManifest)
For all PUT operations, the {@param key} is guaranteed to be passed via this function, whether chunking is enabled or not, and whether the value is chunked or not.-
Methods inherited from interface com.linkedin.venice.pubsub.api.PubSubProducerCallback
onCompletion
-
-
-
-
Method Detail
-
setChunkingInfo
void setChunkingInfo(byte[] key, java.nio.ByteBuffer[] valueChunks, ChunkedValueManifest chunkedValueManifest, java.nio.ByteBuffer[] rmdChunks, ChunkedValueManifest chunkedRmdManifest, ChunkedValueManifest oldValueManifest, ChunkedValueManifest oldRmdManifest)
For all PUT operations, the {@param key} is guaranteed to be passed via this function, whether chunking is enabled or not, and whether the value is chunked or not. The other two parameters are null if the value is not chunked.- Parameters:
key
- A byte[] corresponding to the top-level key written to Kafka, potentially including a chunking suffixvalueChunks
- An array ofByteBuffer
where the backing array has sufficient headroom to prepend Venice's headerchunkedValueManifest
- TheChunkedValueManifest
of the new chunked valuermdChunks
- An array ofByteBuffer
where the backing array has sufficient headroom to prepend Venice's headerchunkedRmdManifest
- TheChunkedValueManifest
of the new chunked RMDoldValueManifest
- TheChunkedValueManifest
of the previous chunked valueoldRmdManifest
- TheChunkedValueManifest
of the previous chunked RMD
-
-