Re: Moving forward with TDE

2023-12-16 Thread Chris Travers
Hi, I was re-reading the patches here and there was one thing I didn't understand. There are provisions for a separation of data encryption keys for primary and replica I see, and these share a single WAL key. But if I am setting up a replica from the primary, and the primary is already

Re: [PoC] pg_upgrade: allow to upgrade publisher node

2023-12-16 Thread Alexander Lakhin
17.12.2023 07:02, Thomas Munro wrote: FYI fairywren failed in this test: https://buildfarm.postgresql.org/cgi-bin/show_log.pl?nm=fairywren=2023-12-16%2022%3A03%3A06 ===8<=== Restoring database schemas in the new cluster *failure* Consult the last few lines of

Re: [PoC] pg_upgrade: allow to upgrade publisher node

2023-12-16 Thread Thomas Munro
FYI fairywren failed in this test: https://buildfarm.postgresql.org/cgi-bin/show_log.pl?nm=fairywren=2023-12-16%2022%3A03%3A06 ===8<=== Restoring database schemas in the new cluster *failure* Consult the last few lines of

Re: Synchronizing slots from primary to standby

2023-12-16 Thread Amit Kapila
On Fri, Dec 15, 2023 at 5:55 PM Nisha Moond wrote: > > (1) > When we try to create a subscription on standby using a synced slot > that is in 'r' sync_state, the subscription will be created at the > subscriber, and on standby, two actions will take place - > (i) As copy_data is true by

Re: Improve eviction algorithm in ReorderBuffer

2023-12-16 Thread Amit Kapila
On Fri, Dec 15, 2023 at 11:29 AM Masahiko Sawada wrote: > > On Fri, Dec 15, 2023 at 12:37 PM Amit Kapila wrote: > > > > On Wed, Dec 13, 2023 at 6:01 AM Masahiko Sawada > > wrote: > > > > > > > IIUC, you are giving preference to multiple list ideas as compared to > > (a) because you don't need

Re: XID formatting and SLRU refactorings

2023-12-16 Thread Thomas Munro
Hi, https://buildfarm.postgresql.org/cgi-bin/show_log.pl?nm=loach=2023-12-16%2005%3A25%3A18 TRAP: failed Assert("epoch > 0"), File: "twophase.c", Line: 969, PID: 71030 0xa8edcd at /usr/home/pgbf/buildroot/HEAD/pgsql.build/tmp_install/home/pgbf/buildroot/HEAD/inst/bin/postgres 0x613863 at

Re: Show WAL write and fsync stats in pg_stat_io

2023-12-16 Thread Michael Paquier
On Tue, Dec 12, 2023 at 02:29:03PM +0300, Nazir Bilal Yavuz wrote: > On Tue, 5 Dec 2023 at 09:16, Michael Paquier wrote: >> This interface from pgstat_prepare_io_time() is not really good, >> because we could finish by setting io_start in the existing code paths >> calling this routine even if

Re: useless LIMIT_OPTION_DEFAULT

2023-12-16 Thread Alvaro Herrera
On 2023-Dec-14, Tom Lane wrote: > Zhang Mingli writes: > > By reading the codes, I found that we process limit option as > > LIMIT_OPTION_WITH_TIES when using WITH TIES > > and all others are LIMIT_OPTION_COUNT by  commit > > 357889eb17bb9c9336c4f324ceb1651da616fe57. > > And check actual limit

Re: [PoC] Reducing planning time when tables have many partitions

2023-12-16 Thread Alena Rybakina
Hi! On 13.12.2023 09:21, Yuya Watari wrote: Hello Alena, Andrei, and all, I am sorry for my late response. I found that the current patches do not apply to the master, so I have rebased those patches. I have attached v22. For this later discussion, I separated the rebasing and bug fixing that

Re: [PATCH] Add support function for containment operators

2023-12-16 Thread jian he
fix a typo and also did a minor change. from + if (lowerExpr != NULL && upperExpr != NULL) + return (Node *) makeBoolExpr(AND_EXPR, list_make2(lowerExpr, upperExpr), -1); + else if (lowerExpr != NULL) + return (Node *) lowerExpr; + else if (upperExpr != NULL) + return (Node *) upperExpr; to +

Re: Adding OLD/NEW support to RETURNING

2023-12-16 Thread jian he
On Mon, Dec 4, 2023 at 8:15 PM Dean Rasheed wrote: > > I have been playing around with the idea of adding support for OLD/NEW > to RETURNING, partly motivated by the discussion on the MERGE > RETURNING thread [1], but also because I think it would be a very > useful addition for other commands

Re: Clang optimiser vs preproc.c

2023-12-16 Thread Andres Freund
Hi, On 2023-12-15 22:19:56 -0500, Tom Lane wrote: > Thomas Munro writes: > > On Sat, Dec 16, 2023 at 3:44 PM Tom Lane wrote: > >> Thomas Munro writes: > >>> FYI, it looks like there is a big jump in CPU time to compile preproc.c > >>> at -O2: > >>> clang15: ~16s > >>> clang16: ~211s > >>>

Re: Improve eviction algorithm in ReorderBuffer

2023-12-16 Thread Masahiko Sawada
On Sat, Dec 16, 2023 at 1:36 AM Euler Taveira wrote: > > On Fri, Dec 15, 2023, at 9:11 AM, Masahiko Sawada wrote: > > > I assume you mean to add ReorderBufferTXN entries to the binaryheap > and then build it by comparing their sizes (i.e. txn->size). But > ReorderBufferTXN entries are removed and

[DOC] Introducing Quick Start Guide to PL/pgSQL and PL/Python Documentation

2023-12-16 Thread Ishaan Adarsh
Hi I have made some documentation enhancements for PL/pgSQL and PL/Python sections. The changes include the addition of a Quick Start Guide to facilitate a smoother onboarding experience for users. Patch File Name: 0001-plpyhton-plpgsql-docu-changes.patch Patch Description: This patch

Re: GUC names in messages

2023-12-16 Thread Michael Paquier
On Thu, Dec 14, 2023 at 09:38:40AM +0100, Peter Eisentraut wrote: > After these discussions, I think this rule change was not a good idea. It > effectively enforces these kinds of inconsistencies. For example, if you > ever refactored > > "DateStyle is wrong" > > to > > "%s is wrong" >

Re: Remove MSVC scripts from the tree

2023-12-16 Thread Michael Paquier
On Thu, Dec 14, 2023 at 11:43:14AM +0900, NINGWEI CHEN wrote: > Sorry for the delayed response. > We are currently working on transitioning to meson build at hamerkop and > anticipating that this can be accomplished by no later than January. > > If the old build scripts are removed before that,