Re: HeapTupleSatisfiesDirty fails to test HEAP_XMAX_IS_LOCKED_ONLY for TransactionIdIsInProgress(...) - Mailing list pgsql-hackers

From Robert Haas
Subject Re: HeapTupleSatisfiesDirty fails to test HEAP_XMAX_IS_LOCKED_ONLY for TransactionIdIsInProgress(...)
Date
Msg-id CA+TgmoafiftcfSqU-XWtSDzKHzxh3zWs4-Knzv=-j7RjFnR-xQ@mail.gmail.com
Whole thread Raw
In response to Re: HeapTupleSatisfiesDirty fails to test HEAP_XMAX_IS_LOCKED_ONLY for TransactionIdIsInProgress(...)  (Alvaro Herrera <alvherre@2ndquadrant.com>)
Responses Re: HeapTupleSatisfiesDirty fails to test HEAP_XMAX_IS_LOCKED_ONLY for TransactionIdIsInProgress(...)  (Andres Freund <andres@2ndquadrant.com>)
Re: HeapTupleSatisfiesDirty fails to test HEAP_XMAX_IS_LOCKED_ONLY for TransactionIdIsInProgress(...)  (Craig Ringer <craig@2ndquadrant.com>)
List pgsql-hackers
On Fri, Aug 2, 2013 at 5:25 PM, Alvaro Herrera <alvherre@2ndquadrant.com> wrote:
>> The attached test case runs under isolationtester to exersise the
>> problem. I've tested it against 9.2, 9.3, and HEAD, but Andres looked
>> over the code and says the underlying bug goes back to the commit of
>> MVCC, it's just become easier to trigger. To reliably test this with
>> isolationtester I had to horribly abuse pg_advisory_lock(...) so that I
>> could force the first SELECT ... FOR UPDATE to acquire its snapshot
>> before the UPDATE runs.
>
> I didn't apply the test case.  I think if we want to test tqual.c
> behavior we will need to introduce a large battery of tests.  I would
> like to see more opinions on whether that's something we want.

I haven't read this particular test, but I do think we could get a lot
of mileage out of applying the isolation tester stuff to more things,
and am generally in favor of that.  It has the advantages of (1)
allowing tests that require more than one session and (2) being run
regularly the buildfarm; but it's not something developers typically
run before every commit, so the run time of the test suite shouldn't
be a big issue for anyone.

-- 
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company



pgsql-hackers by date:

Previous
From: Josh Berkus
Date:
Subject: Re: Unsafe GUCs and ALTER SYSTEM WAS: Re: ALTER SYSTEM SET
Next
From: Robert Haas
Date:
Subject: Re: don't own lock of type?