Snapshot Management

PostgreSQL's MVCC snapshot infrastructure — `src/backend/utils/time/snapmgr.c` — `GetTransactionSnapshot` / `GetLatestSnapshot` / `PushActiveSnapshot` / `RegisterSnapshot` and the tuple-visibility machinery in `heapam_visibility.c`. Covers the ActiveSnapshot stack, RegisteredSnapshots heap, snapshot export for parallel workers, historic snapshots for logical decoding, and the interaction with xmin horizon. Loads when the user asks about `Snapshot` semantics, MVCC visibility (`HeapTupleSatisfiesMVCC`), catalog snapshots vs transaction snapshots, isolation levels, exported snapshots for pg_dump, or `SET LOCAL transaction_isolation`. Skip when the ask is about xact.c commit/abort mechanics or about xid horizons for freezing (see `vacuum-autovacuum`).

matejformanek Updated

File contents

matejformanek/postgres-claude/tree/main/.claude/skills/snapshot-management commit 254cf18641

Frequently asked questions

npx skillmds@latest add matejformanek/snapshot-management