|
PostgreSQL Source Code git master
|


Go to the source code of this file.
Data Structures | |
| struct | sqlparseInfo |
| struct | _archiveHandle |
| struct | _tocEntry |
| struct | _archiveOpts |
Enumerations | |
| enum | T_Action { ACT_DUMP , ACT_RESTORE } |
| enum | sqlparseState { SQL_SCAN = 0 , SQL_IN_SINGLE_QUOTE , SQL_IN_DOUBLE_QUOTE } |
| enum | ArchiverStage { STAGE_NONE = 0 , STAGE_INITIALIZING , STAGE_PROCESSING , STAGE_FINALIZING } |
| enum | ArchiverOutput { OUTPUT_SQLCMDS = 0 , OUTPUT_COPYDATA , OUTPUT_OTHERDATA } |
| enum | RestorePass { RESTORE_PASS_MAIN = 0 , RESTORE_PASS_ACL , RESTORE_PASS_POST_ACL } |
| #define appendByteaLiteralAHX | ( | buf, | |
| str, | |||
| len, | |||
| AH | |||
| ) | appendByteaLiteral(buf, str, len, (AH)->public.std_strings) |
Definition at line 431 of file pg_backup_archiver.h.
| #define appendStringLiteralAHX | ( | buf, | |
| str, | |||
| AH | |||
| ) | appendStringLiteral(buf, str, (AH)->public.encoding, (AH)->public.std_strings) |
Definition at line 428 of file pg_backup_archiver.h.
| #define ARCHIVE_MAJOR | ( | version | ) | (((version) >> 16) & 255) |
Definition at line 42 of file pg_backup_archiver.h.
| #define ARCHIVE_MINOR | ( | version | ) | (((version) >> 8) & 255) |
Definition at line 43 of file pg_backup_archiver.h.
| #define ARCHIVE_OPTS | ( | ... | ) | &(ArchiveOpts){__VA_ARGS__} |
Definition at line 410 of file pg_backup_archiver.h.
| #define ARCHIVE_REV | ( | version | ) | (((version) ) & 255) |
Definition at line 44 of file pg_backup_archiver.h.
| #define BLK_BLOBS 3 |
Definition at line 37 of file pg_backup_archiver.h.
| #define BLK_DATA 1 |
Definition at line 36 of file pg_backup_archiver.h.
| #define K_OFFSET_NO_DATA 3 |
Definition at line 77 of file pg_backup_archiver.h.
| #define K_OFFSET_POS_NOT_SET 1 |
Definition at line 75 of file pg_backup_archiver.h.
| #define K_OFFSET_POS_SET 2 |
Definition at line 76 of file pg_backup_archiver.h.
| #define K_VERS_1_0 MAKE_ARCHIVE_VERSION(1, 0, 0) |
Definition at line 47 of file pg_backup_archiver.h.
| #define K_VERS_1_10 MAKE_ARCHIVE_VERSION(1, 10, 0) /* add tablespace */ |
Definition at line 56 of file pg_backup_archiver.h.
| #define K_VERS_1_11 |
Definition at line 57 of file pg_backup_archiver.h.
| #define K_VERS_1_12 |
Definition at line 58 of file pg_backup_archiver.h.
| #define K_VERS_1_13 |
Definition at line 59 of file pg_backup_archiver.h.
| #define K_VERS_1_14 MAKE_ARCHIVE_VERSION(1, 14, 0) /* add tableam */ |
Definition at line 60 of file pg_backup_archiver.h.
| #define K_VERS_1_15 |
Definition at line 61 of file pg_backup_archiver.h.
| #define K_VERS_1_16 |
Definition at line 62 of file pg_backup_archiver.h.
| #define K_VERS_1_2 MAKE_ARCHIVE_VERSION(1, 2, 0) /* Allow No ZLIB */ |
Definition at line 48 of file pg_backup_archiver.h.
| #define K_VERS_1_3 MAKE_ARCHIVE_VERSION(1, 3, 0) /* BLOBS */ |
Definition at line 49 of file pg_backup_archiver.h.
| #define K_VERS_1_4 MAKE_ARCHIVE_VERSION(1, 4, 0) /* Date & name in header */ |
Definition at line 50 of file pg_backup_archiver.h.
| #define K_VERS_1_5 MAKE_ARCHIVE_VERSION(1, 5, 0) /* Handle dependencies */ |
Definition at line 51 of file pg_backup_archiver.h.
| #define K_VERS_1_6 MAKE_ARCHIVE_VERSION(1, 6, 0) /* Schema field in TOCs */ |
Definition at line 52 of file pg_backup_archiver.h.
| #define K_VERS_1_7 |
Definition at line 53 of file pg_backup_archiver.h.
| #define K_VERS_1_8 |
Definition at line 54 of file pg_backup_archiver.h.
| #define K_VERS_1_9 |
Definition at line 55 of file pg_backup_archiver.h.
| #define K_VERS_MAJOR 1 |
Definition at line 65 of file pg_backup_archiver.h.
| #define K_VERS_MAX MAKE_ARCHIVE_VERSION(K_VERS_MAJOR, K_VERS_MINOR, 255) |
Definition at line 71 of file pg_backup_archiver.h.
| #define K_VERS_MINOR 16 |
Definition at line 66 of file pg_backup_archiver.h.
| #define K_VERS_REV 0 |
Definition at line 67 of file pg_backup_archiver.h.
| #define K_VERS_SELF MAKE_ARCHIVE_VERSION(K_VERS_MAJOR, K_VERS_MINOR, K_VERS_REV) |
Definition at line 68 of file pg_backup_archiver.h.
| #define LOBBUFSIZE 16384 |
Definition at line 33 of file pg_backup_archiver.h.
Definition at line 40 of file pg_backup_archiver.h.
Definition at line 92 of file pg_backup_archiver.h.
Definition at line 200 of file pg_backup_archiver.h.
Definition at line 199 of file pg_backup_archiver.h.
Definition at line 202 of file pg_backup_archiver.h.
| #define REQ_STATS 0x04 |
Definition at line 201 of file pg_backup_archiver.h.
| #define RESTORE_PASS_LAST RESTORE_PASS_POST_ACL |
Definition at line 196 of file pg_backup_archiver.h.
| #define WORKER_CREATE_DONE 10 |
Definition at line 84 of file pg_backup_archiver.h.
| #define WORKER_IGNORED_ERRORS 12 |
Definition at line 86 of file pg_backup_archiver.h.
| #define WORKER_INHIBIT_DATA 11 |
Definition at line 85 of file pg_backup_archiver.h.
| #define WORKER_OK 0 |
Definition at line 83 of file pg_backup_archiver.h.
| #define WRITE_ERROR_EXIT |
Definition at line 100 of file pg_backup_archiver.h.
| typedef void(* ArchiveEntryPtrType) (ArchiveHandle *AH, TocEntry *te) |
Definition at line 113 of file pg_backup_archiver.h.
Definition at line 88 of file pg_backup_archiver.h.
| typedef void(* ClonePtrType) (ArchiveHandle *AH) |
Definition at line 134 of file pg_backup_archiver.h.
| typedef void(* ClosePtrType) (ArchiveHandle *AH) |
Definition at line 111 of file pg_backup_archiver.h.
Definition at line 140 of file pg_backup_archiver.h.
Definition at line 335 of file pg_backup_archiver.h.
| typedef void(* DeClonePtrType) (ArchiveHandle *AH) |
Definition at line 135 of file pg_backup_archiver.h.
Definition at line 334 of file pg_backup_archiver.h.
| typedef void(* EndDataPtrType) (ArchiveHandle *AH, TocEntry *te) |
Definition at line 117 of file pg_backup_archiver.h.
| typedef void(* EndLOPtrType) (ArchiveHandle *AH, TocEntry *te, Oid oid) |
Definition at line 121 of file pg_backup_archiver.h.
| typedef void(* EndLOsPtrType) (ArchiveHandle *AH, TocEntry *te) |
Definition at line 122 of file pg_backup_archiver.h.
| typedef void(* PrepParallelRestorePtrType) (ArchiveHandle *AH) |
Definition at line 133 of file pg_backup_archiver.h.
| typedef void(* PrintExtraTocPtrType) (ArchiveHandle *AH, TocEntry *te) |
Definition at line 130 of file pg_backup_archiver.h.
| typedef void(* PrintTocDataPtrType) (ArchiveHandle *AH, TocEntry *te) |
Definition at line 131 of file pg_backup_archiver.h.
Definition at line 127 of file pg_backup_archiver.h.
| typedef int(* ReadBytePtrType) (ArchiveHandle *AH) |
Definition at line 125 of file pg_backup_archiver.h.
| typedef void(* ReadExtraTocPtrType) (ArchiveHandle *AH, TocEntry *te) |
Definition at line 129 of file pg_backup_archiver.h.
| typedef void(* ReopenPtrType) (ArchiveHandle *AH) |
Definition at line 112 of file pg_backup_archiver.h.
| typedef void(* StartDataPtrType) (ArchiveHandle *AH, TocEntry *te) |
Definition at line 115 of file pg_backup_archiver.h.
| typedef void(* StartLOPtrType) (ArchiveHandle *AH, TocEntry *te, Oid oid) |
Definition at line 120 of file pg_backup_archiver.h.
| typedef void(* StartLOsPtrType) (ArchiveHandle *AH, TocEntry *te) |
Definition at line 119 of file pg_backup_archiver.h.
| typedef int(* WorkerJobDumpPtrType) (ArchiveHandle *AH, TocEntry *te) |
Definition at line 137 of file pg_backup_archiver.h.
| typedef int(* WorkerJobRestorePtrType) (ArchiveHandle *AH, TocEntry *te) |
Definition at line 138 of file pg_backup_archiver.h.
Definition at line 126 of file pg_backup_archiver.h.
Definition at line 124 of file pg_backup_archiver.h.
Definition at line 116 of file pg_backup_archiver.h.
| typedef void(* WriteExtraTocPtrType) (ArchiveHandle *AH, TocEntry *te) |
Definition at line 128 of file pg_backup_archiver.h.
| Enumerator | |
|---|---|
| OUTPUT_SQLCMDS | |
| OUTPUT_COPYDATA | |
| OUTPUT_OTHERDATA | |
Definition at line 164 of file pg_backup_archiver.h.
| Enumerator | |
|---|---|
| STAGE_NONE | |
| STAGE_INITIALIZING | |
| STAGE_PROCESSING | |
| STAGE_FINALIZING | |
Definition at line 156 of file pg_backup_archiver.h.
| Enumerator | |
|---|---|
| RESTORE_PASS_MAIN | |
| RESTORE_PASS_ACL | |
| RESTORE_PASS_POST_ACL | |
Definition at line 190 of file pg_backup_archiver.h.
| Enumerator | |
|---|---|
| SQL_SCAN | |
| SQL_IN_SINGLE_QUOTE | |
| SQL_IN_DOUBLE_QUOTE | |
Definition at line 142 of file pg_backup_archiver.h.
| Enumerator | |
|---|---|
| ACT_DUMP | |
| ACT_RESTORE | |
Definition at line 105 of file pg_backup_archiver.h.
| int ahprintf | ( | ArchiveHandle * | AH, |
| const char * | fmt, | ||
| ... | |||
| ) |
Definition at line 1849 of file pg_backup_archiver.c.
References _archiveHandle::CustomOutPtr, dump_lo_buf(), ExecuteSqlCommandBuf(), fb(), _archiveHandle::lo_buf, _archiveHandle::lo_buf_size, _archiveHandle::lo_buf_used, _archiveHandle::OF, _archiveHandle::public, remaining, RestoringToDB(), WRITE_ERROR_EXIT, and _archiveHandle::writingLO.
Referenced by _LoadLOs(), _PrintFileData(), _PrintFileData(), _PrintTocData(), _WriteData(), ahprintf(), and ReadDataFromArchiveNone().
|
extern |
Definition at line 1241 of file pg_backup_archiver.c.
References _archiveHandle::ArchiveEntryPtr, _tocEntry::catalogId, fb(), _archiveHandle::maxDumpId, _tocEntry::next, opts, pg_malloc(), pg_malloc0(), pg_strdup(), _tocEntry::prev, _archiveHandle::toc, _archiveHandle::tocCount, and true.
Referenced by dumpAccessMethod(), dumpACL(), dumpAgg(), dumpAttrDef(), dumpBaseType(), dumpCast(), dumpCollation(), dumpCommentExtended(), dumpCompositeType(), dumpCompositeTypeColComments(), dumpConstraint(), dumpConversion(), dumpDatabase(), dumpDefaultACL(), dumpDomain(), dumpDumpableObject(), dumpEncoding(), dumpEnumType(), dumpEventTrigger(), dumpExtension(), dumpForeignDataWrapper(), dumpForeignServer(), dumpFunc(), dumpIndex(), dumpIndexAttach(), dumpLO(), dumpNamespace(), dumpOpclass(), dumpOpfamily(), dumpOpr(), dumpPolicy(), dumpProcLang(), dumpPublication(), dumpPublicationNamespace(), dumpPublicationTable(), dumpRangeType(), dumpRelationStats(), dumpRule(), dumpSearchPath(), dumpSecLabel(), dumpSequence(), dumpSequenceData(), dumpShellType(), dumpStatisticsExt(), dumpStatisticsExtStats(), dumpStdStrings(), dumpSubscription(), dumpSubscriptionTable(), dumpTableAttach(), dumpTableComment(), dumpTableData(), dumpTableSchema(), dumpTableSecLabel(), dumpTransform(), dumpTrigger(), dumpTSConfig(), dumpTSDictionary(), dumpTSParser(), dumpTSTemplate(), dumpUndefinedType(), dumpUserMappings(), and refreshMatViewData().
Definition at line 4279 of file pg_backup_archiver.c.
References fb(), fseeko, and ftello.
Referenced by InitArchiveFmt_Custom(), and InitArchiveFmt_Tar().
|
extern |
Definition at line 5146 of file pg_backup_archiver.c.
References _doSetFixedOutputState(), archModeRead, Assert, ConnectDatabaseAhx(), fb(), _archiveHandle::mode, pg_malloc(), pg_strdup(), _archiveHandle::public, and Archive::ropt.
Referenced by RunWorker().
|
extern |
Definition at line 5210 of file pg_backup_archiver.c.
References Assert, _archiveHandle::connection, sqlparseInfo::curCmd, _archiveHandle::currSchema, _archiveHandle::currTableAm, _archiveHandle::currTablespace, _archiveHandle::currUser, _archiveHandle::DeClonePtr, destroyPQExpBuffer(), fb(), free, _archiveHandle::savedPassword, and _archiveHandle::sqlparse.
Referenced by RunWorker().
|
extern |
Definition at line 612 of file pg_backup_db.c.
References ahprintf().
Referenced by _StartLO(), RestoreArchive(), and StartRestoreLO().
|
extern |
Definition at line 1544 of file pg_backup_archiver.c.
References ahprintf(), _archiveHandle::connection, dump_lo_buf(), _archiveHandle::lo_buf_used, lo_close(), _archiveHandle::loFd, and _archiveHandle::writingLO.
Referenced by _LoadLOs(), _LoadLOs(), and _LoadLOs().
|
extern |
Definition at line 1471 of file pg_backup_archiver.c.
References ahprintf(), CommitTransaction(), _archiveHandle::connection, _archiveHandle::loCount, ngettext, pg_log_info, _archiveHandle::public, Archive::ropt, _restoreOptions::single_txn, and _restoreOptions::txn_size.
Referenced by _LoadLOs(), _LoadLOs(), and _LoadLOs().
| TocEntry * getTocEntryByDumpId | ( | ArchiveHandle * | AH, |
| DumpId | id | ||
| ) |
Definition at line 2029 of file pg_backup_archiver.c.
References buildTocEntryArrays(), fb(), and _archiveHandle::tocsByDumpId.
Referenced by _PrintTocData(), _tocEntryRequired(), IssueACLPerBlob(), parseWorkerCommand(), SortTocFromFile(), and TocIDRequired().
|
extern |
Definition at line 105 of file pg_backup_custom.c.
References _ArchiveEntry(), _Clone(), _CloseArchive(), _DeClone(), _EndData(), _EndLO(), _EndLOs(), _getFilePos(), _PrepParallelRestore(), _PrintExtraToc(), _PrintTocData(), _ReadBuf(), _ReadByte(), _ReadExtraToc(), _ReopenArchive(), _StartData(), _StartLO(), _StartLOs(), _WorkerJobRestoreCustom(), _WriteBuf(), _WriteByte(), _WriteData(), _WriteExtraToc(), _archiveHandle::ArchiveEntryPtr, archModeWrite, checkSeek(), _archiveHandle::ClonePtr, _archiveHandle::ClosePtr, _archiveHandle::DeClonePtr, _archiveHandle::EndDataPtr, _archiveHandle::EndLOPtr, _archiveHandle::EndLOsPtr, fb(), _archiveHandle::FH, _archiveHandle::formatData, _archiveHandle::fSpec, lclContext::hasSeek, lclContext::lastFilePos, _archiveHandle::mode, PG_BINARY_R, PG_BINARY_W, pg_fatal, pg_malloc0(), _archiveHandle::PrepParallelRestorePtr, _archiveHandle::PrintExtraTocPtr, _archiveHandle::PrintTocDataPtr, _archiveHandle::ReadBufPtr, _archiveHandle::ReadBytePtr, _archiveHandle::ReadExtraTocPtr, ReadHead(), ReadToc(), _archiveHandle::ReopenPtr, _archiveHandle::StartDataPtr, _archiveHandle::StartLOPtr, _archiveHandle::StartLOsPtr, _archiveHandle::WorkerJobDumpPtr, _archiveHandle::WorkerJobRestorePtr, _archiveHandle::WriteBufPtr, _archiveHandle::WriteBytePtr, _archiveHandle::WriteDataPtr, and _archiveHandle::WriteExtraTocPtr.
Referenced by _allocAH().
|
extern |
Definition at line 110 of file pg_backup_directory.c.
References _ArchiveEntry(), _Clone(), _CloseArchive(), _DeClone(), _EndData(), _EndLO(), _EndLOs(), _PrepParallelRestore(), _PrintExtraToc(), _PrintTocData(), _ReadBuf(), _ReadByte(), _ReadExtraToc(), _ReopenArchive(), _StartData(), _StartLO(), _StartLOs(), _WorkerJobDumpDirectory(), _WorkerJobRestoreDirectory(), _WriteBuf(), _WriteByte(), _WriteData(), _WriteExtraToc(), archDirectory, _archiveHandle::ArchiveEntryPtr, archModeWrite, archTar, _archiveHandle::ClonePtr, _archiveHandle::ClosePtr, create_or_open_dir(), lclContext::dataFH, _archiveHandle::DeClonePtr, lclContext::directory, EndCompressFileHandle(), _archiveHandle::EndDataPtr, _archiveHandle::EndLOPtr, _archiveHandle::EndLOsPtr, fb(), _archiveHandle::format, _archiveHandle::formatData, _archiveHandle::fSpec, InitDiscoverCompressFileHandle(), lclContext::LOsTocFH, MAXPGPATH, _archiveHandle::mode, PG_BINARY_R, pg_fatal, pg_malloc0(), _archiveHandle::PrepParallelRestorePtr, _archiveHandle::PrintExtraTocPtr, _archiveHandle::PrintTocDataPtr, _archiveHandle::ReadBufPtr, _archiveHandle::ReadBytePtr, _archiveHandle::ReadExtraTocPtr, ReadHead(), ReadToc(), _archiveHandle::ReopenPtr, setFilePath(), _archiveHandle::StartDataPtr, _archiveHandle::StartLOPtr, _archiveHandle::StartLOsPtr, _archiveHandle::WorkerJobDumpPtr, _archiveHandle::WorkerJobRestorePtr, _archiveHandle::WriteBufPtr, _archiveHandle::WriteBytePtr, _archiveHandle::WriteDataPtr, and _archiveHandle::WriteExtraTocPtr.
Referenced by _allocAH().
|
extern |
Definition at line 48 of file pg_backup_null.c.
References _CloseArchive(), _EndData(), _EndLO(), _EndLOs(), _PrintTocData(), _StartLO(), _StartLOs(), _WriteBuf(), _WriteByte(), _WriteData(), archModeRead, _archiveHandle::ClonePtr, _archiveHandle::ClosePtr, _archiveHandle::DeClonePtr, _archiveHandle::EndDataPtr, _archiveHandle::EndLOPtr, _archiveHandle::EndLOsPtr, fb(), _archiveHandle::mode, pg_fatal, _archiveHandle::PrintTocDataPtr, _archiveHandle::ReopenPtr, _archiveHandle::StartLOPtr, _archiveHandle::StartLOsPtr, _archiveHandle::WriteBufPtr, _archiveHandle::WriteBytePtr, and _archiveHandle::WriteDataPtr.
Referenced by _allocAH().
|
extern |
Definition at line 121 of file pg_backup_tar.c.
References _ArchiveEntry(), _CloseArchive(), _EndData(), _EndLO(), _EndLOs(), _PrintExtraToc(), _PrintTocData(), _ReadBuf(), _ReadByte(), _ReadExtraToc(), _StartData(), _StartLO(), _StartLOs(), _WriteBuf(), _WriteByte(), _WriteData(), _WriteExtraToc(), archModeWrite, checkSeek(), fb(), lclContext::FH, lclContext::filePos, lclContext::hasSeek, lclContext::isSpecialScript, PG_BINARY_R, PG_BINARY_W, PG_COMPRESSION_NONE, pg_fatal, pg_malloc0_object, ReadHead(), ReadToc(), tarClose(), lclContext::tarFH, lclContext::tarFHpos, and tarOpen().
Referenced by _allocAH().
|
extern |
Definition at line 538 of file pg_backup_db.c.
References Assert, buf, _tocEntry::defn, _tocEntry::dependencies, fb(), getTocEntryByDumpId(), IssueCommandPerBlob(), pg_fatal, pg_free(), and pg_strdup().
Referenced by _printTocEntry().
|
extern |
Definition at line 491 of file pg_backup_db.c.
References ahprintf(), buf, CommitTransaction(), _archiveHandle::connection, _tocEntry::defn, fb(), pg_free(), pg_strdup(), _archiveHandle::public, Archive::ropt, StartTransaction(), _restoreOptions::txn_size, and _archiveHandle::txnCount.
Referenced by _printTocEntry(), IssueACLPerBlob(), and RestoreArchive().
Definition at line 988 of file pg_backup_tar.c.
References fb(), read_tar_number(), TAR_OFFSET_CHECKSUM, TAR_OFFSET_MAGIC, TAR_OFFSET_VERSION, and tarChecksum().
Referenced by _discoverArchiveFormat().
Definition at line 330 of file parallel.c.
References ShutdownInformation::AHX, archive_close_connection(), on_exit_nicely(), and shutdown_info.
Referenced by main().
|
extern |
Definition at line 4779 of file pg_backup_archiver.c.
References Assert, _archiveHandle::connection, fb(), Archive::n_errors, _archiveHandle::public, and restore_toc_entry().
Referenced by _WorkerJobRestoreCustom(), and _WorkerJobRestoreDirectory().
|
extern |
Definition at line 4146 of file pg_backup_archiver.c.
References pg_compress_specification::algorithm, _archiveHandle::archdbname, _archiveHandle::archiveDumpVersion, _archiveHandle::archiveRemoteVersion, _archiveHandle::compression_spec, _archiveHandle::createDate, errmsg(), fb(), _archiveHandle::format, _archiveHandle::intSize, K_VERS_1_0, K_VERS_1_10, K_VERS_1_15, K_VERS_1_2, K_VERS_1_4, K_VERS_1_7, K_VERS_MAX, pg_compress_specification::level, MAKE_ARCHIVE_VERSION, _archiveHandle::offSize, PG_COMPRESSION_GZIP, pg_fatal, pg_free(), pg_log_warning, _archiveHandle::ReadBufPtr, _archiveHandle::ReadBytePtr, _archiveHandle::readHeader, ReadInt(), ReadStr(), supports_compression(), tm, pg_tm::tm_sec, and _archiveHandle::version.
Referenced by InitArchiveFmt_Custom(), InitArchiveFmt_Directory(), and InitArchiveFmt_Tar().
|
extern |
Definition at line 2165 of file pg_backup_archiver.c.
References b, fb(), _archiveHandle::intSize, K_VERS_1_0, _archiveHandle::ReadBytePtr, sign, and _archiveHandle::version.
Referenced by _CustomReadFunc(), _LoadLOs(), _readBlockHeader(), _ReadExtraToc(), _skipData(), _skipLOs(), ReadHead(), ReadOffset(), ReadStr(), and ReadToc().
| int ReadOffset | ( | ArchiveHandle * | AH, |
| pgoff_t * | o | ||
| ) |
Definition at line 2070 of file pg_backup_archiver.c.
References fb(), i, K_OFFSET_NO_DATA, K_OFFSET_POS_NOT_SET, K_OFFSET_POS_SET, K_VERS_1_7, _archiveHandle::offSize, pg_fatal, _archiveHandle::ReadBytePtr, ReadInt(), and _archiveHandle::version.
Referenced by _ReadExtraToc().
|
extern |
Definition at line 2211 of file pg_backup_archiver.c.
References buf, fb(), pg_malloc(), _archiveHandle::ReadBufPtr, and ReadInt().
Referenced by _ReadExtraToc(), _ReadExtraToc(), ReadHead(), and ReadToc().
|
extern |
Definition at line 2708 of file pg_backup_archiver.c.
References _tocEntry::catalogId, _tocEntry::copyStmt, _tocEntry::dataLength, _tocEntry::defn, _tocEntry::dependencies, _tocEntry::desc, _tocEntry::dropStmt, _tocEntry::dumpId, fb(), free, _tocEntry::hadDumper, i, InvalidOid, K_VERS_1_10, K_VERS_1_11, K_VERS_1_14, K_VERS_1_16, K_VERS_1_3, K_VERS_1_5, K_VERS_1_6, K_VERS_1_8, K_VERS_1_9, _archiveHandle::maxDumpId, _tocEntry::nDeps, _tocEntry::next, CatalogId::oid, _tocEntry::owner, pg_fatal, pg_log_debug, pg_log_warning, pg_malloc(), pg_malloc0(), pg_realloc(), _tocEntry::prev, processEncodingEntry(), processSearchPathEntry(), processStdStringsEntry(), _archiveHandle::ReadExtraTocPtr, ReadInt(), ReadStr(), _tocEntry::relkind, _tocEntry::section, SECTION_DATA, SECTION_NONE, SECTION_POST_DATA, SECTION_PRE_DATA, _tocEntry::tableam, CatalogId::tableoid, _tocEntry::tablespace, _tocEntry::tag, _archiveHandle::toc, _archiveHandle::tocCount, and _archiveHandle::version.
Referenced by InitArchiveFmt_Custom(), InitArchiveFmt_Directory(), and InitArchiveFmt_Tar().
|
extern |
Definition at line 73 of file pg_backup_db.c.
References ConnectDatabaseAhx(), _archiveHandle::connection, _restoreOptions::cparams, dbname, fb(), _connParams::override_dbname, pg_strdup(), PQfinish(), _archiveHandle::public, and Archive::ropt.
Referenced by _reconnectToDB().
|
extern |
Definition at line 1494 of file pg_backup_archiver.c.
References ahprintf(), _archiveHandle::connection, DropLOIfExists(), fb(), INV_WRITE, K_VERS_1_12, _archiveHandle::lo_buf, _archiveHandle::lo_buf_size, _archiveHandle::lo_buf_used, lo_create(), lo_open(), LOBBUFSIZE, _archiveHandle::loCount, _archiveHandle::loFd, pg_fatal, pg_log_info, pg_malloc(), PQerrorMessage(), _archiveHandle::version, and _archiveHandle::writingLO.
Referenced by _LoadLOs(), _LoadLOs(), and _LoadLOs().
|
extern |
Definition at line 1447 of file pg_backup_archiver.c.
References ahprintf(), _archiveHandle::connection, _archiveHandle::loCount, _archiveHandle::public, Archive::ropt, _restoreOptions::single_txn, StartTransaction(), and _restoreOptions::txn_size.
Referenced by _LoadLOs(), _LoadLOs(), and _LoadLOs().
|
extern |
Definition at line 2042 of file pg_backup_archiver.c.
References getTocEntryByDumpId(), and _tocEntry::reqs.
Referenced by _tarPositionTo(), and findDumpableDependencies().
|
extern |
|
extern |
Definition at line 2496 of file pg_backup_archiver.c.
References ACT_DUMP, _tocEntry::dataDumper, DispatchJobForTocEntry(), fb(), i, mark_dump_job_done(), _tocEntry::next, ParallelState::numWorkers, pg_free(), pg_malloc(), qsort, REQ_DATA, _tocEntry::reqs, _archiveHandle::toc, _archiveHandle::tocCount, TocEntrySizeCompareQsort(), WaitForWorkers(), WFW_ALL_IDLE, and WriteDataChunksForTocEntry().
Referenced by _CloseArchive(), _CloseArchive(), and _CloseArchive().
|
extern |
Definition at line 2577 of file pg_backup_archiver.c.
References _archiveHandle::currToc, _tocEntry::dataDumper, _tocEntry::dataDumperArg, _tocEntry::desc, _archiveHandle::EndDataPtr, _archiveHandle::EndLOsPtr, fb(), _archiveHandle::StartDataPtr, and _archiveHandle::StartLOsPtr.
Referenced by _WorkerJobDumpDirectory(), and WriteDataChunks().
|
extern |
Definition at line 4120 of file pg_backup_archiver.c.
References pg_compress_specification::algorithm, ARCHIVE_MAJOR, ARCHIVE_MINOR, ARCHIVE_REV, _archiveHandle::compression_spec, _archiveHandle::connection, _archiveHandle::createDate, fb(), _archiveHandle::format, _archiveHandle::intSize, _archiveHandle::offSize, PQdb(), _archiveHandle::public, Archive::remoteVersionStr, tm, _archiveHandle::version, _archiveHandle::WriteBufPtr, _archiveHandle::WriteBytePtr, WriteInt(), and WriteStr().
Referenced by _CloseArchive(), _CloseArchive(), and _CloseArchive().
|
extern |
Definition at line 2134 of file pg_backup_archiver.c.
References b, i, _archiveHandle::intSize, and _archiveHandle::WriteBytePtr.
Referenced by _CustomWriteFunc(), _EndData(), _EndLO(), _EndLOs(), _StartData(), _StartLO(), _StartLOs(), WriteHead(), WriteStr(), and WriteToc().
| size_t WriteOffset | ( | ArchiveHandle * | AH, |
| pgoff_t | o, | ||
| int | wasSet | ||
| ) |
Definition at line 2053 of file pg_backup_archiver.c.
References fb(), and _archiveHandle::WriteBytePtr.
Referenced by _WriteExtraToc().
|
extern |
Definition at line 2192 of file pg_backup_archiver.c.
References fb(), len, _archiveHandle::WriteBufPtr, and WriteInt().
Referenced by _WriteExtraToc(), _WriteExtraToc(), WriteHead(), and WriteToc().
|
extern |
Definition at line 2610 of file pg_backup_archiver.c.
References archCustom, _tocEntry::catalogId, _tocEntry::copyStmt, _tocEntry::dataDumper, _tocEntry::defn, _tocEntry::defnDumper, _tocEntry::defnDumperArg, _tocEntry::defnLen, _tocEntry::dependencies, _tocEntry::desc, _tocEntry::dropStmt, _tocEntry::dumpId, fb(), _archiveHandle::FH, _archiveHandle::format, fseeko, i, _tocEntry::nDeps, _tocEntry::next, CatalogId::oid, _tocEntry::owner, pg_fatal, pg_free(), _tocEntry::relkind, REQ_DATA, REQ_SCHEMA, REQ_SPECIAL, REQ_STATS, _tocEntry::reqs, _tocEntry::section, sprintf, _tocEntry::tableam, CatalogId::tableoid, _tocEntry::tablespace, _tocEntry::tag, _archiveHandle::toc, _archiveHandle::WriteExtraTocPtr, WriteInt(), and WriteStr().
Referenced by _CloseArchive(), _CloseArchive(), and _CloseArchive().