Improve logical decoding error message (was wal_level > WAL_LEVEL_LOGICAL)

From: Neha Khatri <nehakhatri5(at)gmail(dot)com>
To: pgsql-hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Improve logical decoding error message (was wal_level > WAL_LEVEL_LOGICAL)
Date: 2017-05-22 23:08:12
Message-ID: CAFO0U+_y8AyAcQLiF3S1i6yCNuYrcLNEd-BbzCuHiGOSejW=2A@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Mon, May 22, 2017 at 11:08 PM, Neha Khatri <nehakhatri5(at)gmail(dot)com> wrote:

> As per my understabding, current postgres server supports only three
> values for wal_level i.e. 'minimal' , 'replica' or 'logical'. But
> following error message brought to notice that there are various code
> spots that try to look for wal_level >= WAL_LEVEL_LOGICAL:
>
> select * from pg_create_logical_replication_slot('regression_slot',
> 'test_decoding');
> ERROR: logical decoding requires wal_level >= logical
>

The Logical Decoding example in the documentation says:

"Before you can use logical decoding, you must set wal_level
<https://www.postgresql.org/docs/10/static/runtime-config-wal.html#guc-wal-level>
to logical and max_replication_slots
<https://www.postgresql.org/docs/10/static/runtime-config-replication.html#guc-max-replication-slots>
to
at least 1."

But above error message is not exactly consistent with this documentation.
Would it make sense to keep the error message and the documentation
consistent like the attached.

Regards,
Neha

Attachment Content-Type Size
improve_err_message.patch application/octet-stream 579 bytes

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Mark Rofail 2017-05-22 23:51:33 GSoC 2017: Foreign Key Arrays
Previous Message Alvaro Herrera 2017-05-22 22:39:18 Re: PG10 Crash-safe and replicable Hash Indexes and UNIQUE