Re: Optimizing ResouceOwner to speed up COPY

2025-10-16 Thread Tomas Vondra
On 10/17/25 00:17, Tom Lane wrote: > Tomas Vondra writes: >> On 10/16/25 21:28, Tom Lane wrote: >>> I was thinking of adding some temporary instrumentation, like >>> just elog'ing whenever the count goes above 1, and seeing where >>> you get hits during the regression tests. I'm prepared to belie

Re: postgres_fdw: Use COPY to speed up batch inserts

2025-10-16 Thread Tomas Vondra
Hi Matheus, Thanks for the patch. Please add it to the next committfest (PG19-3) at https://commitfest.postgresql.org/ so that we don't lose track of the patch. On 10/15/25 17:02, Matheus Alcantara wrote: > Hi all, > > Currently on postgres_fdw we use prepared statements to insert batches >

Re: pageinspect some function no need superuser priv

2025-10-16 Thread Michael Paquier
On Tue, Oct 14, 2025 at 10:51:51AM -0500, Nathan Bossart wrote: > On Tue, Oct 14, 2025 at 10:29:39AM -0400, Tom Lane wrote: >> Yeah, I do not think it follows that being table owner should >> entitle you to such low-level access. I'm inclined to reject >> this proposal. > > -1 here, too. IMHO al

Re: RFC: Logging plan of the running query

2025-10-16 Thread Robert Haas
On Wed, Oct 1, 2025 at 5:11 AM torikoshia wrote: > I was also considering using an isolation test and injection points, > like in the attached PoC patch. The main steps are: > >In session1, set an injection point to wait during query execution. >In session1, run a query that waits at the i

Re: Optimize LISTEN/NOTIFY

2025-10-16 Thread Joel Jacobson
On Thu, Oct 16, 2025, at 20:16, Joel Jacobson wrote: > On Thu, Oct 16, 2025, at 04:54, Chao Li wrote: >>> On Oct 15, 2025, at 23:36, Joel Jacobson wrote: >>> The latest version gets rid of GetPendingNotifyChannels() >>> and replaces it with the local list pendingNotifyChannels. >> >> Sorry for the

Re: Making pg_rewind faster

2025-10-16 Thread Robert Haas
On Wed, Oct 15, 2025 at 10:27 AM Srinath Reddy Sadipiralla wrote: >> On Fri, Oct 10, 2025 at 12:45 AM Srinath Reddy Sadipiralla >> wrote: >> > XLogFilePath , then validate this new path with the given path >> > ,this helps to catch invalid xlog files like >> > pg_wal/0001FF10. >>

Re: Question about InvalidatePossiblyObsoleteSlot()

2025-10-16 Thread Masahiko Sawada
On Thu, Oct 16, 2025 at 1:23 AM Bertrand Drouvot wrote: > > Hi, > > On Wed, Oct 15, 2025 at 04:24:03PM -0700, Masahiko Sawada wrote: > > On Tue, Oct 14, 2025 at 9:51 PM Bertrand Drouvot > > wrote: > > > > > > We don't really report an "invalidation", what we report is: > > > > > > LOG: terminati

Re: POC: enable logical decoding when wal_level = 'replica' without a server restart

2025-10-16 Thread Masahiko Sawada
On Thu, Oct 16, 2025 at 1:46 AM Hayato Kuroda (Fujitsu) wrote: > > Dear Sawada-san, > > > It's not harmful in practice. I've considered waking up the postmaster > > with a new PMSignalReason, but I thought it's overkill to introduce a > > new reason just to wake up the postmaster. If there is a co

Re: Speed up COPY FROM text/CSV parsing using SIMD

2025-10-16 Thread Nazir Bilal Yavuz
Hi, On Thu, 21 Aug 2025 at 18:47, Andrew Dunstan wrote: > > > On 2025-08-19 Tu 10:14 AM, Nazir Bilal Yavuz wrote: > > Hi, > > > > On Tue, 19 Aug 2025 at 15:33, Nazir Bilal Yavuz wrote: > >> I am able to reproduce the regression you mentioned but both > >> regressions are %20 on my end. I found t

Re: [PATCH] Add pg_get_policy_ddl() function to reconstruct CREATE POLICY statement

2025-10-16 Thread Akshay Joshi
Please find attached the v3 patch, which resolves all compilation errors and warnings. On Thu, Oct 16, 2025 at 6:06 PM Philip Alger wrote: > Hi Akshay, > > As for the statement terminator, it’s useful to include it, while >>> running multiple queries together could result in a syntax error.

Re: Add RESPECT/IGNORE NULLS and FROM FIRST/LAST options

2025-10-16 Thread Tatsuo Ishii
Thanks for the report. > Coverity thinks that this code has still some incorrect bits, and I > think that it is right to think so even on today's HEAD at > 02c171f63fca. > > In WinGetFuncArgInPartition()@nodeWindowAgg.c, we have the following > loop (keeping only the relevant parts: > do >

Re: [PATCH TEST] Fix logical replication setup in subscription test `t/009_matviews.pl`

2025-10-16 Thread Amit Kapila
On Tue, Oct 14, 2025 at 10:34 AM Michael Paquier wrote: > > On Mon, Oct 13, 2025 at 06:12:07PM +0530, Ashutosh Bapat wrote: > > For now this makes sense. > > The arguments and the patches I am seeing do not really make sense > here. > > > We could avoid running a full test, and save time and resou

Re: Inconsistent Behavior of GROUP BY ROLLUP in v17 vs master

2025-10-16 Thread Richard Guo
On Thu, Sep 25, 2025 at 5:27 PM Richard Guo wrote: > On Thu, Sep 25, 2025 at 12:24 PM Tom Lane wrote: > > 18.1 will not be coming out till November, so I feel no need to > > rush to judgment on what to do here. > Thanks. I'll wait for any feedback on the patch itself before > deciding how to pr

Re: Question about InvalidatePossiblyObsoleteSlot()

2025-10-16 Thread Bertrand Drouvot
Hi, On Wed, Oct 15, 2025 at 04:24:03PM -0700, Masahiko Sawada wrote: > On Tue, Oct 14, 2025 at 9:51 PM Bertrand Drouvot > wrote: > > > > We don't really report an "invalidation", what we report is: > > > > LOG: terminating process 3998707 to release replication slot "logical_slot" > > DETAIL: T

Re: [PATCH] Add pg_get_policy_ddl() function to reconstruct CREATE POLICY statement

2025-10-16 Thread Akshay Joshi
On Wed, Oct 15, 2025 at 10:55 PM Álvaro Herrera wrote: > Hello, > > I have reviewed this patch before and provided a number of comments that > have been addressed by Akshay (so I encourage you to list my name and > this address in a Reviewed-by trailer line in the commit message). One > thing I

Re: Improved TAP tests by replacing sub-optimal uses of ok() with better Test::More functions

2025-10-16 Thread Michael Paquier
On Wed, Oct 15, 2025 at 06:06:47PM +0530, Sadhuprasad Patro wrote: > Yes.. I hv used the same you mentioned Andrew... I have been reading the patch. -ok( $stderr =~ /index uniqueness is violated for index "bttest_unique_idx1"/, +like($stderr, + qr/index uniqueness is violated for index "btt