mirror of
https://github.com/postgres/postgres.git
synced 2025-10-27 00:12:01 +03:00
pgindent run for 9.0
This commit is contained in:
@@ -7,7 +7,7 @@
|
||||
* Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* $PostgreSQL: pgsql/src/include/access/genam.h,v 1.83 2010/02/08 04:33:54 tgl Exp $
|
||||
* $PostgreSQL: pgsql/src/include/access/genam.h,v 1.84 2010/02/26 02:01:20 momjian Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@@ -92,7 +92,7 @@ typedef struct SysScanDescData *SysScanDesc;
|
||||
* blocking to see if a conflicting transaction commits.
|
||||
*
|
||||
* For deferrable unique constraints, UNIQUE_CHECK_PARTIAL is specified at
|
||||
* insertion time. The index AM should test if the tuple is unique, but
|
||||
* insertion time. The index AM should test if the tuple is unique, but
|
||||
* should not throw error, block, or prevent the insertion if the tuple
|
||||
* appears not to be unique. We'll recheck later when it is time for the
|
||||
* constraint to be enforced. The AM must return true if the tuple is
|
||||
@@ -101,7 +101,7 @@ typedef struct SysScanDescData *SysScanDesc;
|
||||
*
|
||||
* When it is time to recheck the deferred constraint, a pseudo-insertion
|
||||
* call is made with UNIQUE_CHECK_EXISTING. The tuple is already in the
|
||||
* index in this case, so it should not be inserted again. Rather, just
|
||||
* index in this case, so it should not be inserted again. Rather, just
|
||||
* check for conflicting live tuples (possibly blocking).
|
||||
*/
|
||||
typedef enum IndexUniqueCheck
|
||||
|
||||
@@ -4,7 +4,7 @@
|
||||
*
|
||||
* Copyright (c) 2006-2010, PostgreSQL Global Development Group
|
||||
*
|
||||
* $PostgreSQL: pgsql/src/include/access/gin.h,v 1.37 2010/02/11 14:29:50 teodor Exp $
|
||||
* $PostgreSQL: pgsql/src/include/access/gin.h,v 1.38 2010/02/26 02:01:20 momjian Exp $
|
||||
*--------------------------------------------------------------------------
|
||||
*/
|
||||
#ifndef GIN_H
|
||||
@@ -576,8 +576,8 @@ typedef struct
|
||||
GinState *ginstate;
|
||||
long allocatedMemory;
|
||||
uint32 length;
|
||||
EntryAccumulator *entryallocator;
|
||||
ItemPointerData *tmpList;
|
||||
EntryAccumulator *entryallocator;
|
||||
ItemPointerData *tmpList;
|
||||
RBTree *tree;
|
||||
RBTreeIterator *iterator;
|
||||
} BuildAccumulator;
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
* Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* $PostgreSQL: pgsql/src/include/access/heapam.h,v 1.147 2010/02/08 04:33:54 tgl Exp $
|
||||
* $PostgreSQL: pgsql/src/include/access/heapam.h,v 1.148 2010/02/26 02:01:20 momjian Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@@ -127,7 +127,7 @@ extern void heap2_redo(XLogRecPtr lsn, XLogRecord *rptr);
|
||||
extern void heap2_desc(StringInfo buf, uint8 xl_info, char *rec);
|
||||
|
||||
extern XLogRecPtr log_heap_cleanup_info(RelFileNode rnode,
|
||||
TransactionId latestRemovedXid);
|
||||
TransactionId latestRemovedXid);
|
||||
extern XLogRecPtr log_heap_clean(Relation reln, Buffer buffer,
|
||||
OffsetNumber *redirected, int nredirected,
|
||||
OffsetNumber *nowdead, int ndead,
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
* Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* $PostgreSQL: pgsql/src/include/access/htup.h,v 1.112 2010/02/08 14:10:21 momjian Exp $
|
||||
* $PostgreSQL: pgsql/src/include/access/htup.h,v 1.113 2010/02/26 02:01:21 momjian Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@@ -175,12 +175,12 @@ typedef HeapTupleHeaderData *HeapTupleHeader;
|
||||
#define HEAP_XMAX_INVALID 0x0800 /* t_xmax invalid/aborted */
|
||||
#define HEAP_XMAX_IS_MULTI 0x1000 /* t_xmax is a MultiXactId */
|
||||
#define HEAP_UPDATED 0x2000 /* this is UPDATEd version of row */
|
||||
#define HEAP_MOVED_OFF 0x4000 /* moved to another place by
|
||||
* pre-9.0 VACUUM FULL; kept
|
||||
* for binary upgrade support */
|
||||
#define HEAP_MOVED_IN 0x8000 /* moved from another place by
|
||||
* pre-9.0 VACUUM FULL; kept
|
||||
* for binary upgrade support */
|
||||
#define HEAP_MOVED_OFF 0x4000 /* moved to another place by pre-9.0
|
||||
* VACUUM FULL; kept for binary
|
||||
* upgrade support */
|
||||
#define HEAP_MOVED_IN 0x8000 /* moved from another place by pre-9.0
|
||||
* VACUUM FULL; kept for binary
|
||||
* upgrade support */
|
||||
#define HEAP_MOVED (HEAP_MOVED_OFF | HEAP_MOVED_IN)
|
||||
|
||||
#define HEAP_XACT_MASK 0xFFE0 /* visibility-related bits */
|
||||
@@ -642,7 +642,7 @@ typedef struct xl_heap_update
|
||||
xl_heaptid target; /* deleted tuple id */
|
||||
ItemPointerData newtid; /* new inserted tuple id */
|
||||
bool all_visible_cleared; /* PD_ALL_VISIBLE was cleared */
|
||||
bool new_all_visible_cleared; /* same for the page of newtid */
|
||||
bool new_all_visible_cleared; /* same for the page of newtid */
|
||||
/* NEW TUPLE xl_heap_header AND TUPLE DATA FOLLOWS AT END OF STRUCT */
|
||||
} xl_heap_update;
|
||||
|
||||
@@ -663,7 +663,7 @@ typedef struct xl_heap_clean
|
||||
{
|
||||
RelFileNode node;
|
||||
BlockNumber block;
|
||||
TransactionId latestRemovedXid;
|
||||
TransactionId latestRemovedXid;
|
||||
uint16 nredirected;
|
||||
uint16 ndead;
|
||||
/* OFFSET NUMBERS FOLLOW */
|
||||
@@ -678,8 +678,8 @@ typedef struct xl_heap_clean
|
||||
*/
|
||||
typedef struct xl_heap_cleanup_info
|
||||
{
|
||||
RelFileNode node;
|
||||
TransactionId latestRemovedXid;
|
||||
RelFileNode node;
|
||||
TransactionId latestRemovedXid;
|
||||
} xl_heap_cleanup_info;
|
||||
|
||||
#define SizeOfHeapCleanupInfo (sizeof(xl_heap_cleanup_info))
|
||||
@@ -728,7 +728,7 @@ typedef struct xl_heap_freeze
|
||||
#define SizeOfHeapFreeze (offsetof(xl_heap_freeze, cutoff_xid) + sizeof(TransactionId))
|
||||
|
||||
extern void HeapTupleHeaderAdvanceLatestRemovedXid(HeapTupleHeader tuple,
|
||||
TransactionId *latestRemovedXid);
|
||||
TransactionId *latestRemovedXid);
|
||||
|
||||
/* HeapTupleHeader functions implemented in utils/time/combocid.c */
|
||||
extern CommandId HeapTupleHeaderGetCmin(HeapTupleHeader tup);
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
* Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* $PostgreSQL: pgsql/src/include/access/itup.h,v 1.54 2010/01/10 04:26:36 rhaas Exp $
|
||||
* $PostgreSQL: pgsql/src/include/access/itup.h,v 1.55 2010/02/26 02:01:21 momjian Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@@ -144,7 +144,7 @@ extern IndexTuple index_form_tuple(TupleDesc tupleDescriptor,
|
||||
extern Datum nocache_index_getattr(IndexTuple tup, int attnum,
|
||||
TupleDesc tupleDesc);
|
||||
extern void index_deform_tuple(IndexTuple tup, TupleDesc tupleDescriptor,
|
||||
Datum *values, bool *isnull);
|
||||
Datum *values, bool *isnull);
|
||||
extern IndexTuple CopyIndexTuple(IndexTuple source);
|
||||
|
||||
#endif /* ITUP_H */
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
* Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* $PostgreSQL: pgsql/src/include/access/nbtree.h,v 1.129 2010/02/13 00:59:58 sriggs Exp $
|
||||
* $PostgreSQL: pgsql/src/include/access/nbtree.h,v 1.130 2010/02/26 02:01:21 momjian Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@@ -220,8 +220,10 @@ typedef struct BTMetaPageData
|
||||
#define XLOG_BTREE_NEWROOT 0xA0 /* new root page */
|
||||
#define XLOG_BTREE_DELETE_PAGE_HALF 0xB0 /* page deletion that makes
|
||||
* parent half-dead */
|
||||
#define XLOG_BTREE_VACUUM 0xC0 /* delete entries on a page during vacuum */
|
||||
#define XLOG_BTREE_REUSE_PAGE 0xD0 /* old page is about to be reused from FSM */
|
||||
#define XLOG_BTREE_VACUUM 0xC0 /* delete entries on a page during
|
||||
* vacuum */
|
||||
#define XLOG_BTREE_REUSE_PAGE 0xD0 /* old page is about to be reused from
|
||||
* FSM */
|
||||
|
||||
/*
|
||||
* All that we need to find changed index tuple
|
||||
@@ -314,8 +316,8 @@ typedef struct xl_btree_delete
|
||||
{
|
||||
RelFileNode node;
|
||||
BlockNumber block;
|
||||
TransactionId latestRemovedXid;
|
||||
int numItems; /* number of items in the offset array */
|
||||
TransactionId latestRemovedXid;
|
||||
int numItems; /* number of items in the offset array */
|
||||
|
||||
/* TARGET OFFSET NUMBERS FOLLOW AT THE END */
|
||||
} xl_btree_delete;
|
||||
@@ -329,7 +331,7 @@ typedef struct xl_btree_reuse_page
|
||||
{
|
||||
RelFileNode node;
|
||||
BlockNumber block;
|
||||
TransactionId latestRemovedXid;
|
||||
TransactionId latestRemovedXid;
|
||||
} xl_btree_reuse_page;
|
||||
|
||||
#define SizeOfBtreeReusePage (sizeof(xl_btree_reuse_page))
|
||||
@@ -341,7 +343,7 @@ typedef struct xl_btree_reuse_page
|
||||
*
|
||||
* The correctness requirement for applying these changes during recovery is
|
||||
* that we must do one of these two things for every block in the index:
|
||||
* * lock the block for cleanup and apply any required changes
|
||||
* * lock the block for cleanup and apply any required changes
|
||||
* * EnsureBlockUnpinned()
|
||||
* The purpose of this is to ensure that no index scans started before we
|
||||
* finish scanning the index are still running by the time we begin to remove
|
||||
@@ -361,7 +363,7 @@ typedef struct xl_btree_vacuum
|
||||
RelFileNode node;
|
||||
BlockNumber block;
|
||||
BlockNumber lastBlockVacuumed;
|
||||
int numItems; /* number of items in the offset array */
|
||||
int numItems; /* number of items in the offset array */
|
||||
|
||||
/* TARGET OFFSET NUMBERS FOLLOW */
|
||||
} xl_btree_vacuum;
|
||||
@@ -590,7 +592,7 @@ extern bool _bt_page_recyclable(Page page);
|
||||
extern void _bt_delitems(Relation rel, Buffer buf,
|
||||
OffsetNumber *itemnos, int nitems, bool isVacuum,
|
||||
BlockNumber lastBlockVacuumed);
|
||||
extern int _bt_pagedel(Relation rel, Buffer buf, BTStack stack);
|
||||
extern int _bt_pagedel(Relation rel, Buffer buf, BTStack stack);
|
||||
|
||||
/*
|
||||
* prototypes for functions in nbtsearch.c
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
* Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* $PostgreSQL: pgsql/src/include/access/relscan.h,v 1.69 2010/01/02 16:58:00 momjian Exp $
|
||||
* $PostgreSQL: pgsql/src/include/access/relscan.h,v 1.70 2010/02/26 02:01:21 momjian Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@@ -68,7 +68,8 @@ typedef struct IndexScanDescData
|
||||
/* signaling to index AM about killing index tuples */
|
||||
bool kill_prior_tuple; /* last-returned tuple is dead */
|
||||
bool ignore_killed_tuples; /* do not return killed entries */
|
||||
bool xactStartedInRecovery; /* prevents killing/seeing killed tuples */
|
||||
bool xactStartedInRecovery; /* prevents killing/seeing killed
|
||||
* tuples */
|
||||
|
||||
/* index access method's private state */
|
||||
void *opaque; /* access-method-specific info */
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
* Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* $PostgreSQL: pgsql/src/include/access/skey.h,v 1.39 2010/01/02 16:58:00 momjian Exp $
|
||||
* $PostgreSQL: pgsql/src/include/access/skey.h,v 1.40 2010/02/26 02:01:21 momjian Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@@ -114,13 +114,14 @@ typedef ScanKeyData *ScanKey;
|
||||
* bits should be defined here). Bits 16-31 are reserved for use within
|
||||
* individual index access methods.
|
||||
*/
|
||||
#define SK_ISNULL 0x0001 /* sk_argument is NULL */
|
||||
#define SK_UNARY 0x0002 /* unary operator (not supported!) */
|
||||
#define SK_ROW_HEADER 0x0004 /* row comparison header (see above) */
|
||||
#define SK_ROW_MEMBER 0x0008 /* row comparison member (see above) */
|
||||
#define SK_ROW_END 0x0010 /* last row comparison member */
|
||||
#define SK_SEARCHNULL 0x0020 /* scankey represents "col IS NULL" */
|
||||
#define SK_SEARCHNOTNULL 0x0040 /* scankey represents "col IS NOT NULL" */
|
||||
#define SK_ISNULL 0x0001 /* sk_argument is NULL */
|
||||
#define SK_UNARY 0x0002 /* unary operator (not supported!) */
|
||||
#define SK_ROW_HEADER 0x0004 /* row comparison header (see above) */
|
||||
#define SK_ROW_MEMBER 0x0008 /* row comparison member (see above) */
|
||||
#define SK_ROW_END 0x0010 /* last row comparison member */
|
||||
#define SK_SEARCHNULL 0x0020 /* scankey represents "col IS NULL" */
|
||||
#define SK_SEARCHNOTNULL 0x0040 /* scankey represents "col IS NOT
|
||||
* NULL" */
|
||||
|
||||
|
||||
/*
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
* Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* $PostgreSQL: pgsql/src/include/access/slru.h,v 1.26 2010/02/16 22:34:50 tgl Exp $
|
||||
* $PostgreSQL: pgsql/src/include/access/slru.h,v 1.27 2010/02/26 02:01:21 momjian Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@@ -31,7 +31,7 @@
|
||||
* segment and page numbers in SimpleLruTruncate (see PagePrecedes()).
|
||||
*
|
||||
* Note: slru.c currently assumes that segment file names will be four hex
|
||||
* digits. This sets a lower bound on the segment size (64K transactions
|
||||
* digits. This sets a lower bound on the segment size (64K transactions
|
||||
* for 32-bit TransactionIds).
|
||||
*/
|
||||
#define SLRU_PAGES_PER_SEGMENT 32
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
* Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* $PostgreSQL: pgsql/src/include/access/tupconvert.h,v 1.2 2010/01/02 16:58:00 momjian Exp $
|
||||
* $PostgreSQL: pgsql/src/include/access/tupconvert.h,v 1.3 2010/02/26 02:01:21 momjian Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@@ -30,12 +30,12 @@ typedef struct TupleConversionMap
|
||||
|
||||
|
||||
extern TupleConversionMap *convert_tuples_by_position(TupleDesc indesc,
|
||||
TupleDesc outdesc,
|
||||
const char *msg);
|
||||
TupleDesc outdesc,
|
||||
const char *msg);
|
||||
|
||||
extern TupleConversionMap *convert_tuples_by_name(TupleDesc indesc,
|
||||
TupleDesc outdesc,
|
||||
const char *msg);
|
||||
TupleDesc outdesc,
|
||||
const char *msg);
|
||||
|
||||
extern HeapTuple do_convert_tuple(HeapTuple tuple, TupleConversionMap *map);
|
||||
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
*
|
||||
* Copyright (c) 2000-2010, PostgreSQL Global Development Group
|
||||
*
|
||||
* $PostgreSQL: pgsql/src/include/access/tuptoaster.h,v 1.45 2010/01/02 16:58:00 momjian Exp $
|
||||
* $PostgreSQL: pgsql/src/include/access/tuptoaster.h,v 1.46 2010/02/26 02:01:21 momjian Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@@ -27,7 +27,7 @@
|
||||
/*
|
||||
* Find the maximum size of a tuple if there are to be N tuples per page.
|
||||
*/
|
||||
#define MaximumBytesPerTuple(tuplesPerPage) \
|
||||
#define MaximumBytesPerTuple(tuplesPerPage) \
|
||||
MAXALIGN_DOWN((BLCKSZ - \
|
||||
MAXALIGN(SizeOfPageHeaderData + (tuplesPerPage) * sizeof(ItemIdData))) \
|
||||
/ (tuplesPerPage))
|
||||
@@ -60,12 +60,12 @@
|
||||
* The code will also consider moving MAIN data out-of-line, but only as a
|
||||
* last resort if the previous steps haven't reached the target tuple size.
|
||||
* In this phase we use a different target size, currently equal to the
|
||||
* largest tuple that will fit on a heap page. This is reasonable since
|
||||
* largest tuple that will fit on a heap page. This is reasonable since
|
||||
* the user has told us to keep the data in-line if at all possible.
|
||||
*/
|
||||
#define TOAST_TUPLES_PER_PAGE_MAIN 1
|
||||
|
||||
#define TOAST_TUPLE_TARGET_MAIN MaximumBytesPerTuple(TOAST_TUPLES_PER_PAGE_MAIN)
|
||||
#define TOAST_TUPLE_TARGET_MAIN MaximumBytesPerTuple(TOAST_TUPLES_PER_PAGE_MAIN)
|
||||
|
||||
/*
|
||||
* If an index value is larger than TOAST_INDEX_TARGET, we will try to
|
||||
|
||||
@@ -7,7 +7,7 @@
|
||||
* Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* $PostgreSQL: pgsql/src/include/access/xact.h,v 1.102 2010/02/13 16:15:47 sriggs Exp $
|
||||
* $PostgreSQL: pgsql/src/include/access/xact.h,v 1.103 2010/02/26 02:01:21 momjian Exp $
|
||||
*
|
||||
*-------------------------------------------------------------------------
|
||||
*/
|
||||
@@ -88,9 +88,9 @@ typedef void (*SubXactCallback) (SubXactEvent event, SubTransactionId mySubid,
|
||||
|
||||
typedef struct xl_xact_assignment
|
||||
{
|
||||
TransactionId xtop; /* assigned XID's top-level XID */
|
||||
int nsubxacts; /* number of subtransaction XIDs */
|
||||
TransactionId xsub[1]; /* assigned subxids */
|
||||
TransactionId xtop; /* assigned XID's top-level XID */
|
||||
int nsubxacts; /* number of subtransaction XIDs */
|
||||
TransactionId xsub[1]; /* assigned subxids */
|
||||
} xl_xact_assignment;
|
||||
|
||||
#define MinSizeOfXactAssignment offsetof(xl_xact_assignment, xsub)
|
||||
@@ -136,6 +136,7 @@ typedef struct xl_xact_abort
|
||||
RelFileNode xnodes[1]; /* VARIABLE LENGTH ARRAY */
|
||||
/* ARRAY OF ABORTED SUBTRANSACTION XIDs FOLLOWS */
|
||||
} xl_xact_abort;
|
||||
|
||||
/* Note the intentional lack of an invalidation message array c.f. commit */
|
||||
|
||||
#define MinSizeOfXactAbort offsetof(xl_xact_abort, xnodes)
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
* Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* $PostgreSQL: pgsql/src/include/access/xlog.h,v 1.102 2010/02/08 04:33:54 tgl Exp $
|
||||
* $PostgreSQL: pgsql/src/include/access/xlog.h,v 1.103 2010/02/26 02:01:21 momjian Exp $
|
||||
*/
|
||||
#ifndef XLOG_H
|
||||
#define XLOG_H
|
||||
@@ -132,7 +132,7 @@ typedef struct XLogRecData
|
||||
struct XLogRecData *next; /* next struct in chain, or NULL */
|
||||
} XLogRecData;
|
||||
|
||||
extern PGDLLIMPORT TimeLineID ThisTimeLineID; /* current TLI */
|
||||
extern PGDLLIMPORT TimeLineID ThisTimeLineID; /* current TLI */
|
||||
|
||||
/*
|
||||
* Prior to 8.4, all activity during recovery was carried out by Startup
|
||||
@@ -182,7 +182,7 @@ extern char *XLogArchiveCommand;
|
||||
extern int XLogArchiveTimeout;
|
||||
extern bool log_checkpoints;
|
||||
extern bool XLogRequestRecoveryConnections;
|
||||
extern int MaxStandbyDelay;
|
||||
extern int MaxStandbyDelay;
|
||||
|
||||
#define XLogArchivingActive() (XLogArchiveMode)
|
||||
#define XLogArchiveCommandSet() (XLogArchiveCommand[0] != '\0')
|
||||
@@ -200,7 +200,7 @@ extern int MaxWalSenders;
|
||||
#define XLogIsNeeded() (XLogArchivingActive() || (MaxWalSenders > 0))
|
||||
|
||||
/* Do we need to WAL-log information required only for Hot Standby? */
|
||||
#define XLogStandbyInfoActive() (XLogRequestRecoveryConnections && XLogIsNeeded())
|
||||
#define XLogStandbyInfoActive() (XLogRequestRecoveryConnections && XLogIsNeeded())
|
||||
|
||||
#ifdef WAL_DEBUG
|
||||
extern bool XLOG_DEBUG;
|
||||
@@ -214,8 +214,9 @@ extern bool XLOG_DEBUG;
|
||||
|
||||
/* These directly affect the behavior of CreateCheckPoint and subsidiaries */
|
||||
#define CHECKPOINT_IS_SHUTDOWN 0x0001 /* Checkpoint is for shutdown */
|
||||
#define CHECKPOINT_END_OF_RECOVERY 0x0002 /* Like shutdown checkpoint, but
|
||||
* issued at end of WAL recovery */
|
||||
#define CHECKPOINT_END_OF_RECOVERY 0x0002 /* Like shutdown checkpoint,
|
||||
* but issued at end of WAL
|
||||
* recovery */
|
||||
#define CHECKPOINT_IMMEDIATE 0x0004 /* Do it without delays */
|
||||
#define CHECKPOINT_FORCE 0x0008 /* Force even if no activity */
|
||||
/* These are important to RequestCheckpoint */
|
||||
@@ -250,8 +251,8 @@ extern XLogRecPtr XLogInsert(RmgrId rmid, uint8 info, XLogRecData *rdata);
|
||||
extern void XLogFlush(XLogRecPtr RecPtr);
|
||||
extern void XLogBackgroundFlush(void);
|
||||
extern bool XLogNeedsFlush(XLogRecPtr RecPtr);
|
||||
extern int XLogFileInit(uint32 log, uint32 seg,
|
||||
bool *use_existent, bool use_lock);
|
||||
extern int XLogFileInit(uint32 log, uint32 seg,
|
||||
bool *use_existent, bool use_lock);
|
||||
extern int XLogFileOpen(uint32 log, uint32 seg);
|
||||
|
||||
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
* Portions Copyright (c) 1996-2010, PostgreSQL Global Development Group
|
||||
* Portions Copyright (c) 1994, Regents of the University of California
|
||||
*
|
||||
* $PostgreSQL: pgsql/src/include/access/xlog_internal.h,v 1.28 2010/01/15 09:19:06 heikki Exp $
|
||||
* $PostgreSQL: pgsql/src/include/access/xlog_internal.h,v 1.29 2010/02/26 02:01:21 momjian Exp $
|
||||
*/
|
||||
#ifndef XLOG_INTERNAL_H
|
||||
#define XLOG_INTERNAL_H
|
||||
@@ -152,15 +152,15 @@ typedef XLogLongPageHeaderData *XLogLongPageHeader;
|
||||
} while (0)
|
||||
|
||||
/* Align a record pointer to next page */
|
||||
#define NextLogPage(recptr) \
|
||||
#define NextLogPage(recptr) \
|
||||
do { \
|
||||
if (recptr.xrecoff % XLOG_BLCKSZ != 0) \
|
||||
recptr.xrecoff += \
|
||||
(XLOG_BLCKSZ - recptr.xrecoff % XLOG_BLCKSZ); \
|
||||
if (recptr.xrecoff >= XLogFileSize) \
|
||||
if (recptr.xrecoff >= XLogFileSize) \
|
||||
{ \
|
||||
(recptr.xlogid)++; \
|
||||
recptr.xrecoff = 0; \
|
||||
recptr.xrecoff = 0; \
|
||||
} \
|
||||
} while (0)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user