#[non_exhaustive]pub enum Commit {
Auto,
Tracked,
Transactional(String),
}Expand description
How processed deliveries are committed back to the consumer group.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
Auto
librdkafka auto-commit, the librdkafka default: positions are stored as messages are
handed to the application and committed every auto.commit.interval.ms. ack and
nack are advisory no-ops; a crash can lose the tail of processed-but-uncommitted work
or skip unprocessed deliveries that were already stored.
Tracked
Per-message acknowledgement: enable.auto.offset.store is switched off and an ack
advances the stored position to just below the lowest still-unsettled delivery (or to
the highest delivered offset once none are outstanding). At-least-once stays precise
with concurrent handler lanes, and offset gaps the consumer never receives (transaction
markers, compacted-away records) cannot block the position. Auto-commit still flushes
the stored position in the background and once more when the consumer closes.
Transactional(String)
Exactly-once: the consumer never commits its own offsets - the
EosPipeline whose transactional id matches this name commits
them through the producer transaction (send_offsets_to_transaction), so source
positions move atomically with the records the handlers publish. enable.auto.commit
and enable.auto.offset.store are switched off; ack advances the shared watermark
exactly like Tracked, and the pipeline picks the watermark up at its
next window commit.