Thread: xact_desc
ISTM that xact_desc routines do not work properly when called with WAL_DEBUG enabled from XLogInsert(). LOG: INSERT @ 0/3740978: prev 0/3740938; xid 5699: Transaction - commit: 2008-10-14 03:14:14.866437+01; subxacts: 10447936 0 STATEMENT: commit; LOG: INSERT @ 0/37409F0: prev 0/37409B0; xid 5702: Transaction - commit: 2008-10-14 03:14:17.687843+01; subxacts: 10447936 0 STATEMENT: commit; The arrays... work fine in recovery, just not prior to inserting. Anyway, that led me a merry dance with other code. -- Simon Riggs www.2ndQuadrant.comPostgreSQL Training, Services and Support
Simon Riggs <simon@2ndQuadrant.com> writes: > ISTM that xact_desc routines do not work properly when called with > WAL_DEBUG enabled from XLogInsert(). Well, now that you mention it, that code is utterly, completely broken, and always has been. It's passing only the first rdata-chunk of the WAL record to the print routine :-( AFAICS the only way to fix it would be to allocate some workspace and assemble the chunks of the record into that. Doubtful that it's worth it --- I'd be inclined to just remove the code instead. regards, tom lane
On Mon, 2008-10-13 at 23:05 -0400, Tom Lane wrote: > Simon Riggs <simon@2ndQuadrant.com> writes: > > ISTM that xact_desc routines do not work properly when called with > > WAL_DEBUG enabled from XLogInsert(). > > Well, now that you mention it, that code is utterly, completely broken, > and always has been. It's passing only the first rdata-chunk of the WAL > record to the print routine :-( > > AFAICS the only way to fix it would be to allocate some workspace and > assemble the chunks of the record into that. Doubtful that it's worth > it --- I'd be inclined to just remove the code instead. Will remove, with extreme prejudice. -- Simon Riggs www.2ndQuadrant.comPostgreSQL Training, Services and Support