Model a set of read-only queries to a database as a snapshot.
Classes
Snapshot
Snapshot(
session,
read_timestamp=None,
min_read_timestamp=None,
max_staleness=None,
exact_staleness=None,
multi_use=False,
transaction_id=None,
)
Allow a set of reads / SQL statements with shared staleness.
If no options are passed, reads will use the strong
model, reading
at a timestamp where all previously committed transactions are visible.
Parameters | |
---|---|
Name | Description |
session |
Session
The session used to perform the commit. |
read_timestamp |
Execute all reads at the given timestamp. |
min_read_timestamp |
Execute all reads at a timestamp >= |
max_staleness |
Read data at a timestamp >= NOW - |
exact_staleness |
Execute all reads at a timestamp that is |
multi_use |
If true, multiple |