diff options
author | Tom Lane <tgl@sss.pgh.pa.us> | 2006-08-21 16:16:31 +0000 |
---|---|---|
committer | Tom Lane <tgl@sss.pgh.pa.us> | 2006-08-21 16:16:31 +0000 |
commit | 35af5422f640e74029a167d106604da35ae64c5f (patch) | |
tree | 88297ff1c3c369c1a2a2063b319518b0db72b4fe /src/include/access/xlog.h | |
parent | 1054c38069359239d4c1469a1dab543f11706bc2 (diff) |
Make the server track an 'XID epoch', that is, maintain higher-order bits
of the transaction ID counter. Nothing is done with the epoch except to
store it in checkpoint records, but this provides a foundation with which
add-on code can pretend that XIDs never wrap around. This is a severely
trimmed and rewritten version of the xxid patch submitted by Marko Kreen.
Per discussion, the epoch counter seems the only part of xxid that really
needs to be in the core server.
Diffstat (limited to 'src/include/access/xlog.h')
-rw-r--r-- | src/include/access/xlog.h | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/include/access/xlog.h b/src/include/access/xlog.h index 22b0f0bb7be..a5ae94b91aa 100644 --- a/src/include/access/xlog.h +++ b/src/include/access/xlog.h @@ -6,7 +6,7 @@ * Portions Copyright (c) 1996-2006, PostgreSQL Global Development Group * Portions Copyright (c) 1994, Regents of the University of California * - * $PostgreSQL: pgsql/src/include/access/xlog.h,v 1.73 2006/08/17 23:04:08 tgl Exp $ + * $PostgreSQL: pgsql/src/include/access/xlog.h,v 1.74 2006/08/21 16:16:31 tgl Exp $ */ #ifndef XLOG_H #define XLOG_H @@ -166,5 +166,6 @@ extern void CreateCheckPoint(bool shutdown, bool force); extern void XLogPutNextOid(Oid nextOid); extern XLogRecPtr GetRedoRecPtr(void); extern TransactionId GetRecentNextXid(void); +extern void GetNextXidAndEpoch(TransactionId *xid, uint32 *epoch); #endif /* XLOG_H */ |