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 use fromFoldable
, as it has better performance. Provided pipes like commitBatchWithin are also to be preferred, as they also achieve better performance.
Attributes
- Companion
- object
- Source
- CommittableOffsetBatch.scala
- Graph
-
- Supertypes