]> granicus.if.org Git - postgresql/commit
Make new deadlock isolation test more reproducible.
authorTom Lane <tgl@sss.pgh.pa.us>
Thu, 11 Feb 2016 16:59:11 +0000 (11:59 -0500)
committerTom Lane <tgl@sss.pgh.pa.us>
Thu, 11 Feb 2016 16:59:11 +0000 (11:59 -0500)
commitb11d07b6a3fc64904731e3b9a467a2567bc7dcdb
tree43aa0a3a6a746494468810e6223e75ce5af1071e
parentd9dc2b4149c017c0a1d2045b858e8e0cc1a92464
Make new deadlock isolation test more reproducible.

The original formulation of 4c9864b9b4d87d02f07f40bb27976da737afdcab
was extremely timing-sensitive, because it arranged for the deadlock
detector to be running (and possibly unblocking the current query)
at almost exactly the same time as isolationtester would be probing
to see if the query is blocked.  The committed expected-file assumed
that the deadlock detection would finish first, but we see the opposite
on both fast and slow buildfarm animals.  Adjust the deadlock timeout
settings to make it predictable that isolationtester *will* see the
query as waiting before deadlock detection unblocks it.

I used a 5s timeout for the same reasons mentioned in
a7921f71a3c747141344d8604f6a6d7b4cddb2a9.
src/test/isolation/expected/deadlock-hard.out
src/test/isolation/specs/deadlock-hard.spec