Re: pgsql: Store 2PC GID in commit/abort WAL recs for logical decoding

Alvaro Herrera <alvherre@2ndquadrant.com>

From: Alvaro Herrera <alvherre@2ndquadrant.com>
To: Nikhil Sontakke <nikhils@2ndquadrant.com>
Cc: Heikki Linnakangas <hlinnaka@iki.fi>, Michael Paquier <michael@paquier.xyz>, Simon Riggs <simon@2ndquadrant.com>, pgsql-hackers <pgsql-hackers@postgresql.org>
Date: 2018-06-15T19:04:57Z
Lists: pgsql-hackers
On 2018-Jun-14, Nikhil Sontakke wrote:

> There was a slight oversight in the twophase_gid length calculation in
> the XactLogCommitRecord() code path in the cf5a1890592 commit. The
> corresponding XactLogAbortRecord() code path was ok. PFA, a small
> patch to fix the oversight.

Forgot to add: maybe it would be useful to have tests in core where
these omissions become evident.  Do you have some?

-- 
Álvaro Herrera                https://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services


Commits

  1. Fix off-by-one bug in XactLogCommitRecord

  2. Fix confusion on the padding of GIDs in on commit and abort records.

  3. Store 2PC GID in commit/abort WAL recs for logical decoding