From: Alvaro Herrera Date: Mon, 24 Oct 2016 12:27:24 +0000 (-0300) Subject: Preserve commit timestamps across clean restart X-Git-Tag: XL9_5_R1_4~4^2~3 X-Git-Url: http://git.postgresql.org/gitweb/static/gitweb.js?a=commitdiff_plain;h=7a2fa5774a52bf7469f622e3ed4d6317c1d5a64e;p=postgres-xl.git Preserve commit timestamps across clean restart An oversight in setting the boundaries of known commit timestamps during startup caused old commit timestamps to become inaccessible after a server restart. Author and reporter: Julien Rouhaud Review, test code: Craig Ringer --- diff --git a/src/backend/access/transam/commit_ts.c b/src/backend/access/transam/commit_ts.c index a284894862..38dba8cef4 100644 --- a/src/backend/access/transam/commit_ts.c +++ b/src/backend/access/transam/commit_ts.c @@ -842,6 +842,8 @@ SetCommitTsLimit(TransactionId oldestXact, TransactionId newestXact) else { Assert(ShmemVariableCache->newestCommitTsXid == InvalidTransactionId); + ShmemVariableCache->oldestCommitTsXid = oldestXact; + ShmemVariableCache->newestCommitTsXid = newestXact; } LWLockRelease(CommitTsLock); }