Re: Concurrency testing

From: Jeff Janes <jeff(dot)janes(at)gmail(dot)com>
To: "David E(dot) Wheeler" <david(at)kineticode(dot)com>
Cc: David Fetter <david(at)fetter(dot)org>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Concurrency testing
Date: 2009-10-08 02:59:24
Message-ID: f67928030910071959t3aca4b39ic00a2775f85a384f@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Wed, Oct 7, 2009 at 5:33 PM, David E. Wheeler <david(at)kineticode(dot)com> wrote:
> On Oct 7, 2009, at 5:18 PM, Jeff Janes wrote:
>
>> I'd much rather live without Test::More and use DBD::Pg, then have
>> Test::More but need to open pipes to psql to talk to the database,
>> rather than using DBI to do it.  But I guess we would need to worry
>> about whether we can make DBD::Pg work with the installation being
>> tested, rather than finding some other install.
>
> The test architecture depends on Perl, but not on the DBI. I don't think
> that Andrew wants to add any dependencies. Therefore we'd need to use file
> handles.

If we are going to talk to multiple psql pipes at the same time, and
not self-deadlock in the process, we would probably need to use some
form of non-blocking IO. Unfortunately, I've often found it isn't as
easy as one might hope to do that in a completely portable way. Maybe
IPC::Run, but I think that that is non-core also.

Are we interested only in simple deterministic concurrency testing: T1
does A, T2 does B, T1 does C and must block until T2 does D, at which
point (and not before) T1 must respond with E. (Of course from some
recent testing I've done, we would also want "T1 does C and must block
either until T2 does D or until X+/-Y microseconds have passed")

Or would we want to beat the snot out the database in parallel in a
nondeterministic fashion, and checking for self-consistency and
non-deadlock?

Cheers,

Jeff

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2009-10-08 03:08:54 Re: postgres 8.3.8 and Solaris 10_x86 64 bit problems?
Previous Message Jeff Janes 2009-10-08 02:41:36 Re: Concurrency testing