Package com.linkedin.venice.utils
Class ChunkingTestUtils
java.lang.Object
com.linkedin.venice.utils.ChunkingTestUtils
-
Field Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic byte[]
createChunkBytes
(int startValue, int chunkLength) static ChunkedKeySuffix
createChunkedKeySuffix
(int firstSegmentNumber, int firstSequenceNumber, int chunkIndex) createChunkedRecord
(byte[] serializedKey, int firstSegmentNumber, int firstSequenceNumber, int chunkIndex, int firstMessageOffset, PubSubTopicPartition pubSubTopicPartition) createChunkValueManifestRecord
(byte[] serializedKey, PubSubMessage<KafkaKey, KafkaMessageEnvelope, Long> firstMessage, int numberOfChunks, PubSubTopicPartition pubSubTopicPartition) createDeleteRecord
(byte[] serializedKey, byte[] serializedRmd, PubSubTopicPartition pubSubTopicPartition) static KafkaMessageEnvelope
createKafkaMessageEnvelope
(MessageType messageType, int segmentNumber, int sequenceNumber) createPutRecord
(byte[] serializedKey, byte[] serializedValue, byte[] serializedRmd, PubSubTopicPartition pubSubTopicPartition) static ByteBuffer
createReplicationMetadataPayload
(int size) createUpdateRecord
(byte[] serializedKey, byte[] serializedValue, PubSubTopicPartition pubSubTopicPartition)
-
Field Details
-
CHUNK_LENGTH
public static final int CHUNK_LENGTH- See Also:
-
KEY_WITH_CHUNKING_SUFFIX_SERIALIZER
-
-
Method Details
-
createChunkBytes
public static byte[] createChunkBytes(int startValue, int chunkLength) -
createChunkedKeySuffix
public static ChunkedKeySuffix createChunkedKeySuffix(int firstSegmentNumber, int firstSequenceNumber, int chunkIndex) -
createKafkaMessageEnvelope
public static KafkaMessageEnvelope createKafkaMessageEnvelope(MessageType messageType, int segmentNumber, int sequenceNumber) -
createChunkedRecord
public static PubSubMessage<KafkaKey,KafkaMessageEnvelope, createChunkedRecordLong> (byte[] serializedKey, int firstSegmentNumber, int firstSequenceNumber, int chunkIndex, int firstMessageOffset, PubSubTopicPartition pubSubTopicPartition) -
createChunkValueManifestRecord
public static PubSubMessage<KafkaKey,KafkaMessageEnvelope, createChunkValueManifestRecordLong> (byte[] serializedKey, PubSubMessage<KafkaKey, KafkaMessageEnvelope, Long> firstMessage, int numberOfChunks, PubSubTopicPartition pubSubTopicPartition) -
createReplicationMetadataPayload
-
createDeleteRecord
public static PubSubMessage<KafkaKey,KafkaMessageEnvelope, createDeleteRecordLong> (byte[] serializedKey, byte[] serializedRmd, PubSubTopicPartition pubSubTopicPartition) -
createPutRecord
public static PubSubMessage<KafkaKey,KafkaMessageEnvelope, createPutRecordLong> (byte[] serializedKey, byte[] serializedValue, byte[] serializedRmd, PubSubTopicPartition pubSubTopicPartition) -
createUpdateRecord
public static PubSubMessage<KafkaKey,KafkaMessageEnvelope, createUpdateRecordLong> (byte[] serializedKey, byte[] serializedValue, PubSubTopicPartition pubSubTopicPartition)
-