Re: Add two missing tests in 035_standby_logical_decoding.pl

Поиск
Список
Период
Сортировка
От Drouvot, Bertrand
Тема Re: Add two missing tests in 035_standby_logical_decoding.pl
Дата
Msg-id 19d8fa0d-e840-66eb-f5bc-4c3f9594ec8b@gmail.com
обсуждение исходный текст
Ответ на Re: Add two missing tests in 035_standby_logical_decoding.pl  (Alvaro Herrera <alvherre@alvh.no-ip.org>)
Ответы Re: Add two missing tests in 035_standby_logical_decoding.pl  (Amit Kapila <amit.kapila16@gmail.com>)
Список pgsql-hackers
Hi,

On 4/26/23 12:27 PM, Alvaro Herrera wrote:
>> diff --git a/src/test/perl/PostgreSQL/Test/Cluster.pm b/src/test/perl/PostgreSQL/Test/Cluster.pm
>> index 6f7f4e5de4..819667d42a 100644
>> --- a/src/test/perl/PostgreSQL/Test/Cluster.pm
>> +++ b/src/test/perl/PostgreSQL/Test/Cluster.pm
>> @@ -2644,7 +2644,16 @@ sub wait_for_catchup
>>       }
>>       if (!defined($target_lsn))
>>       {
>> -        $target_lsn = $self->lsn('write');
>> +        my $isrecovery = $self->safe_psql('postgres', "SELECT pg_is_in_recovery()");
>> +        chomp($isrecovery);
>> +        if ($isrecovery eq 't')
>> +        {
>> +            $target_lsn = $self->lsn('replay');
>> +        }
>> +        else
>> +        {
>> +            $target_lsn = $self->lsn('write');
>> +        }
> 
> Please modify the function's documentation to account for this code change.
> 

Good point, thanks! Done in V6 attached.

Regards,

-- 
Bertrand Drouvot
PostgreSQL Contributors Team
RDS Open Source Databases
Amazon Web Services: https://aws.amazon.com
Вложения

В списке pgsql-hackers по дате отправления:

Предыдущее
От: Daniel Gustafsson
Дата:
Сообщение: Re: Find dangling membership roles in pg_dumpall
Следующее
От: "Drouvot, Bertrand"
Дата:
Сообщение: Re: Add two missing tests in 035_standby_logical_decoding.pl