Re: [HACKERS] Speedup twophase transactions - Mailing list pgsql-hackers

From Nikhil Sontakke
Subject Re: [HACKERS] Speedup twophase transactions
Date
Msg-id CAMGcDxcOzS5Puf+g=0h-YdQb8qDpZXZvkSn7zEykXZ2+esNMPg@mail.gmail.com
Whole thread Raw
In response to Re: [HACKERS] Speedup twophase transactions  (Michael Paquier <michael.paquier@gmail.com>)
List pgsql-hackers
Nikhil, do you mind if I try something like that? As we already know
what is the first XID when beginning redo via
ShmemVariableCache->nextXid it is possible to discard 2PC files that
should not be here.

Yeah, that is ok.
 
What makes me worry is the control of the maximum
number of entries in shared memory. If there are legit 2PC files that
are flushed on disk at checkpoint, you would finish with potentially
more 2PC transactions than what should be possible (even if updates of
max_prepared_xacts are WAL-logged).

The max_prepared_xacts number restricts the number of pending PREPARED transactions *across* the 2PC files and shmem inredo entries. We can never have more entries than this value.


Regards,
Nikhils
-- 
 Nikhil Sontakke                   http://www.2ndQuadrant.com/
 PostgreSQL/Postgres-XL Development, 24x7 Support, Training & Services

pgsql-hackers by date:

Previous
From: Ashutosh Sharma
Date:
Subject: Re: [HACKERS] WAL Consistency checking for hash indexes
Next
From: Nikhil Sontakke
Date:
Subject: Re: [HACKERS] Speedup twophase transactions