Re: row filtering for logical replication

2021-10-11 Thread Ajin Cherian
On Tue, Oct 12, 2021 at 1:37 AM Dilip Kumar wrote: > > On Wed, Oct 6, 2021 at 2:33 PM Ajin Cherian wrote: > > > > On Sat, Oct 2, 2021 at 5:44 PM Ajin Cherian wrote: > > > > > > I have for now also rebased the patch and merged the first 5 patches > > > into 1, and added my changes for the above i

Re: Corruption with IMMUTABLE functions in index expression.

2021-10-11 Thread Andres Freund
Hi, On 2021-10-11 14:59:22 -0400, Tom Lane wrote: > Andres Freund writes: > > Perhaps we could set pg_index.indisvalid to false initially, and if opening > > an > > index where pg_index.indisvalid error out with a different error message if > > TransactionIdIsCurrentTransactionId(xmin). And then

Re: Corruption with IMMUTABLE functions in index expression.

2021-10-11 Thread Tom Lane
Andres Freund writes: > On 2021-10-11 14:59:22 -0400, Tom Lane wrote: >> I doubt we need any code changes beyond changing the indisvalid state. > I was thinking we'd want to throw an error if an index that's being created is > accessed during the index build, rather than just not include it in >

Re: Allow escape in application_name

2021-10-11 Thread Fujii Masao
On 2021/10/07 11:46, kuroda.hay...@fujitsu.com wrote: So now we can choose from followings: * ignore such differences and use isdigit() and strtol() * give up using them and implement two static support functions How do you think? Someone knows any other knowledge about locale? Replacing p

Re: postgres_fdw: misplaced? comments in connection.c

2021-10-11 Thread Etsuro Fujita
On Mon, Oct 11, 2021 at 5:05 PM Etsuro Fujita wrote: > The comments for pgfdw_get_cleanup_result() say this: > > * It's not a huge problem if we throw an ERROR here, but if we get into error > * recursion trouble, we'll end up slamming the connection shut, which will > * necessitate failing the

Re: Rewriting the test of pg_upgrade as a TAP test - take three - remastered set

2021-10-11 Thread Michael Paquier
On Sun, Oct 03, 2021 at 08:22:57AM -0400, Andrew Dunstan wrote: > Actually, I was wrong. The module just does "make check" for non-MSVC. > For MSVC it calls vcregress.pl, which the patch doesn't touch (it > should, I think). Yes, it should. And I'd like to do things so as we replace all the inter

Re: Rewriting the test of pg_upgrade as a TAP test - take three - remastered set

2021-10-11 Thread Michael Paquier
On Mon, Oct 11, 2021 at 09:04:47AM -0400, Andrew Dunstan wrote: > Keeping test.sh is not necessary - I mis-remembered what the test module > does. So.. Are people fine to remove entirely test.sh at the end, requiring the tests of pg_upgrade to have TAP installed? I'd rather raise the bar here, a

Re: Skipping logical replication transactions on subscriber side

2021-10-11 Thread Masahiko Sawada
On Fri, Oct 8, 2021 at 8:17 PM Greg Nancarrow wrote: > > On Thu, Sep 30, 2021 at 3:45 PM Masahiko Sawada wrote: > > > > I've attached updated patches that incorporate all comments I got so > > far. Please review them. > > > > Some comments about the v15-0001 patch: Thank you for the comments! >

Re: Error "initial slot snapshot too large" in create replication slot

2021-10-11 Thread Kyotaro Horiguchi
At Mon, 11 Oct 2021 16:48:10 +0530, Dilip Kumar wrote in > On Mon, Oct 11, 2021 at 4:29 PM Kyotaro Horiguchi > wrote: > > > > At Mon, 11 Oct 2021 11:49:41 +0530, Dilip Kumar > > wrote in > > > While creating an "export snapshot" I don't see any protection why the > > > number of xids in the s

Re: Skipping logical replication transactions on subscriber side

2021-10-11 Thread Masahiko Sawada
On Fri, Oct 8, 2021 at 9:22 PM osumi.takami...@fujitsu.com wrote: > > On Thursday, September 30, 2021 2:45 PM Masahiko Sawada > wrote: > > I've attached updated patches that incorporate all comments I got so far. > > Please > > review them. > Hello > > > Minor two comments for v15-0001 patch. >

Re: Error "initial slot snapshot too large" in create replication slot

2021-10-11 Thread Kyotaro Horiguchi
At Tue, 12 Oct 2021 13:59:59 +0900 (JST), Kyotaro Horiguchi wrote in > So I came up with the attached version. Sorry, it was losing a piece of change. -- Kyotaro Horiguchi NTT Open Source Software Center >From 424f405b4c9d41471eae1edd48cdbb6a6d47217e Mon Sep 17 00:00:00 2001 From: Kyotaro Hor

Re: Printing backtrace of postgres processes

2021-10-11 Thread bt21tanigaway
Hi, The previous patch was failing because of the recent test changes made by commit 201a76183e2 which unified new and get_new_node, attached patch has the changes to handle the changes accordingly. Thanks for your update! I have two comments. 1.Do we need “set_backtrace(NULL, 0);” on “HandleM

Re: storing an explicit nonce

2021-10-11 Thread Ants Aasma
On Mon, 11 Oct 2021 at 22:15, Bruce Momjian wrote: > > Yes, that's the direction that I was thinking also and specifically with > > XTS as the encryption algorithm to allow us to exclude the LSN but keep > > everything else, and to address the concern around the nonce/tweak/etc > > being the same

Re: Bug in DefineRange() with multiranges

2021-10-11 Thread Sergey Shinderuk
On 10.10.2021 20:12, Peter Eisentraut wrote: On 04.10.21 19:09, Sergey Shinderuk wrote: I wonder what is the proper fix.  Just drop pfree() altogether or add pstrdup() instead?  I see that makeMultirangeTypeName() doesn't bother freeing its buf. I think removing the pfree()s is a correct fix.

Re: Error "initial slot snapshot too large" in create replication slot

2021-10-11 Thread Dilip Kumar
On Tue, Oct 12, 2021 at 10:35 AM Kyotaro Horiguchi wrote: > > At Tue, 12 Oct 2021 13:59:59 +0900 (JST), Kyotaro Horiguchi > wrote in > > So I came up with the attached version. > > Sorry, it was losing a piece of change. Yeah, at a high level this is on the idea I have in mind, I will do a deta

Re: Allow escape in application_name

2021-10-11 Thread Kyotaro Horiguchi
At Tue, 12 Oct 2021 13:25:01 +0900, Fujii Masao wrote in > > > On 2021/10/07 11:46, kuroda.hay...@fujitsu.com wrote: > > So now we can choose from followings: > >* ignore such differences and use isdigit() and strtol() > > * give up using them and implement two static support functions > >How

Re: Reword docs of feature "Remove temporary files after backend crash"

2021-10-11 Thread Bharath Rupireddy
On Mon, Oct 11, 2021 at 11:37 AM Fujii Masao wrote: > > IMO, we can add the new description as proposed in my v1 patch (after > > adding startup process to the exception list) to both the GUCs > > restart_after_crash and remove_temp_files_after_crash. And, in > > remove_temp_files_after_crash GUC

Re: Allow escape in application_name

2021-10-11 Thread Kyotaro Horiguchi
At Tue, 12 Oct 2021 15:06:11 +0900 (JST), Kyotaro Horiguchi wrote in > "%4%5%6%7p" is converted to "57p". Do we need to imitate that bug > with this patch? So.. I try to describe the behavior for exhaustive patterns.. current: A. "^-?[0-9]+.*" : returns valid padding. p goes after the last d

Re: Accommodate startup process in a separate ProcState array slot instead of in MaxBackends slots.

2021-10-11 Thread Bharath Rupireddy
On Tue, Oct 12, 2021 at 5:37 AM Fujii Masao wrote: > > On 2021/10/12 4:07, Bharath Rupireddy wrote: > > Hi, > > > > While working on [1], it is found that currently the ProcState array > > doesn't have entries for auxiliary processes, it does have entries for > > MaxBackends. But the startup proce

Re: Parallel vacuum workers prevent the oldest xmin from advancing

2021-10-11 Thread Masahiko Sawada
On Mon, Oct 11, 2021 at 9:51 AM Michael Paquier wrote: > > On Mon, Oct 11, 2021 at 09:23:32AM +0900, Masahiko Sawada wrote: > > On Sat, Oct 9, 2021 at 12:13 AM Alvaro Herrera > > wrote: > >> * PROC_VACUUM_FOR_WRAPAROUND. Should be innocuous I think, since the > >> "parent" process already has t

RE: Added schema level support for publication.

2021-10-11 Thread houzj.f...@fujitsu.com
On Monday, October 11, 2021 11:02 PM vignesh C wrote: > The attached v39 patch has the fixes for the above issues. Thanks for the updates. I have a few minor suggestions about the testcases in the v39-0003-Test patch. 1) +-- alter publication drop CURRENT_SCHEMA +ALTER PUBLICATION testpub1_forsc

Re: Allow escape in application_name

2021-10-11 Thread Kyotaro Horiguchi
At Tue, 12 Oct 2021 15:42:23 +0900 (JST), Kyotaro Horiguchi wrote in > If we code as the following: ... > A. "^-?[0-9]+.*" : same to the current > B. "^[^0-9-].*" : same to the current > C. "^-[^0-9].*" : padding = 0, p doesn't advance. > D. "^-" : padding = 0, p doesn't advan

<    1   2