Location via proxy:   [ UP ]  
[Report a bug]   [Manage cookies]                
Skip to content

Commit 73822b8

Browse files
committed
Raise some timeouts to 180s, in test code.
Slow runs of buildfarm members chipmunk, hornet and mandrill saw the shorter timeouts expire. The 180s timeout in poll_query_until has been trouble-free since 2a0f89c introduced it two years ago, so use 180s more widely. Back-patch to 9.6, where the first of these timeouts was introduced. Reviewed by Michael Paquier. Discussion: https://postgr.es/m/20181209001601.GC2973271@rfd.leadboat.com
1 parent 62999b9 commit 73822b8

File tree

4 files changed

+13
-13
lines changed

4 files changed

+13
-13
lines changed

src/test/isolation/README

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -108,8 +108,8 @@ Each step may contain commands that block until further action has been taken
108108
deadlock). A test that uses this ability must manually specify valid
109109
permutations, i.e. those that would not expect a blocked session to execute a
110110
command. If a test fails to follow that rule, isolationtester will cancel it
111-
after 60 seconds. If the cancel doesn't work, isolationtester will exit
112-
uncleanly after a total of 75 seconds of wait time. Testing invalid
111+
after 180 seconds. If the cancel doesn't work, isolationtester will exit
112+
uncleanly after a total of 200 seconds of wait time. Testing invalid
113113
permutations should be avoided because they can make the isolation tests take
114114
a very long time to run, and they serve no useful testing purpose.
115115

src/test/isolation/isolationtester.c

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -766,15 +766,15 @@ try_complete_step(Step *step, int flags)
766766
td += (int64) current_time.tv_usec - (int64) start_time.tv_usec;
767767

768768
/*
769-
* After 60 seconds, try to cancel the query.
769+
* After 180 seconds, try to cancel the query.
770770
*
771771
* If the user tries to test an invalid permutation, we don't want
772772
* to hang forever, especially when this is running in the
773-
* buildfarm. So try to cancel it after a minute. This will
774-
* presumably lead to this permutation failing, but remaining
775-
* permutations and tests should still be OK.
773+
* buildfarm. This will presumably lead to this permutation
774+
* failing, but remaining permutations and tests should still be
775+
* OK.
776776
*/
777-
if (td > 60 * USECS_PER_SEC && !canceled)
777+
if (td > 180 * USECS_PER_SEC && !canceled)
778778
{
779779
PGcancel *cancel = PQgetCancel(conn);
780780

@@ -791,15 +791,15 @@ try_complete_step(Step *step, int flags)
791791
}
792792

793793
/*
794-
* After 75 seconds, just give up and die.
794+
* After 200 seconds, just give up and die.
795795
*
796796
* Since cleanup steps won't be run in this case, this may cause
797797
* later tests to fail. That stinks, but it's better than waiting
798798
* forever for the server to respond to the cancel.
799799
*/
800-
if (td > 75 * USECS_PER_SEC)
800+
if (td > 200 * USECS_PER_SEC)
801801
{
802-
fprintf(stderr, "step %s timed out after 75 seconds\n",
802+
fprintf(stderr, "step %s timed out after 200 seconds\n",
803803
step->name);
804804
exit_nicely();
805805
}

src/test/recovery/t/006_logical_decoding.pl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@
7272
print "waiting to replay $endpos\n";
7373

7474
my $stdout_recv = $node_master->pg_recvlogical_upto(
75-
'postgres', 'test_slot', $endpos, 10,
75+
'postgres', 'test_slot', $endpos, 180,
7676
'include-xids' => '0',
7777
'skip-empty-xacts' => '1');
7878
chomp($stdout_recv);
@@ -84,7 +84,7 @@
8484
) or die "slot never became inactive";
8585

8686
$stdout_recv = $node_master->pg_recvlogical_upto(
87-
'postgres', 'test_slot', $endpos, 10,
87+
'postgres', 'test_slot', $endpos, 180,
8888
'include-xids' => '0',
8989
'skip-empty-xacts' => '1');
9090
chomp($stdout_recv);

src/test/recovery/t/010_logical_decoding_timelines.pl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -183,7 +183,7 @@ BEGIN
183183

184184
$stdout = $node_replica->pg_recvlogical_upto(
185185
'postgres', 'before_basebackup',
186-
$endpos, 30,
186+
$endpos, 180,
187187
'include-xids' => '0',
188188
'skip-empty-xacts' => '1');
189189

0 commit comments

Comments
 (0)