Glossary
Sync cursor
What a sync cursor is, why Clivly orders changes by a column in your table, and how a sync picks up where it stopped.
A sync cursor is the saved position in your table up to which Clivly has read. Each run starts from the cursor, reads the rows that changed since then, and saves the new position. That is how a run picks up where the last one stopped.
The column it uses
The cursor is an updatedAt-style column. It is paired with the row's id so
rows changed at the same moment still have a stable order. You name the column
in the source config:
source: {
contacts: fromDrizzle(db, participants, { cursorField: "updatedAt" }),
}
When a sync is interrupted
The saved cursor is the last row Clivly confirmed. The next run resumes from there, so an interrupted sync does not restart from the top of the table.
Checking it
npx clivly status reports whether the cursor is saved. See
Sync & cursors for the full behaviour.
Related: Contact entity.