summaryrefslogtreecommitdiff
path: root/src/test/recovery/t/003_recovery_targets.pl
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/recovery/t/003_recovery_targets.pl')
-rw-r--r--src/test/recovery/t/003_recovery_targets.pl16
1 files changed, 8 insertions, 8 deletions
diff --git a/src/test/recovery/t/003_recovery_targets.pl b/src/test/recovery/t/003_recovery_targets.pl
index a82545bf6f..b7b0caae68 100644
--- a/src/test/recovery/t/003_recovery_targets.pl
+++ b/src/test/recovery/t/003_recovery_targets.pl
@@ -32,7 +32,7 @@ sub test_recovery_standby
# Wait until standby has replayed enough data
my $caughtup_query =
- "SELECT '$until_lsn'::pg_lsn <= pg_last_xlog_replay_location()";
+ "SELECT '$until_lsn'::pg_lsn <= pg_last_wal_replay_location()";
$node_standby->poll_query_until('postgres', $caughtup_query)
or die "Timed out while waiting for standby to catch up";
@@ -57,7 +57,7 @@ $node_master->start;
$node_master->safe_psql('postgres',
"CREATE TABLE tab_int AS SELECT generate_series(1,1000) AS a");
my $lsn1 =
- $node_master->safe_psql('postgres', "SELECT pg_current_xlog_location();");
+ $node_master->safe_psql('postgres', "SELECT pg_current_wal_location();");
# Take backup from which all operations will be run
$node_master->backup('my_backup');
@@ -67,14 +67,14 @@ $node_master->backup('my_backup');
$node_master->safe_psql('postgres',
"INSERT INTO tab_int VALUES (generate_series(1001,2000))");
my $ret = $node_master->safe_psql('postgres',
- "SELECT pg_current_xlog_location(), txid_current();");
+ "SELECT pg_current_wal_location(), txid_current();");
my ($lsn2, $recovery_txid) = split /\|/, $ret;
# More data, with recovery target timestamp
$node_master->safe_psql('postgres',
"INSERT INTO tab_int VALUES (generate_series(2001,3000))");
$ret = $node_master->safe_psql('postgres',
- "SELECT pg_current_xlog_location(), now();");
+ "SELECT pg_current_wal_location(), now();");
my ($lsn3, $recovery_time) = split /\|/, $ret;
# Even more data, this time with a recovery target name
@@ -82,22 +82,22 @@ $node_master->safe_psql('postgres',
"INSERT INTO tab_int VALUES (generate_series(3001,4000))");
my $recovery_name = "my_target";
my $lsn4 =
- $node_master->safe_psql('postgres', "SELECT pg_current_xlog_location();");
+ $node_master->safe_psql('postgres', "SELECT pg_current_wal_location();");
$node_master->safe_psql('postgres',
"SELECT pg_create_restore_point('$recovery_name');");
# And now for a recovery target LSN
$node_master->safe_psql('postgres',
"INSERT INTO tab_int VALUES (generate_series(4001,5000))");
-my $recovery_lsn = $node_master->safe_psql('postgres', "SELECT pg_current_xlog_location()");
+my $recovery_lsn = $node_master->safe_psql('postgres', "SELECT pg_current_wal_location()");
my $lsn5 =
- $node_master->safe_psql('postgres', "SELECT pg_current_xlog_location();");
+ $node_master->safe_psql('postgres', "SELECT pg_current_wal_location();");
$node_master->safe_psql('postgres',
"INSERT INTO tab_int VALUES (generate_series(5001,6000))");
# Force archiving of WAL file
-$node_master->safe_psql('postgres', "SELECT pg_switch_xlog()");
+$node_master->safe_psql('postgres', "SELECT pg_switch_wal()");
# Test recovery targets
my @recovery_params = ("recovery_target = 'immediate'");