postgresql/src/test/isolation/expected/partition-concurrent-attach...

Ignoring revisions in .git-blame-ignore-revs. Click here to bypass and see the normal blame view.

56 lines
1.7 KiB
Plaintext
Raw Normal View History

Parsed test spec with 2 sessions
starting permutation: s1b s1a s2b s2i s1c s2c s2s
step s1b: begin;
step s1a: alter table tpart attach partition tpart_2 for values from (100) to (200);
step s2b: begin;
step s2i: insert into tpart values (110,'xxx'), (120, 'yyy'), (150, 'zzz'); <waiting ...>
step s1c: commit;
step s2i: <... completed>
Use annotations to reduce instability of isolation-test results. We've long contended with isolation test results that aren't entirely stable. Some test scripts insert long delays to try to force stable results, which is not terribly desirable; but other erratic failure modes remain, causing unrepeatable buildfarm failures. I've spent a fair amount of time trying to solve this by improving the server-side support code, without much success: that way is fundamentally unable to cope with diffs that stem from chance ordering of arrival of messages from different server processes. We can improve matters on the client side, however, by annotating the test scripts themselves to show the desired reporting order of events that might occur in different orders. This patch adds three types of annotations to deal with (a) test steps that might or might not complete their waits before the isolationtester can see them waiting; (b) test steps in different sessions that can legitimately complete in either order; and (c) NOTIFY messages that might arrive before or after the completion of a step in another session. We might need more annotation types later, but this seems to be enough to deal with the instabilities we've seen in the buildfarm. It also lets us get rid of all the long delays that were previously used, cutting more than a minute off the runtime of the isolation tests. Back-patch to all supported branches, because the buildfarm instabilities affect all the branches, and because it seems desirable to keep isolationtester's capabilities the same across all branches to simplify possible future back-patching of tests. Discussion: https://postgr.es/m/327948.1623725828@sss.pgh.pa.us
2021-06-23 03:43:12 +02:00
ERROR: new row for relation "tpart_default" violates partition constraint
step s2c: commit;
step s2s: select tableoid::regclass, * from tpart;
tableoid| i|j
--------+---+---
tpart_2 |110|xxx
tpart_2 |120|yyy
tpart_2 |150|zzz
(3 rows)
starting permutation: s1b s1a s2b s2i2 s1c s2c s2s
step s1b: begin;
step s1a: alter table tpart attach partition tpart_2 for values from (100) to (200);
step s2b: begin;
step s2i2: insert into tpart_default (i, j) values (110, 'xxx'), (120, 'yyy'), (150, 'zzz'); <waiting ...>
step s1c: commit;
step s2i2: <... completed>
Use annotations to reduce instability of isolation-test results. We've long contended with isolation test results that aren't entirely stable. Some test scripts insert long delays to try to force stable results, which is not terribly desirable; but other erratic failure modes remain, causing unrepeatable buildfarm failures. I've spent a fair amount of time trying to solve this by improving the server-side support code, without much success: that way is fundamentally unable to cope with diffs that stem from chance ordering of arrival of messages from different server processes. We can improve matters on the client side, however, by annotating the test scripts themselves to show the desired reporting order of events that might occur in different orders. This patch adds three types of annotations to deal with (a) test steps that might or might not complete their waits before the isolationtester can see them waiting; (b) test steps in different sessions that can legitimately complete in either order; and (c) NOTIFY messages that might arrive before or after the completion of a step in another session. We might need more annotation types later, but this seems to be enough to deal with the instabilities we've seen in the buildfarm. It also lets us get rid of all the long delays that were previously used, cutting more than a minute off the runtime of the isolation tests. Back-patch to all supported branches, because the buildfarm instabilities affect all the branches, and because it seems desirable to keep isolationtester's capabilities the same across all branches to simplify possible future back-patching of tests. Discussion: https://postgr.es/m/327948.1623725828@sss.pgh.pa.us
2021-06-23 03:43:12 +02:00
ERROR: new row for relation "tpart_default" violates partition constraint
step s2c: commit;
step s2s: select tableoid::regclass, * from tpart;
tableoid| i|j
--------+---+---
tpart_2 |110|xxx
tpart_2 |120|yyy
tpart_2 |150|zzz
(3 rows)
starting permutation: s1b s2b s2i s1a s2c s1c s2s
step s1b: begin;
step s2b: begin;
step s2i: insert into tpart values (110,'xxx'), (120, 'yyy'), (150, 'zzz');
step s1a: alter table tpart attach partition tpart_2 for values from (100) to (200); <waiting ...>
step s2c: commit;
step s1a: <... completed>
Use annotations to reduce instability of isolation-test results. We've long contended with isolation test results that aren't entirely stable. Some test scripts insert long delays to try to force stable results, which is not terribly desirable; but other erratic failure modes remain, causing unrepeatable buildfarm failures. I've spent a fair amount of time trying to solve this by improving the server-side support code, without much success: that way is fundamentally unable to cope with diffs that stem from chance ordering of arrival of messages from different server processes. We can improve matters on the client side, however, by annotating the test scripts themselves to show the desired reporting order of events that might occur in different orders. This patch adds three types of annotations to deal with (a) test steps that might or might not complete their waits before the isolationtester can see them waiting; (b) test steps in different sessions that can legitimately complete in either order; and (c) NOTIFY messages that might arrive before or after the completion of a step in another session. We might need more annotation types later, but this seems to be enough to deal with the instabilities we've seen in the buildfarm. It also lets us get rid of all the long delays that were previously used, cutting more than a minute off the runtime of the isolation tests. Back-patch to all supported branches, because the buildfarm instabilities affect all the branches, and because it seems desirable to keep isolationtester's capabilities the same across all branches to simplify possible future back-patching of tests. Discussion: https://postgr.es/m/327948.1623725828@sss.pgh.pa.us
2021-06-23 03:43:12 +02:00
ERROR: updated partition constraint for default partition "tpart_default_default" would be violated by some row
step s1c: commit;
step s2s: select tableoid::regclass, * from tpart;
tableoid | i|j
---------------------+---+---
tpart_default_default|110|xxx
tpart_default_default|120|yyy
tpart_default_default|150|zzz
(3 rows)