Re: postgres_fdw test timeouts

2023-12-02 Thread Thomas Munro
On Sun, Dec 3, 2023 at 6:00 PM Alexander Lakhin wrote: > I've managed to reproduce the failure locally when running postgres_fdw_x/ > regress in parallel (--num-processes 10). It reproduced for me on > on 04a09ee94 (iterations 1, 2, 4), but not on 04a09ee94~1 (30 iterations > passed). > > I'm goin

Re: Schema variables - new implementation for Postgres 15

2023-12-02 Thread Pavel Stehule
Hi ne 26. 11. 2023 v 18:56 odesílatel Dmitry Dolgov <9erthali...@gmail.com> napsal: > > On Sat, Nov 18, 2023 at 06:28:53PM +0100, Pavel Stehule wrote: > > so 18. 11. 2023 v 15:54 odesílatel Dmitry Dolgov <9erthali...@gmail.com> > > napsal: > > > As a side note, I'm intended to go one more time th

Re: postgres_fdw test timeouts

2023-12-02 Thread Alexander Lakhin
Hello Thomas, 03.12.2023 02:48, Thomas Munro wrote: Thanks for finding this correlation. Yeah, poking around in the cfbot history database I see about 1 failure like that per day since that date, and there doesn't seem to be anything else as obviously likely to be related to wakeups and timeout

Re: Patch: Improve Boolean Predicate JSON Path Docs

2023-12-02 Thread shihao zhong
The following review has been posted through the commitfest application: make installcheck-world: not tested Implements feature: not tested Spec compliant: not tested Documentation:tested, passed I took a look for this commit, it looks correct to me

Re: postgres_fdw test timeouts

2023-12-02 Thread Thomas Munro
On Fri, Dec 1, 2023 at 9:38 AM Nathan Bossart wrote: > AFAICT the failures began around September 10th, which leads me to wonder > if this is related to commit 04a09ee. That is little more than a wild > guess, though. I haven't been able to deduce much else from the logs I can > find, and I didn

Re: Is WAL_DEBUG related code still relevant today?

2023-12-02 Thread Tom Lane
Nathan Bossart writes: > On Sat, Dec 02, 2023 at 07:36:29PM +0530, Bharath Rupireddy wrote: >> I started to think if this code is needed at all in production. How >> about we do either of the following? > Well, the fact that this code is hidden behind an off-by-default macro > seems like a pretty

Re: Emitting JSON to file using COPY TO

2023-12-02 Thread Joe Conway
On 12/2/23 13:50, Maciek Sakrejda wrote: On Fri, Dec 1, 2023 at 11:32 AM Joe Conway wrote: 1. Is supporting JSON array format sufficient, or does it need to support some other options? How flexible does the support scheme need to be? "JSON Lines" is a semi-standard format [1] that's basically

Re: Emitting JSON to file using COPY TO

2023-12-02 Thread Joe Conway
On 12/2/23 16:53, Nathan Bossart wrote: On Sat, Dec 02, 2023 at 10:11:20AM -0500, Tom Lane wrote: So if you are writing a production that might need to match FORMAT followed by JSON, you need to match FORMAT_LA too. Thanks for the pointer. That does seem to be the culprit. diff --git a/src/b

Re: Is WAL_DEBUG related code still relevant today?

2023-12-02 Thread Nathan Bossart
On Sat, Dec 02, 2023 at 07:36:29PM +0530, Bharath Rupireddy wrote: > I started to think if this code is needed at all in production. How > about we do either of the following? Well, the fact that this code is hidden behind an off-by-default macro seems like a pretty strong indicator that it is not

Re: about help message for new pg_dump's --filter option

2023-12-02 Thread Daniel Gustafsson
> On 2 Dec 2023, at 17:02, Alvaro Herrera wrote: > > On 2023-Nov-30, Kyotaro Horiguchi wrote: > >> Hello. >> >> Recently, a new --filter option was added to pg_dump. I might be >> wrong, but the syntax of the help message for this feels off. Is the >> word 'on' not necessary after 'based'? >>

Re: Emitting JSON to file using COPY TO

2023-12-02 Thread Nathan Bossart
On Sat, Dec 02, 2023 at 10:11:20AM -0500, Tom Lane wrote: > So if you are writing a production that might need to match > FORMAT followed by JSON, you need to match FORMAT_LA too. Thanks for the pointer. That does seem to be the culprit. diff --git a/src/backend/parser/gram.y b/src/backend/parse

Re: Proposal obfuscate password in pg logs

2023-12-02 Thread Tom Lane
Guanqun Yang writes: > We notice Postgres logs, pg_stat_statements and pg_stat_activity will > record passwords when using "CREATE" statement to create user with > password. Can we provide users with an option to obfuscate those passwords? See the many, many prior discussions of this idea. The sh

Re: Proposal: In-flight explain logging

2023-12-02 Thread Rafael Thofehrn Castro
Hello Maciek, Thanks for pointing that out. They are indeed super similar. Before I wrote the patch I searched for "explain" related ones. I guess I should have performed a better search. Comparing the patches, there is one main difference: the existing patch prints only the plan without any inst

Proposal obfuscate password in pg logs

2023-12-02 Thread Guanqun Yang
hey guys, We notice Postgres logs, pg_stat_statements and pg_stat_activity will record passwords when using "CREATE" statement to create user with password. Can we provide users with an option to obfuscate those passwords? Yours, Guanqun

Re: Proposal: In-flight explain logging

2023-12-02 Thread Maciek Sakrejda
Have you seen the other recent patch regarding this? [1] The mailing list thread was active pretty recently. The submission is marked as Needs Review. I haven't looked at either patch, but the proposals are very similar as I understand it. [1]: https://commitfest.postgresql.org/45/4345/

Proposal: In-flight explain logging

2023-12-02 Thread Rafael Thofehrn Castro
Hello hackers, # MOTIVATION My recent experiences with problematic queries in customers motivated me to write this patch proposing a new feature to enhance visibility on what active queries are doing. PostgreSQL already offers 2 very powerful tools for query troubleshooting: - EXPLAIN: gives us

Re: Emitting JSON to file using COPY TO

2023-12-02 Thread Maciek Sakrejda
On Fri, Dec 1, 2023 at 11:32 AM Joe Conway wrote: > 1. Is supporting JSON array format sufficient, or does it need to > support some other options? How flexible does the support scheme need to be? "JSON Lines" is a semi-standard format [1] that's basically just newline-separated JSON values. (In

Re: SQL:2011 application time

2023-12-02 Thread Paul Jungwirth
On Thu, Nov 23, 2023 at 1:08 AM Peter Eisentraut wrote: > After further thought, I think the right solution is to change > btree_gist (and probably also btree_gin) to use the common RT* strategy > numbers. Okay. That will mean bumping the version of btree_gist, and you must be running that versi

Re: undetected deadlock in ALTER SUBSCRIPTION ... REFRESH PUBLICATION

2023-12-02 Thread Shlok Kyal
Hi, > thread. I think you can compare the timing of regression tests in > subscription, with and without the patch to show there is no > regression. And probably some tests with a large number of tables for > sync with very little data. I have tested the regression test timings for subscription w

Re: about help message for new pg_dump's --filter option

2023-12-02 Thread Alvaro Herrera
On 2023-Nov-30, Kyotaro Horiguchi wrote: > Hello. > > Recently, a new --filter option was added to pg_dump. I might be > wrong, but the syntax of the help message for this feels off. Is the > word 'on' not necessary after 'based'? > > > --filter=FILENAMEinclude or exclude objects an

Re: Emitting JSON to file using COPY TO

2023-12-02 Thread Tom Lane
Joe Conway writes: >> I noticed that, with the PoC patch, "json" is the only format that must be >> quoted. Without quotes, I see a syntax error. I'm assuming there's a >> conflict with another json-related rule somewhere in gram.y, but I haven't >> tracked down exactly which one is causing it.

Re: Emitting JSON to file using COPY TO

2023-12-02 Thread Joe Conway
On 12/1/23 18:09, Nathan Bossart wrote: On Fri, Dec 01, 2023 at 02:28:55PM -0500, Joe Conway wrote: I did a quick PoC patch (attached) -- if there interest and no hard objections I would like to get it up to speed for the January commitfest. Cool. I would expect there to be interest, given al

Is WAL_DEBUG related code still relevant today?

2023-12-02 Thread Bharath Rupireddy
Hi, I was recently looking at the code around the WAL_DEBUG macro and GUC. When enabled, the code does the following: 1. Creates a memory context that allows pallocs within critical sections. 2. Decodes (not logical decoding but DecodeXLogRecord()) every WAL record using the above memory context

Re: Remove unnecessary includes of system headers in header files

2023-12-02 Thread Peter Eisentraut
On 01.12.23 17:41, Tom Lane wrote: Peter Eisentraut writes: I noticed that some header files included system header files for no apparent reason, so I did some digging and found out that in a few cases the original reason has disappeared. So I propose the attached patches to remove the unneces

Re: Change GUC hashtable to use simplehash?

2023-12-02 Thread John Naylor
On Wed, Nov 29, 2023 at 8:31 PM John Naylor wrote: > > Attached is a rough start with Andres's earlier ideas, to get > something concrete out there. While looking at the assembly out of curiosity, I found a couple bugs in the split API that I've fixed locally. I think the path forward is: - per