1
0
mirror of https://github.com/postgrespro/pg_probackup.git synced 2025-02-13 14:58:35 +02:00

Fix validation messages

This commit is contained in:
Artur Zakirov 2017-02-27 16:42:17 +03:00
parent 20e550518c
commit 9454066156

View File

@ -186,7 +186,7 @@ validate_wal(pgBackup *backup,
/* There are all need WAL records */ /* There are all need WAL records */
if (all_wal) if (all_wal)
elog(INFO, "backup validation stopped on time %s and xid " XID_FMT, elog(INFO, "backup validation completed successfully on time %s and xid " XID_FMT,
last_timestamp, last_xid); last_timestamp, last_xid);
/* There are not need WAL records */ /* There are not need WAL records */
else else
@ -213,17 +213,17 @@ validate_wal(pgBackup *backup,
time2iso(target_timestamp, lengthof(target_timestamp), time2iso(target_timestamp, lengthof(target_timestamp),
target_time); target_time);
elog(WARNING, "recovery can be done to time %s and xid " XID_FMT, elog(WARNING, "recovery can be done up to time %s and xid " XID_FMT,
last_timestamp, last_xid); last_timestamp, last_xid);
if (TransactionIdIsValid(target_xid) && target_time != 0) if (TransactionIdIsValid(target_xid) && target_time != 0)
elog(ERROR, "there are no WAL records to time %s and xid " XID_FMT, elog(ERROR, "not enough WAL records to time %s and xid " XID_FMT,
target_timestamp, target_xid); target_timestamp, target_xid);
else if (TransactionIdIsValid(target_xid)) else if (TransactionIdIsValid(target_xid))
elog(ERROR, "there are no WAL records to xid " XID_FMT, elog(ERROR, "not enough WAL records to xid " XID_FMT,
target_xid); target_xid);
else if (target_time != 0) else if (target_time != 0)
elog(ERROR, "there are no WAL records to time %s", elog(ERROR, "not enough WAL records to time %s",
target_timestamp); target_timestamp);
} }
} }