Re: [HACKERS] Logical Replication and Character encoding

Поиск
Список
Период
Сортировка
От Kyotaro HORIGUCHI
Тема Re: [HACKERS] Logical Replication and Character encoding
Дата
Msg-id 20170214.112352.120935619.horiguchi.kyotaro@lab.ntt.co.jp
обсуждение исходный текст
Ответ на Re: [HACKERS] Logical Replication and Character encoding  (Petr Jelinek <petr.jelinek@2ndquadrant.com>)
Ответы Re: [HACKERS] Logical Replication and Character encoding  (Petr Jelinek <petr.jelinek@2ndquadrant.com>)
Список pgsql-hackers
At Sat, 4 Feb 2017 21:27:32 +0100, Petr Jelinek <petr.jelinek@2ndquadrant.com> wrote in
<bcc7f7e9-f558-b19e-b544-000ba7cf286c@2ndquadrant.com>
> Hmm I wonder if we should just make the subscriber send the
> client_encoding always (based on server encoding of the subscriber).
> That should solve the issue in combination with your patch no?

Yeah, right. I considered that a subscriber might want to set its
own value for that but that is useless.

The attached patch does the following things to just prevent
making a logical replication connection between databases with
inconsistent encodings.

- added client_encoding with subscriber(or standby)'s encoding at the last of options in libpqrcv_connect.

- CheckLogicalDecodingRequirements refuses connection for a request with inconsistent encodings.

> ERROR:  logical replication requires consistent encodings on both side (publisher = UTF8, subscriber = EUC_JP)


We could check this earlier if involving physical replication but
I think this is a matter of logical replication.

regards,

-- 
Kyotaro Horiguchi
NTT Open Source Software Center

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

Предыдущее
От: Andres Freund
Дата:
Сообщение: Re: [HACKERS] PATCH: two slab-like memory allocators
Следующее
От: Andreas Karlsson
Дата:
Сообщение: Re: [HACKERS] REINDEX CONCURRENTLY 2.0