PostgresCheckpointStore
The CheckpointStore on PostgreSQL: one row per (group, subscription, partition) in wow_checkpoint.
A save is one autocommitted upsert whose update applies only when the new position is higher, so concurrent saves leave the highest and a lower one changes nothing. JDBC calls run on dispatcher, virtual threads by default.
Constructors
Functions
Claims the table's format (PostgresFormat) and creates it when missing.
The upserts save makes one by one, as one multi-row upsert in one transaction: one statement, whose round trip also carries the transaction's bound, and one commit, one WAL flush (in autocommit each upsert of a batch was a transaction of its own). A key saved twice keeps its furthest position, as one statement may touch a row once. The rows go in key order, so two batches touching the same rows lock them in the same order and never wait on each other in a cycle; past MAX_ROWS they are split into several statements of the one transaction. A failed batch commits none of them, and the caller saves them again, as it saves any batch that failed: each upsert only moves a position forward.