Remove some unstable parts from new TAP test for archive status check
authorMichael Paquier <[email protected]>
Fri, 24 Apr 2020 02:33:41 +0000 (11:33 +0900)
committerMichael Paquier <[email protected]>
Fri, 24 Apr 2020 02:33:41 +0000 (11:33 +0900)
The test is proving to have timing issues when looking at archive status
files on standbys after crash recovery, while other parts of the test
rely on pg_stat_archiver as a wait point to make sure that a given state
of the archiving is reached.  The coverage is not heavily impacted by
the removal those extra tests.

Per reports from several buildfarm animals, like crake, piculet,
culicidae and francolin.

Discussion: https://postgr.es/m/20200424005929[email protected]
Backpatch-through: 9.5

src/test/recovery/t/020_archive_status.pl

index 397352f05893dafb6a714725250ed6db86be6f1c..401412e687b1e3f60f74796bd06e67caa43a1e0a 100644 (file)
@@ -5,7 +5,7 @@ use strict;
 use warnings;
 use PostgresNode;
 use TestLib;
-use Test::More tests => 16;
+use Test::More tests => 13;
 use Config;
 
 my $primary = get_new_node('master');
@@ -136,23 +136,12 @@ my $standby1_data = $standby1->data_dir;
 $standby1->start;
 $standby1->safe_psql('postgres', q{CHECKPOINT});
 
-# Recovery with archive_mode=on does not keep .ready signal files inherited
-# from backup.  Note that this WAL segment existed in the backup.
-ok( !-f "$standby1_data/$segment_path_1_ready",
-       ".ready file for WAL segment $segment_name_1 present in backup got removed with archive_mode=on on standby"
-);
-
 # Recovery with archive_mode=on should not create .ready files.
 # Note that this segment did not exist in the backup.
 ok( !-f "$standby1_data/$segment_path_2_ready",
        ".ready file for WAL segment $segment_name_2 not created on standby when archive_mode=on on standby"
 );
 
-# Recovery with archive_mode = on creates .done files.
-ok( -f "$standby1_data/$segment_path_2_done",
-       ".done file for WAL segment $segment_name_2 created when archive_mode=on on standby"
-);
-
 # Test recovery with archive_mode = always, which should always keep
 # .ready files if archiving is enabled, though here we want the archive
 # command to fail to persist the .ready files.  Note that this node
@@ -170,10 +159,6 @@ ok( -f "$standby2_data/$segment_path_1_ready",
        ".ready file for WAL segment $segment_name_1 existing in backup is kept with archive_mode=always on standby"
 );
 
-ok( -f "$standby2_data/$segment_path_2_ready",
-       ".ready file for WAL segment $segment_name_2 created with archive_mode=always on standby"
-);
-
 # Reset statistics of the archiver for the next checks.
 $standby2->safe_psql('postgres', q{SELECT pg_stat_reset_shared('archiver')});