Class AdaptivePollingRecordPublisher
- java.lang.Object
-
- org.apache.flink.streaming.connectors.kinesis.internals.publisher.polling.PollingRecordPublisher
-
- org.apache.flink.streaming.connectors.kinesis.internals.publisher.polling.AdaptivePollingRecordPublisher
-
- All Implemented Interfaces:
RecordPublisher
@Internal public class AdaptivePollingRecordPublisher extends PollingRecordPublisher
An adaptive record publisher to add a dynamic batch read size forPollingRecordPublisher. Kinesis Streams have quotas on the transactions per second, and throughout. This class attempts to balance quotas and mitigate back off errors.
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface org.apache.flink.streaming.connectors.kinesis.internals.publisher.RecordPublisher
RecordPublisher.RecordBatchConsumer, RecordPublisher.RecordPublisherRunResult
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description RecordPublisher.RecordPublisherRunResultrun(RecordPublisher.RecordBatchConsumer consumer)Run the record publisher.-
Methods inherited from class org.apache.flink.streaming.connectors.kinesis.internals.publisher.polling.PollingRecordPublisher
run
-
-
-
-
Method Detail
-
run
public RecordPublisher.RecordPublisherRunResult run(RecordPublisher.RecordBatchConsumer consumer) throws InterruptedException
Description copied from interface:RecordPublisherRun the record publisher. Records will be consumed from the stream and published to the consumer. The number of batches retrieved by a single invocation will vary based on implementation.- Specified by:
runin interfaceRecordPublisher- Overrides:
runin classPollingRecordPublisher- Parameters:
consumer- the record batch consumer in which to output records- Returns:
- a status enum to represent whether a shard has been fully consumed
- Throws:
InterruptedException
-
-