Commits the offsets to Kafka in a single commit.
The offsets included in the CommittableOffsetBatch.
Creates a new CommittableOffsetBatch with the specified offsets included.
Creates a new CommittableOffsetBatch with the specified offsets included. Note that this function requires offsets to be in-order per topic-partition, as provided offsets will override existing offsets for the same topic-partition.
Creates a new CommittableOffsetBatch with the specified offset included.
Creates a new CommittableOffsetBatch with the specified offset included. Note that this function requires offsets to be in-order per topic-partition, as provided offsets will override existing offsets for the same topic-partition.
CommittableOffsetBatch represents a batch of Kafka offsets which can be committed together using commit. An offset, or one more batch, can be added an existing batch using
updated
. Note that this requires the offsets per topic-partition to be included in-order, since offset commits in general require it.Use CommittableOffsetBatch#empty to create an empty batch. The CommittableOffset#batch function can be used to create a batch from an existing CommittableOffset.
If you have some offsets in-order per topic-partition, you can fold them together using CommittableOffsetBatch#empty and
updated
, or you can use CommittableOffsetBatch#fromFoldable. Generally, prefer to usefromFoldable
, as it has better performance. Provided pipes like commitBatch and commitBatchWithin are also to be preferred, as they also achieve better performance.