| From: | Chao Li <li(dot)evan(dot)chao(at)gmail(dot)com> |
|---|---|
| To: | Peter Smith <smithpb2250(at)gmail(dot)com> |
| Cc: | Ashutosh Bapat <ashutosh(dot)bapat(dot)oss(at)gmail(dot)com>, Robert Haas <robertmhaas(at)gmail(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org> |
| Subject: | Re: Should we say "wal_level = logical" instead of "wal_level >= logical" |
| Date: | 2025-11-11 05:57:33 |
| Message-ID: | 06EAC2D9-F8FF-418D-97DE-D8B722D94E34@gmail.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
> On Nov 4, 2025, at 09:43, Peter Smith <smithpb2250(at)gmail(dot)com> wrote:
>
> On Wed, Oct 29, 2025 at 8:10 PM Chao Li <li(dot)evan(dot)chao(at)gmail(dot)com> wrote:
> ...
>> I think 0001 basically good. A tiny comment is that, in inval.c, "wal_level>=logical” doesn’t have white-spaces around “=“, while in the other two files, they have. So maybe all add white-spaces around “=“ here.
>>
>> For 0002, I have a fixed feeling.
>>
>> This change is okay to me:
>> ```
>> - if (wal_level != WAL_LEVEL_LOGICAL)
>> + if (wal_level < WAL_LEVEL_LOGICAL)
>> ```
>>
>> But I really don’t like the error message changes:
>> ```
>> if (nslots_on_old > 0 && strcmp(wal_level, "logical") != 0)
>> - pg_fatal("\"wal_level\" must be \"logical\" but is set to \"%s\"",
>> + pg_fatal("\"wal_level\" must be \"logical\" or higher but is set to \"%s\"",
>> ```
>> And
>> ```
>> -HINT: Set "wal_level" to "logical" before creating subscriptions.
>> +HINT: Set "wal_level" >= "logical" before creating subscriptions.
>> ```
>>
>> Which will really make end users confused. I believe end users don’t care about so-called future extensions, they only need accurate information.
>>
>
> Hi Chao.
>
> Thanks for your review comments. Here are the v3* patches.
>
> * Patch 0001 - Fixed spaces per suggestion.
>
> * Patch 0002 - Unchanged. For now, this patch 0002 is mostly only a
> placeholder until Sawada-San's patch [1] is pushed, and then I will
> revisit it. There is lots of overlap, so perhaps much of it will be
> made redundant.
>
> ======
> [1] https://www.postgresql.org/message-id/flat/CAD21AoAtqpZW%3DzC57qxEFbBCVhJ2kF2HXmuUT3w_tHGZCYmpnw%40mail.gmail.com
>
> Kind Regards,
> Peter Smith.
> Fujitsu Australia
> <v3-0002-fix-wal_level-equality-code.patch><v3-0001-fix-wal_level-equality-comments.patch>
0001 looks good to me now.
Best regards,
--
Chao Li (Evan)
HighGo Software Co., Ltd.
https://www.highgo.com/
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Mahendra Singh Thalor | 2025-11-11 05:59:04 | Re: Non-text mode for pg_dumpall |
| Previous Message | John Naylor | 2025-11-11 05:56:42 | HASH INDEX builds seems confused |