|
PostgreSQL Source Code git master
|


Go to the source code of this file.
Typedefs | |
| typedef struct SnapBuild | SnapBuild |
Enumerations | |
| enum | SnapBuildState { SNAPBUILD_START = -1 , SNAPBUILD_BUILDING_SNAPSHOT = 0 , SNAPBUILD_FULL_SNAPSHOT = 1 , SNAPBUILD_CONSISTENT = 2 } |
| Enumerator | |
|---|---|
| SNAPBUILD_START | |
| SNAPBUILD_BUILDING_SNAPSHOT | |
| SNAPBUILD_FULL_SNAPSHOT | |
| SNAPBUILD_CONSISTENT | |
Definition at line 22 of file snapbuild.h.
|
extern |
Definition at line 185 of file snapbuild.c.
References ALLOCSET_DEFAULT_SIZES, AllocSetContextCreate, SnapBuild::building_full_snapshot, SnapBuild::catchange, SnapBuild::committed, SnapBuild::context, CurrentMemoryContext, fb(), SnapBuild::in_slot_creation, SnapBuild::includes_all_transactions, SnapBuild::initial_xmin_horizon, MemoryContextSwitchTo(), palloc0(), palloc0_object, SnapBuild::reorder, SNAPBUILD_START, SnapBuild::start_decoding_at, SnapBuild::state, SnapBuild::two_phase_at, SnapBuild::xcnt, SnapBuild::xcnt_space, and SnapBuild::xip.
Referenced by StartupDecodingContext().
Definition at line 1969 of file snapbuild.c.
References AllocateDir(), DEBUG1, elog, ereport, errcode_for_file_access(), errmsg(), fb(), FreeDir(), get_dirent_type(), GetRedoRecPtr(), LOG, MAXPGPATH, PG_LOGICAL_SNAPSHOTS_DIR, PGFILETYPE_ERROR, PGFILETYPE_REG, ReadDir(), ReplicationSlotsComputeLogicalRestartLSN(), snprintf, and XLogRecPtrIsValid.
Referenced by CheckPointGuts().
Definition at line 233 of file snapbuild.c.
References SnapBuild::context, fb(), MemoryContextDelete(), SnapBuildSnapDecRefcount(), and SnapBuild::snapshot.
Referenced by FreeDecodingContext().
Definition at line 599 of file snapbuild.c.
References AbortCurrentTransaction(), CurrentResourceOwner, elog, ERROR, ExportInProgress, fb(), IsTransactionState(), and SavedResourceOwnerDuringExport.
Referenced by exec_replication_command().
|
extern |
Definition at line 939 of file snapbuild.c.
References Assert, SnapBuild::building_full_snapshot, SnapBuild::committed, DEBUG1, DEBUG2, elog, fb(), SnapBuild::includes_all_transactions, SnapBuild::next_phase_at, NormalTransactionIdFollows, SnapBuild::reorder, ReorderBufferSetBaseSnapshot(), ReorderBufferXidHasBaseSnapshot(), SNAPBUILD_BUILDING_SNAPSHOT, SNAPBUILD_CONSISTENT, SNAPBUILD_FULL_SNAPSHOT, SNAPBUILD_START, SnapBuildAddCommittedTxn(), SnapBuildBuildSnapshot(), SnapBuildDistributeSnapshotAndInval(), SnapBuildSnapDecRefcount(), SnapBuildSnapIncRefcount(), SnapBuildXidHasCatalogChanges(), SnapBuild::snapshot, SnapBuild::start_decoding_at, SnapBuild::state, TransactionIdAdvance, TransactionIdFollowsOrEquals(), TransactionIdIsValid, TransactionIdPrecedes(), and SnapBuild::xmax.
Referenced by DecodeCommit().
|
extern |
Definition at line 277 of file snapbuild.c.
References SnapBuild::state.
Referenced by DecodePrepare(), DecodingContextReady(), heap2_decode(), heap_decode(), logicalmsg_decode(), ReorderBufferCanStartStreaming(), and xact_decode().
Definition at line 538 of file snapbuild.c.
References CurrentResourceOwner, elog, ereport, errmsg_plural(), ERROR, ExportInProgress, ExportSnapshot(), fb(), IsTransactionOrTransactionBlock(), LOG, SavedResourceOwnerDuringExport, SnapBuildInitialSnapshot(), StartTransactionCommand(), XACT_REPEATABLE_READ, XactIsoLevel, and XactReadOnly.
Referenced by CreateReplicationSlot().
Definition at line 578 of file snapbuild.c.
References Assert, fb(), SNAPBUILD_CONSISTENT, SnapBuildBuildSnapshot(), SnapBuildSnapIncRefcount(), SnapBuild::snapshot, and SnapBuild::state.
Referenced by logicalmsg_decode().
|
extern |
Definition at line 286 of file snapbuild.c.
References SnapBuild::two_phase_at.
Referenced by DecodeCommit().
Definition at line 440 of file snapbuild.c.
References Assert, SnapBuild::building_full_snapshot, SnapBuild::committed, elog, ereport, errcode(), ERRCODE_T_R_SERIALIZATION_FAILURE, errmsg(), ERROR, fb(), GetMaxSnapshotXidCount(), GetOldestSafeDecodingTransactionId(), HaveRegisteredOrActiveSnapshot(), HistoricSnapshotActive(), SnapBuild::includes_all_transactions, InvalidateCatalogSnapshot(), LW_SHARED, LWLockAcquire(), LWLockRelease(), MyProc, NormalTransactionIdPrecedes, palloc_array, SNAPBUILD_CONSISTENT, SnapBuildBuildSnapshot(), SNAPSHOT_MVCC, SnapBuild::state, test(), TransactionIdAdvance, TransactionIdFollows(), TransactionIdIsValid, XACT_REPEATABLE_READ, XactIsoLevel, xidComparator(), and PGPROC::xmin.
Referenced by CreateReplicationSlot(), and SnapBuildExportSnapshot().
|
extern |
Definition at line 638 of file snapbuild.c.
References fb(), SnapBuild::next_phase_at, SnapBuild::reorder, ReorderBufferSetBaseSnapshot(), ReorderBufferXidHasBaseSnapshot(), SNAPBUILD_CONSISTENT, SNAPBUILD_FULL_SNAPSHOT, SnapBuildBuildSnapshot(), SnapBuildSnapIncRefcount(), SnapBuild::snapshot, SnapBuild::state, and TransactionIdPrecedes().
Referenced by heap2_decode(), heap_decode(), and logicalmsg_decode().
|
extern |
Definition at line 688 of file snapbuild.c.
References elog, ERROR, fb(), InvalidCommandId, Max, SnapBuild::reorder, ReorderBufferAddNewCommandId(), ReorderBufferAddNewTupleCids(), and ReorderBufferXidSetCatalogChanges().
Referenced by heap2_decode().
|
extern |
Definition at line 1135 of file snapbuild.c.
References ReorderBuffer::current_restart_decoding_lsn, DEBUG3, elog, fb(), InvalidTransactionId, SnapBuild::last_serialized_snapshot, LogicalIncreaseRestartDecodingForSlot(), LogicalIncreaseXminForSlot(), xl_running_xacts::oldestRunningXid, SnapBuild::reorder, ReorderBufferGetOldestTXN(), ReorderBufferGetOldestXmin(), ReorderBufferTXN::restart_decoding_lsn, SNAPBUILD_CONSISTENT, SnapBuildFindSnapshot(), SnapBuildPurgeOlderTxn(), SnapBuildSerialize(), SnapBuild::state, XLogRecPtrIsValid, SnapBuild::xmax, and SnapBuild::xmin.
Referenced by standby_decode().
Definition at line 626 of file snapbuild.c.
References ExportInProgress, fb(), and SavedResourceOwnerDuringExport.
Referenced by AbortTransaction().
|
extern |
Definition at line 1483 of file snapbuild.c.
References SNAPBUILD_CONSISTENT, SnapBuildRestore(), SnapBuildSerialize(), and SnapBuild::state.
Referenced by xlog_decode().
|
extern |
Definition at line 295 of file snapbuild.c.
References SnapBuild::two_phase_at.
Referenced by CreateDecodingContext().
Definition at line 328 of file snapbuild.c.
References Assert, elog, ERROR, fb(), FirstCommandId, SnapBuildFreeSnapshot(), and SNAPSHOT_HISTORIC_MVCC.
Referenced by FreeSnapshotBuilder(), ReorderBufferCleanupTXN(), ReorderBufferFreeSnap(), ReorderBufferTransferSnapToParent(), SnapBuildCommitTxn(), and SnapBuildRestore().
|
extern |
Definition at line 2057 of file snapbuild.c.
References ereport, errcode_for_file_access(), errmsg(), ERROR, fb(), LSN_FORMAT_ARGS, MAXPGPATH, PG_LOGICAL_SNAPSHOTS_DIR, sprintf, and stat.
Referenced by update_local_synced_slot().
|
extern |
Definition at line 304 of file snapbuild.c.
References SnapBuild::start_decoding_at.
Referenced by AssertTXNLsnOrder(), DecodeTXNNeedSkip(), logicalmsg_decode(), and ReorderBufferCanStartStreaming().