Class DuplicatingPollStrategy
java.lang.Object
com.linkedin.venice.unit.kafka.consumer.poll.AbstractPollStrategy
com.linkedin.venice.unit.kafka.consumer.poll.DuplicatingPollStrategy
- All Implemented Interfaces:
PollStrategy
A
PollStrategy
implementation which can introduce duplicates.
The message payload is duplicated verbatim, but the Kafka offsets are incremented, as it would
happen in a real Kafka deployment.-
Field Summary
Fields inherited from class com.linkedin.venice.unit.kafka.consumer.poll.AbstractPollStrategy
keepPollingWhenEmpty
-
Constructor Summary
ConstructorDescriptionDuplicatingPollStrategy
(AbstractPollStrategy basePollStrategy, Set<PubSubTopicPartitionOffset> PubSubTopicPartitionOffsetsToDuplicate) -
Method Summary
Modifier and TypeMethodDescriptionprotected PubSubTopicPartitionOffset
getNextPoll
(Map<PubSubTopicPartition, Long> offsets) Methods inherited from class com.linkedin.venice.unit.kafka.consumer.poll.AbstractPollStrategy
incrementOffset, poll
-
Constructor Details
-
DuplicatingPollStrategy
public DuplicatingPollStrategy(AbstractPollStrategy basePollStrategy, Set<PubSubTopicPartitionOffset> PubSubTopicPartitionOffsetsToDuplicate)
-
-
Method Details
-
getNextPoll
- Specified by:
getNextPoll
in classAbstractPollStrategy
-