232#define TargetTagIsCoveredBy(covered_target, covering_target) \
233 ((GET_PREDICATELOCKTARGETTAG_RELATION(covered_target) == \
234 GET_PREDICATELOCKTARGETTAG_RELATION(covering_target)) \
235 && (GET_PREDICATELOCKTARGETTAG_OFFSET(covering_target) == \
236 InvalidOffsetNumber) \
237 && (((GET_PREDICATELOCKTARGETTAG_OFFSET(covered_target) != \
238 InvalidOffsetNumber) \
239 && (GET_PREDICATELOCKTARGETTAG_PAGE(covering_target) == \
240 GET_PREDICATELOCKTARGETTAG_PAGE(covered_target))) \
241 || ((GET_PREDICATELOCKTARGETTAG_PAGE(covering_target) == \
242 InvalidBlockNumber) \
243 && (GET_PREDICATELOCKTARGETTAG_PAGE(covered_target) \
244 != InvalidBlockNumber))) \
245 && (GET_PREDICATELOCKTARGETTAG_DB(covered_target) == \
246 GET_PREDICATELOCKTARGETTAG_DB(covering_target)))
255#define PredicateLockHashPartition(hashcode) \
256 ((hashcode) % NUM_PREDICATELOCK_PARTITIONS)
257#define PredicateLockHashPartitionLock(hashcode) \
258 (&MainLWLockArray[PREDICATELOCK_MANAGER_LWLOCK_OFFSET + \
259 PredicateLockHashPartition(hashcode)].lock)
260#define PredicateLockHashPartitionLockByIndex(i) \
261 (&MainLWLockArray[PREDICATELOCK_MANAGER_LWLOCK_OFFSET + (i)].lock)
263#define NPREDICATELOCKTARGETENTS() \
264 mul_size(max_predicate_locks_per_xact, add_size(MaxBackends, max_prepared_xacts))
266#define SxactIsOnFinishedList(sxact) (!dlist_node_is_detached(&(sxact)->finishedLink))
276#define SxactIsCommitted(sxact) (((sxact)->flags & SXACT_FLAG_COMMITTED) != 0)
277#define SxactIsPrepared(sxact) (((sxact)->flags & SXACT_FLAG_PREPARED) != 0)
278#define SxactIsRolledBack(sxact) (((sxact)->flags & SXACT_FLAG_ROLLED_BACK) != 0)
279#define SxactIsDoomed(sxact) (((sxact)->flags & SXACT_FLAG_DOOMED) != 0)
280#define SxactIsReadOnly(sxact) (((sxact)->flags & SXACT_FLAG_READ_ONLY) != 0)
281#define SxactHasSummaryConflictIn(sxact) (((sxact)->flags & SXACT_FLAG_SUMMARY_CONFLICT_IN) != 0)
282#define SxactHasSummaryConflictOut(sxact) (((sxact)->flags & SXACT_FLAG_SUMMARY_CONFLICT_OUT) != 0)
288#define SxactHasConflictOut(sxact) (((sxact)->flags & SXACT_FLAG_CONFLICT_OUT) != 0)
289#define SxactIsDeferrableWaiting(sxact) (((sxact)->flags & SXACT_FLAG_DEFERRABLE_WAITING) != 0)
290#define SxactIsROSafe(sxact) (((sxact)->flags & SXACT_FLAG_RO_SAFE) != 0)
291#define SxactIsROUnsafe(sxact) (((sxact)->flags & SXACT_FLAG_RO_UNSAFE) != 0)
292#define SxactIsPartiallyReleased(sxact) (((sxact)->flags & SXACT_FLAG_PARTIALLY_RELEASED) != 0)
302#define PredicateLockTargetTagHashCode(predicatelocktargettag) \
303 get_hash_value(PredicateLockTargetHash, predicatelocktargettag)
315#define PredicateLockHashCodeFromTargetHashCode(predicatelocktag, targethash) \
316 ((targethash) ^ ((uint32) PointerGetDatum((predicatelocktag)->myXact)) \
317 << LOG2_NUM_PREDICATELOCK_PARTITIONS)
328#define SerialSlruCtl (&SerialSlruDesc)
330#define SERIAL_PAGESIZE BLCKSZ
331#define SERIAL_ENTRYSIZE sizeof(SerCommitSeqNo)
332#define SERIAL_ENTRIESPERPAGE (SERIAL_PAGESIZE / SERIAL_ENTRYSIZE)
337#define SERIAL_MAX_PAGE (MaxTransactionId / SERIAL_ENTRIESPERPAGE)
339#define SerialNextPage(page) (((page) >= SERIAL_MAX_PAGE) ? 0 : (page) + 1)
341#define SerialValue(slotno, xid) (*((SerCommitSeqNo *) \
342 (SerialSlruCtl->shared->page_buffer[slotno] + \
343 ((((uint32) (xid)) % SERIAL_ENTRIESPERPAGE) * SERIAL_ENTRYSIZE))))
345#define SerialPage(xid) (((uint32) (xid)) / SERIAL_ENTRIESPERPAGE)
667 errmsg(
"not enough elements in RWConflictPool to record a read/write conflict"),
668 errhint(
"You might need to run fewer transactions at a time or increase \"max_connections\".")));
692 errmsg(
"not enough elements in RWConflictPool to record a potential read/write conflict"),
693 errhint(
"You might need to run fewer transactions at a time or increase \"max_connections\".")));
764 return errdetail(
"Could not access serializable CSN of transaction %u.", xid);
767#ifdef USE_ASSERT_CHECKING
785 oldestXact -= 1U << 31;
1220 .
name =
"serializable",
1222 .long_segment_names =
false,
1233#ifdef USE_ASSERT_CHECKING
1535 errmsg_internal(
"deferrable snapshot was unsafe; trying a new one")));
1625 errmsg(
"cannot use serializable mode in a hot standby"),
1626 errdetail(
"\"default_transaction_isolation\" is set to \"serializable\"."),
1627 errhint(
"You can use \"SET default_transaction_isolation = 'repeatable read'\" to change the default.")));
1678 errmsg(
"a snapshot-importing transaction must not be READ ONLY DEFERRABLE")));
1714 elog(
ERROR,
"cannot establish serializable snapshot during a parallel operation");
1732#ifdef TEST_SUMMARIZE_SERIAL
1757 errmsg(
"could not import the requested snapshot"),
1758 errdetail(
"The source process with PID %d is not running anymore.",
1959 return (target !=
NULL);
2408 errmsg(
"out of shared memory"),
2409 errhint(
"You might need to increase \"%s\".",
"max_pred_locks_per_transaction")));
2423 errmsg(
"out of shared memory"),
2424 errhint(
"You might need to increase \"%s\".",
"max_pred_locks_per_transaction")));
2893 relId = relation->
rd_id;
3525 <=
roXact->SeqNo.lastCommitBeforeSnapshot))
3820 errmsg(
"out of shared memory"),
3821 errhint(
"You might need to increase \"%s\".",
"max_pred_locks_per_transaction")));
3931 errmsg(
"could not serialize access due to read/write dependencies among transactions"),
3932 errdetail_internal(
"Reason code: Canceled on identification as a pivot, during conflict out checking."),
3933 errhint(
"The transaction might succeed if retried.")));
3967 errmsg(
"could not serialize access due to read/write dependencies among transactions"),
3968 errdetail_internal(
"Reason code: Canceled on identification as a pivot, during conflict out checking."),
3969 errhint(
"The transaction might succeed if retried.")));
4000 errmsg(
"could not serialize access due to read/write dependencies among transactions"),
4002 errhint(
"The transaction might succeed if retried.")));
4008 errmsg(
"could not serialize access due to read/write dependencies among transactions"),
4009 errdetail_internal(
"Reason code: Canceled on identification as a pivot, with conflict out to old committed transaction %u.", xid),
4010 errhint(
"The transaction might succeed if retried.")));
4047 errmsg(
"could not serialize access due to read/write dependencies among transactions"),
4049 errhint(
"The transaction might succeed if retried.")));
4158 sxact->finishedBefore))
4171 sxact->finishedBefore))
4277 errmsg(
"could not serialize access due to read/write dependencies among transactions"),
4278 errdetail_internal(
"Reason code: Canceled on identification as a pivot, during conflict in checking."),
4279 errhint(
"The transaction might succeed if retried.")));
4525 ||
t2->prepareSeqNo <=
writer->commitSeqNo)
4570 ||
t0->commitSeqNo >=
writer->prepareSeqNo)
4572 ||
t0->SeqNo.lastCommitBeforeSnapshot >=
writer->prepareSeqNo))
4596 errmsg(
"could not serialize access due to read/write dependencies among transactions"),
4597 errdetail_internal(
"Reason code: Canceled on identification as a pivot, during write."),
4598 errhint(
"The transaction might succeed if retried.")));
4608 errmsg(
"could not serialize access due to read/write dependencies among transactions"),
4610 errhint(
"The transaction might succeed if retried.")));
4655 errmsg(
"could not serialize access due to read/write dependencies among transactions"),
4656 errdetail_internal(
"Reason code: Canceled on identification as a pivot, during commit attempt."),
4657 errhint(
"The transaction might succeed if retried.")));
4691 errmsg(
"could not serialize access due to read/write dependencies among transactions"),
4692 errdetail_internal(
"Reason code: Canceled on commit attempt with conflict in from prepared pivot."),
4693 errhint(
"The transaction might succeed if retried.")));
4748 &record,
sizeof(record));
4775 &record,
sizeof(record));
4868 errmsg(
"out of shared memory")));
4893 sxact->topXid = xid;
bool ParallelContextActive(void)
#define InvalidBlockNumber
static bool BlockNumberIsValid(BlockNumber blockNumber)
#define unconstify(underlying_type, expr)
#define PG_USED_FOR_ASSERTS_ONLY
#define Assert(condition)
uint32 LocalTransactionId
void * hash_search(HTAB *hashp, const void *keyPtr, HASHACTION action, bool *foundPtr)
HTAB * hash_create(const char *tabname, int64 nelem, const HASHCTL *info, int flags)
void hash_destroy(HTAB *hashp)
void * hash_search_with_hash_value(HTAB *hashp, const void *keyPtr, uint32 hashvalue, HASHACTION action, bool *foundPtr)
void * hash_seq_search(HASH_SEQ_STATUS *status)
int64 hash_get_num_entries(HTAB *hashp)
void hash_seq_init(HASH_SEQ_STATUS *status, HTAB *hashp)
int errcode(int sqlerrcode)
int int errdetail_internal(const char *fmt,...) pg_attribute_printf(1
int errhint(const char *fmt,...) pg_attribute_printf(1
int errdetail(const char *fmt,...) pg_attribute_printf(1
int int errmsg_internal(const char *fmt,...) pg_attribute_printf(1
#define ereport(elevel,...)
#define palloc_object(type)
#define palloc_array(type, count)
static dlist_node * dlist_pop_head_node(dlist_head *head)
#define dlist_foreach(iter, lhead)
static void dlist_init(dlist_head *head)
#define dlist_head_element(type, membername, lhead)
static void dlist_delete_thoroughly(dlist_node *node)
static void dlist_delete(dlist_node *node)
#define dlist_foreach_modify(iter, lhead)
static bool dlist_is_empty(const dlist_head *head)
static void dlist_push_tail(dlist_head *head, dlist_node *node)
static void dlist_node_init(dlist_node *node)
#define dlist_container(type, membername, ptr)
#define IsParallelWorker()
static OffsetNumber ItemPointerGetOffsetNumber(const ItemPointerData *pointer)
static BlockNumber ItemPointerGetBlockNumber(const ItemPointerData *pointer)
#define GET_VXID_FROM_PGPROC(vxid_dst, proc)
#define SetInvalidVirtualTransactionId(vxid)
bool LWLockHeldByMe(LWLock *lock)
bool LWLockAcquire(LWLock *lock, LWLockMode mode)
bool LWLockHeldByMeInMode(LWLock *lock, LWLockMode mode)
void LWLockRelease(LWLock *lock)
void LWLockInitialize(LWLock *lock, int tranche_id)
#define NUM_PREDICATELOCK_PARTITIONS
#define SLRU_PAGES_PER_SEGMENT
static bool pg_lfind32(uint32 key, const uint32 *base, uint32 nelem)
static rewind_source * source
#define ERRCODE_T_R_SERIALIZATION_FAILURE
PredicateLockData * GetPredicateLockStatusData(void)
void CheckPointPredicate(void)
void PredicateLockPageSplit(Relation relation, BlockNumber oldblkno, BlockNumber newblkno)
static void DecrementParentLocks(const PREDICATELOCKTARGETTAG *targettag)
static HTAB * PredicateLockHash
static void SetPossibleUnsafeConflict(SERIALIZABLEXACT *roXact, SERIALIZABLEXACT *activeXact)
#define PredicateLockTargetTagHashCode(predicatelocktargettag)
static void SetNewSxactGlobalXmin(void)
void CheckForSerializableConflictIn(Relation relation, const ItemPointerData *tid, BlockNumber blkno)
static void ReleasePredXact(SERIALIZABLEXACT *sxact)
static void PredicateLockShmemInit(void *arg)
void SetSerializableTransactionSnapshot(Snapshot snapshot, VirtualTransactionId *sourcevxid, int sourcepid)
static bool RWConflictExists(const SERIALIZABLEXACT *reader, const SERIALIZABLEXACT *writer)
static bool PredicateLockingNeededForRelation(Relation relation)
static bool SerializationNeededForRead(Relation relation, Snapshot snapshot)
static Snapshot GetSafeSnapshot(Snapshot origSnapshot)
#define SxactIsCommitted(sxact)
static SerialControl serialControl
void PredicateLockPage(Relation relation, BlockNumber blkno, Snapshot snapshot)
#define SxactIsROUnsafe(sxact)
static Snapshot GetSerializableTransactionSnapshotInt(Snapshot snapshot, VirtualTransactionId *sourcevxid, int sourcepid)
static LWLock * ScratchPartitionLock
static void PredicateLockAcquire(const PREDICATELOCKTARGETTAG *targettag)
#define SxactIsDeferrableWaiting(sxact)
static void ReleasePredicateLocksLocal(void)
static HTAB * LocalPredicateLockHash
int max_predicate_locks_per_page
struct SerialControlData * SerialControl
static PredXactList PredXact
static void SetRWConflict(SERIALIZABLEXACT *reader, SERIALIZABLEXACT *writer)
int GetSafeSnapshotBlockingPids(int blocked_pid, int *output, int output_size)
static uint32 ScratchTargetTagHash
static void RemoveTargetIfNoLongerUsed(PREDICATELOCKTARGET *target, uint32 targettaghash)
static uint32 predicatelock_hash(const void *key, Size keysize)
void CheckForSerializableConflictOut(Relation relation, TransactionId xid, Snapshot snapshot)
static int64 max_serializable_xacts
#define SxactIsReadOnly(sxact)
#define SerialNextPage(page)
static void DropAllPredicateLocksFromTable(Relation relation, bool transfer)
bool PageIsPredicateLocked(Relation relation, BlockNumber blkno)
static int serial_errdetail_for_io_error(const void *opaque_data)
static void CreatePredicateLock(const PREDICATELOCKTARGETTAG *targettag, uint32 targettaghash, SERIALIZABLEXACT *sxact)
static void SerialAdd(TransactionId xid, SerCommitSeqNo minConflictCommitSeqNo)
static void ClearOldPredicateLocks(void)
#define SxactHasSummaryConflictIn(sxact)
static SERIALIZABLEXACT * CreatePredXact(void)
static bool GetParentPredicateLockTag(const PREDICATELOCKTARGETTAG *tag, PREDICATELOCKTARGETTAG *parent)
#define PredicateLockHashCodeFromTargetHashCode(predicatelocktag, targethash)
static void RestoreScratchTarget(bool lockheld)
#define SerialValue(slotno, xid)
static void DeleteChildTargetLocks(const PREDICATELOCKTARGETTAG *newtargettag)
static void DeleteLockTarget(PREDICATELOCKTARGET *target, uint32 targettaghash)
void PredicateLockTwoPhaseFinish(FullTransactionId fxid, bool isCommit)
void predicatelock_twophase_recover(FullTransactionId fxid, uint16 info, void *recdata, uint32 len)
static SlruDesc SerialSlruDesc
static SERIALIZABLEXACT * OldCommittedSxact
#define SxactHasConflictOut(sxact)
static bool MyXactDidWrite
static int MaxPredicateChildLocks(const PREDICATELOCKTARGETTAG *tag)
static void FlagSxactUnsafe(SERIALIZABLEXACT *sxact)
static void PredicateLockShmemRequest(void *arg)
void CheckTableForSerializableConflictIn(Relation relation)
#define SxactIsPrepared(sxact)
void AttachSerializableXact(SerializableXactHandle handle)
SerializableXactHandle ShareSerializableXact(void)
static bool PredicateLockExists(const PREDICATELOCKTARGETTAG *targettag)
static void RemoveScratchTarget(bool lockheld)
#define SxactIsOnFinishedList(sxact)
#define SxactIsPartiallyReleased(sxact)
static void SerialSetActiveSerXmin(TransactionId xid)
static dlist_head * FinishedSerializableTransactions
static bool SerializationNeededForWrite(Relation relation)
static HTAB * SerializableXidHash
static bool CheckAndPromotePredicateLockRequest(const PREDICATELOCKTARGETTAG *reqtag)
void PredicateLockPageCombine(Relation relation, BlockNumber oldblkno, BlockNumber newblkno)
static bool SerialPagePrecedesLogically(int64 page1, int64 page2)
static void CheckTargetForConflictsIn(PREDICATELOCKTARGETTAG *targettag)
int max_predicate_locks_per_relation
#define SxactIsROSafe(sxact)
void PreCommit_CheckForSerializationFailure(void)
void ReleasePredicateLocks(bool isCommit, bool isReadOnlySafe)
static void FlagRWConflict(SERIALIZABLEXACT *reader, SERIALIZABLEXACT *writer)
static const PREDICATELOCKTARGETTAG ScratchTargetTag
#define PredicateLockHashPartitionLockByIndex(i)
static void OnConflict_CheckForSerializationFailure(const SERIALIZABLEXACT *reader, SERIALIZABLEXACT *writer)
static bool CoarserLockCovers(const PREDICATELOCKTARGETTAG *newtargettag)
void PredicateLockRelation(Relation relation, Snapshot snapshot)
static SERIALIZABLEXACT * MySerializableXact
void PredicateLockTID(Relation relation, const ItemPointerData *tid, Snapshot snapshot, TransactionId tuple_xid)
#define SxactIsDoomed(sxact)
#define NPREDICATELOCKTARGETENTS()
static SerCommitSeqNo SerialGetMinConflictCommitSeqNo(TransactionId xid)
static void SummarizeOldestCommittedSxact(void)
const ShmemCallbacks PredicateLockShmemCallbacks
bool check_serial_buffers(int *newval, void **extra, GucSource source)
void PostPrepare_PredicateLocks(FullTransactionId fxid)
#define TargetTagIsCoveredBy(covered_target, covering_target)
static RWConflictPoolHeader RWConflictPool
static void ReleaseRWConflict(RWConflict conflict)
static bool TransferPredicateLocksToNewTarget(PREDICATELOCKTARGETTAG oldtargettag, PREDICATELOCKTARGETTAG newtargettag, bool removeOld)
void AtPrepare_PredicateLocks(void)
void RegisterPredicateLockingXid(TransactionId xid)
#define PredicateLockHashPartitionLock(hashcode)
#define SERIAL_ENTRIESPERPAGE
static bool XidIsConcurrent(TransactionId xid)
static void ReleaseOneSerializableXact(SERIALIZABLEXACT *sxact, bool partial, bool summarize)
static HTAB * PredicateLockTargetHash
bool CheckForSerializableConflictOutNeeded(Relation relation, Snapshot snapshot)
#define SxactIsRolledBack(sxact)
static SERIALIZABLEXACT * SavedSerializableXact
#define SxactHasSummaryConflictOut(sxact)
static void PredicateLockShmemAttach(void *arg)
void TransferPredicateLocksToHeapRelation(Relation relation)
static void CreateLocalPredicateLockHash(void)
int max_predicate_locks_per_xact
Snapshot GetSerializableTransactionSnapshot(Snapshot snapshot)
void * SerializableXactHandle
#define RWConflictDataSize
#define SXACT_FLAG_DEFERRABLE_WAITING
#define SXACT_FLAG_SUMMARY_CONFLICT_IN
@ TWOPHASEPREDICATERECORD_XACT
@ TWOPHASEPREDICATERECORD_LOCK
#define FirstNormalSerCommitSeqNo
#define InvalidSerCommitSeqNo
#define SXACT_FLAG_CONFLICT_OUT
#define PredXactListDataSize
#define SXACT_FLAG_READ_ONLY
#define SXACT_FLAG_DOOMED
#define GET_PREDICATELOCKTARGETTAG_DB(locktag)
#define GET_PREDICATELOCKTARGETTAG_RELATION(locktag)
#define RWConflictPoolHeaderDataSize
#define InvalidSerializableXact
#define SET_PREDICATELOCKTARGETTAG_PAGE(locktag, dboid, reloid, blocknum)
#define RecoverySerCommitSeqNo
struct RWConflictData * RWConflict
#define GET_PREDICATELOCKTARGETTAG_TYPE(locktag)
#define SET_PREDICATELOCKTARGETTAG_RELATION(locktag, dboid, reloid)
#define SXACT_FLAG_ROLLED_BACK
#define SXACT_FLAG_COMMITTED
#define SXACT_FLAG_RO_UNSAFE
#define SXACT_FLAG_PREPARED
#define SET_PREDICATELOCKTARGETTAG_TUPLE(locktag, dboid, reloid, blocknum, offnum)
#define SXACT_FLAG_PARTIALLY_RELEASED
#define GET_PREDICATELOCKTARGETTAG_PAGE(locktag)
#define SXACT_FLAG_RO_SAFE
#define SXACT_FLAG_SUMMARY_CONFLICT_OUT
#define GET_PREDICATELOCKTARGETTAG_OFFSET(locktag)
Snapshot GetSnapshotData(Snapshot snapshot)
bool ProcArrayInstallImportedXmin(TransactionId xmin, VirtualTransactionId *sourcevxid)
#define INVALID_PROC_NUMBER
#define RelationUsesLocalBuffers(relation)
bool ShmemAddrIsValid(const void *addr)
Size add_size(Size s1, Size s2)
Size mul_size(Size s1, Size s2)
#define ShmemRequestHash(...)
#define ShmemRequestStruct(...)
int SimpleLruReadPage_ReadOnly(SlruDesc *ctl, int64 pageno, const void *opaque_data)
void SimpleLruTruncate(SlruDesc *ctl, int64 cutoffPage)
int SimpleLruZeroPage(SlruDesc *ctl, int64 pageno)
void SimpleLruWriteAll(SlruDesc *ctl, bool allow_redirtied)
int SimpleLruReadPage(SlruDesc *ctl, int64 pageno, bool write_ok, const void *opaque_data)
bool check_slru_buffers(const char *name, int *newval)
#define SlruPagePrecedesUnitTests(ctl, per_page)
#define SimpleLruRequest(...)
static LWLock * SimpleLruGetBankLock(SlruDesc *ctl, int64 pageno)
Snapshot GetTransactionSnapshot(void)
#define IsMVCCSnapshot(snapshot)
void ProcSendSignal(ProcNumber procNumber)
void ProcWaitForSignal(uint32 wait_event_info)
SERIALIZABLEXACT * myXact
PREDICATELOCKTARGET * myTarget
PREDICATELOCKTARGETTAG tag
dlist_head predicateLocks
SerCommitSeqNo commitSeqNo
SERIALIZABLEXACT * element
SerCommitSeqNo LastSxactCommitSeqNo
SerCommitSeqNo CanPartialClearThrough
SERIALIZABLEXACT * OldCommittedSxact
SerCommitSeqNo HavePartialClearedThrough
TransactionId SxactGlobalXmin
RelFileLocator rd_locator
VirtualTransactionId vxid
LWLock perXactPredicateListLock
SerCommitSeqNo lastCommitBeforeSnapshot
dlist_head possibleUnsafeConflicts
SerCommitSeqNo prepareSeqNo
dlist_head predicateLocks
SerCommitSeqNo commitSeqNo
union SERIALIZABLEXACT::@134 SeqNo
TransactionId finishedBefore
SerCommitSeqNo earliestOutConflictCommit
ShmemRequestCallback request_fn
FullTransactionId nextXid
PREDICATELOCKTARGETTAG target
TwoPhasePredicateRecordType type
TwoPhasePredicateLockRecord lockRecord
union TwoPhasePredicateRecord::@135 data
TwoPhasePredicateXactRecord xactRecord
static bool TransactionIdFollows(TransactionId id1, TransactionId id2)
#define FirstUnpinnedObjectId
#define InvalidTransactionId
static bool TransactionIdPrecedesOrEquals(TransactionId id1, TransactionId id2)
static bool TransactionIdFollowsOrEquals(TransactionId id1, TransactionId id2)
#define TransactionIdEquals(id1, id2)
#define XidFromFullTransactionId(x)
#define FirstNormalTransactionId
#define TransactionIdIsValid(xid)
static bool TransactionIdPrecedes(TransactionId id1, TransactionId id2)
void RegisterTwoPhaseRecord(TwoPhaseRmgrId rmid, uint16 info, const void *data, uint32 len)
#define TWOPHASE_RM_PREDICATELOCK_ID
TransamVariablesData * TransamVariables
TransactionId GetTopTransactionIdIfAny(void)
bool IsSubTransaction(void)
bool TransactionIdIsCurrentTransactionId(TransactionId xid)
bool IsInParallelMode(void)
#define IsolationIsSerializable()
bool RecoveryInProgress(void)