From: | Peter Smith <smithpb2250(at)gmail(dot)com> |
---|---|
To: | Masahiko Sawada <sawada(dot)mshk(at)gmail(dot)com> |
Cc: | shveta malik <shveta(dot)malik(at)gmail(dot)com>, Amit Kapila <amit(dot)kapila16(at)gmail(dot)com>, "Hayato Kuroda (Fujitsu)" <kuroda(dot)hayato(at)fujitsu(dot)com>, Ashutosh Bapat <ashutosh(dot)bapat(dot)oss(at)gmail(dot)com>, Shlok Kyal <shlok(dot)kyal(dot)oss(at)gmail(dot)com>, Bertrand Drouvot <bertranddrouvot(dot)pg(at)gmail(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: POC: enable logical decoding when wal_level = 'replica' without a server restart |
Date: | 2025-10-16 00:13:38 |
Message-ID: | CAHut+PsF9u5+oVp48eRb2agzp06_Tgh4LCiRr--+ykps8xzBNQ@mail.gmail.com |
Views: | Whole Thread | Raw Message | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Thu, Oct 16, 2025 at 9:48 AM Masahiko Sawada <sawada(dot)mshk(at)gmail(dot)com> wrote:
>
...
> > ditto above. Those >= seem to make it more complex than necessary.
> >
> > errmsg can be: "...requires \"effective_wal_level\" to be \"logical\"
> > on the ..."
> > errhint can be: "...set \"wal_level\" = \"logical\" or..."
>
> It seems we're already using >= in many places even before the patch:
>
> src/backend/access/transam/xlogfuncs.c:
> errmsg("pg_log_standby_snapshot() can only be used if \"wal_level\" >=
> \"replica\"")));
> src/backend/postmaster/postmaster.c:
> (errmsg("replication slot synchronization (\"sync_replication_slots\"
> = on) requires \"wal_level\" >= \"logical\"")));
> src/backend/replication/logical/decode.c:
> errmsg("logical decoding on standby requires
> \"wal_level\" >= \"logical\" on the primary")));
> src/backend/replication/logical/logical.c:
> errmsg("logical decoding requires \"wal_level\" >= \"logical\"")));
> src/backend/replication/logical/logical.c:
> errmsg("logical decoding on standby requires \"wal_level\"
> >= \"logical\" on the primary")));
> src/backend/replication/logical/slotsync.c:
> errmsg("replication slot synchronization requires \"wal_level\" >=
> \"logical\""));
>
> I agree that it makes the message more complex than necessary. I
> imagine that we used that style since we can avoid editing these
> messages when we introduce a higher level than 'logical', but I think
> it's likely to adjust the messages in that case anyway. So how about
> discussing this topic in another thread to simply improve the
> user-faced error messages? If we can agree on such changes, this patch
> can follow the new style.
>
OK, done. See [1]
Kind Regards,
Peter Smith.
Fujitsu Australia
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2025-10-16 00:18:41 | Re: remove partColsUpdated |
Previous Message | Peter Smith | 2025-10-16 00:05:58 | Should we say "wal_level = logical" instead of "wal_level >= logical" |