Re: [PATCH] test_aio: Skip io_uring tests when kernel disables it

2025-12-09 Thread Nazir Bilal Yavuz
Hi, On Mon, 8 Dec 2025 at 05:12, Henson Choi wrote: > > Hi hackers, > > I encountered test_aio failures on RHEL 9 / Rocky Linux 9 systems where > io_uring is disabled by default (io_uring_disabled=2). This is increasingly > common in enterprise environments. > > Background: > Red Hat disabled io_

Re: Mark function arguments of type "T *" as "const T *" where possible

2025-12-09 Thread Bertrand Drouvot
Hi, On Tue, Dec 09, 2025 at 04:20:57PM +, Bertrand Drouvot wrote: > To avoid any risks: > > - cases that produce -Wdiscarded-qualifiers warnings have been discarded as > they would need more investigation. > > - double pointers are excluded to keep the changes straightforward. > > - cases t

Re: [PATCH] Add hint for misspelled relations

2025-12-09 Thread Steve Chavez
Hi Kirill and Daniel, many thanks for your feedback. > Why do we even do this? Can't we just pass fuzzystate->distance to varstr_levenshtein_less_equal? It is initialized in outer func to MAX_FUZZY_DISTANCE + 1 This was an oversight. I've corrected it on the new attached patch. > Worst case is

Re: [oauth] SASL mechanisms

2025-12-09 Thread Nico Williams
On Tue, Dec 09, 2025 at 01:18:43PM -0800, Jacob Champion wrote: > On Tue, Nov 25, 2025 at 9:40 AM Nico Williams wrote: > > (And... I don't have time to contribute this, plus I've tried to > > contribute to PG before and got my patches into two commitfests, but the > > amount of energy needed to co

Re: Missing empty transaction optimization in pgoutput plugin

2025-12-09 Thread Ashutosh Bapat
On Wed, Dec 10, 2025 at 9:17 AM Zhijie Hou (Fujitsu) wrote: > > On Monday, December 8, 2025 2:49 PM Ashutosh Bapat > wrote: > > > > Hi All, > > test_decoding output plugin skips sending stream_start and stream_end if no > > change from a segment of a streamed transaction is sent downstream. If n

Re: Skipping schema changes in publication

2025-12-09 Thread shveta malik
On Tue, Dec 9, 2025 at 11:17 PM Shlok Kyal wrote: > > > > I have removed the 0001 0002 and 0004 patches for now. Will post them > once 0003 patch is RFC. > Here is the update patch for "EXCEPT TABLE". > Thanks, I have not looked at new patch yet, but here are few comments for v29-003: 1) create_

Re: Improve pg_sync_replication_slots() to wait for primary to advance

2025-12-09 Thread Yilin Zhang
At 2025-12-10 13:07:34, "Ajin Cherian" wrote: > >I'm not sure if this is much of an improvement, I like the current >approach and matches with similar coding patterns in the code base. > >Attaching v34 addressing the above comments. > Hi, Few comments for v34. 1 - 0002 ``` --- a/src/backend/

Re: Add a greedy join search algorithm to handle large join problems

2025-12-09 Thread Chengpeng Yan
Hi, > On Dec 10, 2025, at 07:30, Tomas Vondra wrote: > > I looked at a couple more failing queries, and removing the aggregates > fixes them too. Maybe there are other issues/crashes, of course. Thanks a lot for pointing this out. I also noticed the same issue when testing TPC-H Q5. The root cau

greenfly lwlock corruption in REL_14_STABLE and REL_15_STABLE

2025-12-09 Thread Thomas Munro
Beginning a week ago, greenfly (RISC-V, Clang 20.1) has failed like this in 5 of 8 runs of the pgbench tests on the two oldest branches: TRAP: FailedAssertion("!(oldstate & LW_VAL_EXCLUSIVE)", File: "lwlock.c", Line: 1850, PID: 1536294) postgres: main: gburd postgres [local] CREATE TYPE(Exceptiona

Re: Improve pg_sync_replication_slots() to wait for primary to advance

2025-12-09 Thread Ajin Cherian
On Wed, Dec 10, 2025 at 3:05 PM shveta malik wrote: > > On Wed, Dec 10, 2025 at 8:10 AM Ajin Cherian wrote: > > > > On Wed, Dec 10, 2025 at 1:29 PM Chao Li wrote: > > > > > > Hi Ajin, > > > > > > I’d like to revisit this patch, but looks like > > > 04396eacd3faeaa4fa3d084a6749e4e384bdf0db has s

Re: [BUG] Incorrect historic snapshot may be serialized to disk during fast-forwarding

2025-12-09 Thread cca5507
Hi, I add some commit message to the patch and create a CF entry: https://commitfest.postgresql.org/patch/6304/ -- Regards, ChangAo Chen v4-0001-Handle-XLOG_HEAP2_NEW_CID-in-heap2_decode-even-if.patch Description: Binary data

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

2025-12-09 Thread Amit Kapila
On Wed, Dec 10, 2025 at 4:39 AM Masahiko Sawada wrote: > > On Mon, Dec 8, 2025 at 8:27 PM Amit Kapila wrote: > > > > On Tue, Dec 9, 2025 at 12:22 AM Masahiko Sawada > > wrote: > > > > > > On Mon, Dec 8, 2025 at 3:30 AM Amit Kapila > > > wrote: > > > > > > > > On Mon, Dec 8, 2025 at 1:06 PM Ma

Re: Improve pg_sync_replication_slots() to wait for primary to advance

2025-12-09 Thread Chao Li
> On Dec 10, 2025, at 10:40, Ajin Cherian wrote: > > On Wed, Dec 10, 2025 at 1:29 PM Chao Li wrote: >> >> Hi Ajin, >> >> I’d like to revisit this patch, but looks like >> 04396eacd3faeaa4fa3d084a6749e4e384bdf0db has some conflicts to this patch. >> So can you please rebase this patch? >>

Re: Improve pg_sync_replication_slots() to wait for primary to advance

2025-12-09 Thread shveta malik
On Wed, Dec 10, 2025 at 8:10 AM Ajin Cherian wrote: > > On Wed, Dec 10, 2025 at 1:29 PM Chao Li wrote: > > > > Hi Ajin, > > > > I’d like to revisit this patch, but looks like > > 04396eacd3faeaa4fa3d084a6749e4e384bdf0db has some conflicts to this patch. > > So can you please rebase this patch?

RE: Missing empty transaction optimization in pgoutput plugin

2025-12-09 Thread Zhijie Hou (Fujitsu)
On Monday, December 8, 2025 2:49 PM Ashutosh Bapat wrote: > > Hi All, > test_decoding output plugin skips sending stream_start and stream_end if no > change from a segment of a streamed transaction is sent downstream. If no > change has been sent downstream across all the streamed segments it >

Re: [PATCH] Add memory usage reporting to VACUUM VERBOSE

2025-12-09 Thread Tatsuya Kawata
Hi all, Just a gentle ping on this patch. Please let me know if there are any additional comments or points I should address in the next revision. Regards, Tatsuya Kawata

Re?? log_min_messages per backend type

2025-12-09 Thread Tan Yang
Hi, I applied this patch, and I have a few thoughts. === Issue 1: Unhelpful error messages for typos === When users make typos in process types or log levels, the current error messages don't provide helpful hints. For example: ```     testdb=# SET log_min_messages TO 'autovacum:debug1, war

RE: Assertion failure in SnapBuildInitialSnapshot()

2025-12-09 Thread Zhijie Hou (Fujitsu)
On Wednesday, December 10, 2025 7:25 AM Masahiko Sawada wrote: > > On Tue, Nov 25, 2025 at 10:25 PM Zhijie Hou (Fujitsu) > wrote: > > > > On Wednesday, November 26, 2025 2:57 AM Masahiko Sawada > wrote: > > > > > > On Tue, Nov 25, 2025 at 4:02 AM Zhijie Hou (Fujitsu) > > > > wrote: > > > > >

Re: Improve pg_sync_replication_slots() to wait for primary to advance

2025-12-09 Thread Ajin Cherian
On Wed, Dec 10, 2025 at 1:29 PM Chao Li wrote: > > Hi Ajin, > > I’d like to revisit this patch, but looks like > 04396eacd3faeaa4fa3d084a6749e4e384bdf0db has some conflicts to this patch. So > can you please rebase this patch? > > Best regards, > -- It's been rebased. Have a look at the latest

Re: Improve pg_sync_replication_slots() to wait for primary to advance

2025-12-09 Thread Chao Li
> On Dec 9, 2025, at 18:33, Ajin Cherian wrote: > > Hi all, > > Since commit 04396ea [1] has been pushed, which included part of the > changes this patch set was addressing, I have updated and rebased the > patch set to incorporate those changes. > > The patch set now contains two patches: >

Re: Improve pg_sync_replication_slots() to wait for primary to advance

2025-12-09 Thread Ajin Cherian
On Tue, Dec 9, 2025 at 10:45 PM shveta malik wrote: > > On Tue, Dec 9, 2025 at 4:04 PM Ajin Cherian wrote: > > > > Hi all, > > > > Since commit 04396ea [1] has been pushed, which included part of the > > changes this patch set was addressing, I have updated and rebased the > > patch set to incorp

Re: Issue with query_is_distinct_for() and grouping sets

2025-12-09 Thread Richard Guo
On Thu, Oct 23, 2025 at 4:07 PM Richard Guo wrote: > Fair point. Patch updated with a revised commit message. ... and then pushed. - Richard

Re: log_min_messages per backend type

2025-12-09 Thread Chao Li
> On Dec 10, 2025, at 02:24, Alvaro Herrera wrote: > > On 2025-Dec-09, Alvaro Herrera wrote: > >> So here's your v6 again with those fixes as 0003 -- let's see what CI >> thinks of this. I haven't looked at your doc changes yet. > > This passed CI, so I have marked it as Ready for Committer

Re: Fix a minor typo in the comment of read_stream_start_pending

2025-12-09 Thread Xuneng Zhou
Hi, On Wed, Dec 10, 2025 at 7:07 AM Heikki Linnakangas wrote: > > On 11/11/2025 02:43, Chao Li wrote: > >> On Nov 10, 2025, at 22:56, Xuneng Zhou wrote: > >> /* > >> * Sequential: Issue advice until the preadv() calls have caught > >> * up with the first advice issued for this sequential region,

PSA: Planning to grease protocol connections during 19beta

2025-12-09 Thread Jacob Champion
I want to make sure this doesn't take anyone by surprise: I'm planning to get Jelte's "grease" patch into shape for a commit some time in January. https://commitfest.postgresql.org/patch/6157/ If you're unfamiliar with the concept of greasing [1], one way to think of it is that we're invertin

Re: Add mode column to pg_stat_progress_vacuum

2025-12-09 Thread Shinya Kato
On Wed, Dec 10, 2025 at 8:12 AM Masahiko Sawada wrote: > I've pushed both patches after incorporating the above two points. Thank you, Sawada-san, for your thorough review, and thanks to all reviewers. -- Best regards, Shinya Kato NTT OSS Center

[PATCH] Fix severe performance regression with gettext 0.20+ on Windows

2025-12-09 Thread Bryan Green
Hello hackers, I've been investigating a performance issue on Windows with recent gettext versions (0.20.1 and later) that causes exception-heavy workloads to run significantly slower than with gettext 0.19.8. Starting with gettext 0.20.1, the library changed its Windows locale handling in a way

Re: Solaris versus our NLS files

2025-12-09 Thread Tom Lane
Thomas Munro writes: > On Wed, Dec 10, 2025 at 11:22 AM Nico Williams wrote: >> How about supporting only UTF-8 locales? > Yeah, if nobody noticed this wasn't working at all, then it makes > sense to defer the generation of .mo files for non-UTF-8 codesets > until someone eventually does notice

Small bugs regarding resowner handling in aio.c, catcache.c

2025-12-09 Thread Matthias van de Meent
Hi Heikki, Andres, Whilst looking through catcache.c's code I noticed this piece of code: ReleaseCatCacheListWithOwner(CatCList *list, ResourceOwner resowner) { [...] if (resowner) ResourceOwnerForgetCatCacheRef(CurrentResourceOwner, &ct->tuple); Note how the resowner argument is

Re: Add support for specifying tables in pg_createsubscriber.

2025-12-09 Thread Euler Taveira
On Sun, Dec 7, 2025, at 11:52 PM, Peter Smith wrote: > > OK. Done as suggested in v23. > I took another look at this patch. I noticed that it increased the test time in 3 or 4s. I started writing the suggestions to this email but since it increases a lot, it is better to provide a patch and explai

Re: Add a greedy join search algorithm to handle large join problems

2025-12-09 Thread Tomas Vondra
On 12/9/25 20:20, Tomas Vondra wrote: > On 12/2/25 14:04, Chengpeng Yan wrote: >> Hi, >> >> >> >>> On Dec 2, 2025, at 18:56, Tomas Vondra wrote: >>> >>> I think a much broader evaluation will be needed, comparing not just the >>> planning time, but also the quality of the final plan. Which for

updates for handling optional argument in system functions

2025-12-09 Thread Mark Wong
Hi everyone, I noticed how it was preferred to define optional arguments with the system functions in system_functions.sql instead of defining them in pg_proc.dat. I took a gross stab at updating the ones that ended in _ext, which turned out to be 7 declarations across 6 system functions, and cre

Re: Assertion failure in SnapBuildInitialSnapshot()

2025-12-09 Thread Masahiko Sawada
On Tue, Nov 25, 2025 at 10:25 PM Zhijie Hou (Fujitsu) wrote: > > On Wednesday, November 26, 2025 2:57 AM Masahiko Sawada > wrote: > > > > On Tue, Nov 25, 2025 at 4:02 AM Zhijie Hou (Fujitsu) > > > > wrote: > > > > > > On Tuesday, November 25, 2025 3:30 AM Masahiko Sawada > > wrote: > > > > >

Re: Add SPLIT PARTITION/MERGE PARTITIONS commands

2025-12-09 Thread Dmitry Koval
Hi, Alexander! Thank you for your corrections! Two questions: 1) "v65-0001-Implement-ALTER-TABLE-.-MERGE-PARTITIONS-.-comma.patch" patch, "src/backend/partitioning/partbounds.c" file, "check_two_partitions_bounds_range" function. Old comment (v64) + /* +* lower1=false (th

Re: [Proposal] Adding callback support for custom statistics kinds

2025-12-09 Thread Sami Imseih
> > > IIUC, if *any* error occurs outside of a deserialize callback, first the > "error" > > code will be called, followed by "done" which will then trigger the > > end_extra_stats > > callback that will perform the cleanup. > > That is true. But problem is, without an error indication, > end_extra

Re: Add mode column to pg_stat_progress_vacuum

2025-12-09 Thread Masahiko Sawada
On Tue, Dec 9, 2025 at 12:22 AM Yu Wang wrote: > > On 12/9/25 5:25 AM, Masahiko Sawada wrote: > > On Thu, Dec 4, 2025 at 8:30 PM Shinya Kato wrote: > >> Thank you for the review! > >> > >> On Thu, Dec 4, 2025 at 9:15 AM Masahiko Sawada > >> wrote: > >>> I've attached a small change to simplify

Re: Qual push down to table AM

2025-12-09 Thread Andres Freund
Hi, On 2025-12-09 16:40:17 -0500, Robert Haas wrote: > On Fri, Aug 29, 2025 at 4:38 AM Julien Tachoires wrote: > Potentially, there could be a performance problem I think the big performance hazard with this is repeated deforming. The scankey infrastructure deforms attributes one-by-one *and* it

Re: Fix a minor typo in the comment of read_stream_start_pending

2025-12-09 Thread Heikki Linnakangas
On 11/11/2025 02:43, Chao Li wrote: On Nov 10, 2025, at 22:56, Xuneng Zhou wrote: /* * Sequential: Issue advice until the preadv() calls have caught * up with the first advice issued for this sequential region, and * then stay of the way of the kernel's own read-ahead. */ “out” is missing from

Re: [Proposal] Adding callback support for custom statistics kinds

2025-12-09 Thread Chao Li
> On Dec 10, 2025, at 05:54, Sami Imseih wrote: > > IIUC, if *any* error occurs outside of a deserialize callback, first the > "error" > code will be called, followed by "done" which will then trigger the > end_extra_stats > callback that will perform the cleanup. That is true. But problem i

Re: Fix incorrect comments in tuplesort.c

2025-12-09 Thread David Rowley
On Mon, 8 Dec 2025 at 15:08, cca5507 wrote: > > Using "However" here indicates some exception to what's just been > > said, but there is no longer an exception. To write about what the > > 1024 is for, we might need to reverse engineer what that's for. I > > assume it's something like "Clamp at 10

Re: Consistently use palloc_object() and palloc_array()

2025-12-09 Thread Michael Paquier
On Wed, Dec 10, 2025 at 11:41:25AM +1300, Thomas Munro wrote: > On Wed, Dec 10, 2025 at 11:38 AM Michael Paquier wrote: >> b_checkargnulls = >> - palloc(sizeof(LLVMBasicBlockRef *) * op->d.func.nargs); >> + palloc_array(LLVMBasicBlockRef *, op->d.func.nargs)

Re: Solaris versus our NLS files

2025-12-09 Thread Thomas Munro
On Wed, Dec 10, 2025 at 11:22 AM Nico Williams wrote: > On Wed, Dec 10, 2025 at 11:03:00AM +1300, Thomas Munro wrote: > > On Wed, Dec 10, 2025 at 10:54 AM Thomas Munro > > wrote: > > > if you create codesetless symlinks > > > > Oops, wrote that too fast... you want to add the suffixes. Well the

Re: Consistently use palloc_object() and palloc_array()

2025-12-09 Thread Thomas Munro
On Wed, Dec 10, 2025 at 11:38 AM Michael Paquier wrote: > b_checkargnulls = > - palloc(sizeof(LLVMBasicBlockRef *) * op->d.func.nargs); > + palloc_array(LLVMBasicBlockRef *, op->d.func.nargs); > > This one in llvmjit_expr.c was causing a compilation failure.

Re: Solaris versus our NLS files

2025-12-09 Thread Thomas Munro
On Wed, Dec 10, 2025 at 11:23 AM Tom Lane wrote: > If you're right about Sun not doing transcoding, then I guess we would > only need to create symlinks matching the encodings used in our .po > files, which'd remove the symlink bloat problem and replace it with > how-do-we-extract-that-encoding-na

Re: Trying out read streams in pgvector (an extension)

2025-12-09 Thread Peter Geoghegan
On Mon, Dec 8, 2025 at 10:47 PM Thomas Munro wrote: > Yielding just because you've scanned N index pages/tuples/whatever is > harder to think about. The stream shouldn't get far ahead unless it's > recently been useful for I/O concurrency (though optimal distance > heuristics are an open problem)

Re: Consistently use palloc_object() and palloc_array()

2025-12-09 Thread Michael Paquier
On Fri, Dec 05, 2025 at 04:41:41PM +0900, Michael Paquier wrote: > Thanks. That's a lot to digest. Digesting a bit more now.. - char *ret = palloc(sizeof(buf)); + char *ret = palloc_array(char, sizeof(buf)) This one in dumputils.c is right, but I am not sure that it is an improv

Re: Solaris versus our NLS files

2025-12-09 Thread Tom Lane
Thomas Munro writes: > On Wed, Dec 10, 2025 at 10:22 AM Tom Lane wrote: >> After some quality time with Google, I learned why: with Solaris's >> apparently-locally-hacked version of gettext, it's not good enough >> to have $INSTALLATION/share/locale/ subdirectories named like >> "es", "fr", etc.

Re: Solaris versus our NLS files

2025-12-09 Thread Nico Williams
On Wed, Dec 10, 2025 at 11:03:00AM +1300, Thomas Munro wrote: > On Wed, Dec 10, 2025 at 10:54 AM Thomas Munro wrote: > > if you create codesetless symlinks > > Oops, wrote that too fast... you want to add the suffixes. Well then > it's the other way around, and you'd have to generate new files w

[Proposal] Adding Log File Capability to pg_createsubscriber

2025-12-09 Thread Gyan Sreejith
Background: - pg_createsubscriber currently outputs all messages (internal validation messages, standby server start/stop logs, recovery progress output, and output from utilities) directly to the console. As a result, users may find debugging and handling errors difficult. It woul

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

2025-12-09 Thread Manni Wood
On Tue, Dec 9, 2025 at 7:40 AM Bilal Yavuz wrote: > Hi, > > On Sat, 6 Dec 2025 at 10:55, Bilal Yavuz wrote: > > > > Hi, > > > > On Sat, 6 Dec 2025 at 04:40, Manni Wood > wrote: > > > Hello, all. > > > > > > Andrew, I tried your suggestion of just reading the first chunk of the > copy file to de

Re: [PATCH] O_CLOEXEC not honored on Windows - handle inheritance chain

2025-12-09 Thread Bryan Green
On 12/9/2025 3:03 PM, Thomas Munro wrote: > On Sun, Nov 30, 2025 at 1:13 PM Thomas Munro wrote: >> What do you think about these improvements? See attached. >> >> * moved and adjusted new comment about flag conversion to cover all >> three flags, since it's true for all of them >> * adjusted the

Re: Solaris versus our NLS files

2025-12-09 Thread Thomas Munro
On Wed, Dec 10, 2025 at 10:54 AM Thomas Munro wrote: > if you create codesetless symlinks Oops, wrote that too fast... you want to add the suffixes. Well then it's the other way around, and you'd have to generate new files with the right encoding and suffixes (which means knowing which combinati

Re: AIX support

2025-12-09 Thread Tristan Partin
Howdy, Heikki asked me to look at the renames of the static Meson targets. I don't understand the reasoning for the changes. I am completely unfamiliar with AIX, so maybe it's obvious. Does Meson produce a static library and a shared library with the same file extension? If so, why is that? Th

Re: [Proposal] Adding callback support for custom statistics kinds

2025-12-09 Thread Sami Imseih
> My point is that, there are many places jumping to “error”, then from “error” > goto “done”, > if an error didn’t happen from the deserialize callback, how end_extra_stats() > can know if failure happened and takes action accordingly? IIUC, if *any* error occurs outside of a deserialize callbac

Re: Solaris versus our NLS files

2025-12-09 Thread Thomas Munro
On Wed, Dec 10, 2025 at 10:22 AM Tom Lane wrote: > After some quality time with Google, I learned why: with Solaris's > apparently-locally-hacked version of gettext, it's not good enough > to have $INSTALLATION/share/locale/ subdirectories named like > "es", "fr", etc. They have to be named after

Re: Trying out read streams in pgvector (an extension)

2025-12-09 Thread Melanie Plageman
On Mon, Dec 8, 2025 at 10:47 PM Thomas Munro wrote: > > I think it'd be better if that were the consumer's choice. I don't > want the consumer to be required to drain the stream before resuming, > as that'd be an unprincipled stall. For example, if new WAL arrives > over the network then I thin

Re: Qual push down to table AM

2025-12-09 Thread Robert Haas
On Fri, Aug 29, 2025 at 4:38 AM Julien Tachoires wrote: > Thank you for this quick feedback. > > One potential approach to solve this in heapgettup() would be: > 1. hold the buffer lock > 2. get the tuple from the buffer > 3. if the tuple is not visible, move to the next tuple, back to 2. > 4. rel

Re: [PATCH] VACUUM: avoid pre-creation transactions holding back cleanup of newly created relations

2025-12-09 Thread Andres Freund
Hi, On 2025-12-09 14:31:09 -0500, Melanie Plageman wrote: > On Tue, Dec 9, 2025 at 2:25 PM Andres Freund wrote: > > > > Isn't the whole idea that it would be safe to allow freezing in this case > > incorrect? Consider the following scenario: > > > > A1: BEGIN TRANSACTION ISOLATION LEVEL REPEATAB

Solaris versus our NLS files

2025-12-09 Thread Tom Lane
I idly tried the NLS-testing patch at [1] on a Solaris image (actually OpenIndiana), and was not really astonished to find that it fails. Everything compiles cleanly, but the test shows that no message translation happens, and manual checking confirms that. After some quality time with Google, I

Re: [oauth] SASL mechanisms

2025-12-09 Thread Jacob Champion
On Tue, Nov 25, 2025 at 9:40 AM Nico Williams wrote: > > I could see us eventually pulling out the user's claims (whether from > > Kerberos or OAuth, or maybe generically mapped from an identity) into > > a central API. That way validators wouldn't have to reinvent the wheel > > each time. > > But

Re: AIX support

2025-12-09 Thread Peter Eisentraut
On 09.12.25 17:50, Srirama Kucherlapati wrote: Hi Team, (Peter/Heikki) I have implemented the requested modifications in the latest patch. Below are the key technical updates: • Meson Build Configuration: Adjusted below meson.build scripts to incorporate the suggested changes, ensuring prope

Re: explain plans for foreign servers

2025-12-09 Thread Sami Imseih
Hi, I spent more time reviewing this patch. Here are additional comments. 1/ Remove unnecessary includes #include "commands/explain_state.h" from option.c. #include "utils/json.h" from postgres_fdw.c. 2/ Add new EXPLAIN options MEMORY and SUMMARY flags added to the remote EXPLAIN query formatt

Re: [PATCH] O_CLOEXEC not honored on Windows - handle inheritance chain

2025-12-09 Thread Thomas Munro
On Sun, Nov 30, 2025 at 1:13 PM Thomas Munro wrote: > What do you think about these improvements? See attached. > > * moved and adjusted new comment about flag conversion to cover all > three flags, since it's true for all of them > * adjusted the comment about why we don't use SetHandleInformati

Re: AIX support

2025-12-09 Thread Heikki Linnakangas
On 09/12/2025 18:50, Srirama Kucherlapati wrote: @@ -1766,9 +1785,9 @@ endforeach # any types wider than 64 bits, as allowing MAXIMUM_ALIGNOF to exceed 8 # would be too much of a penalty for disk and memory space. alignof_double = cdata.get('ALIGNOF_DOUBLE') -if cc.alignment('int64_t', args: t

Re: PoC: Compute a histogram of prune_xid to support autovacuum improvements

2025-12-09 Thread Melanie Plageman
On Tue, Jun 3, 2025 at 12:40 PM Renan Alves Fonseca wrote: > > in the scope of improving the autovacuum algorithm, this patch proposes > to maintain a histogram of *smallest prunable xid per page* for each > relation. It allows to estimate the number of pages that would > be pruned by vacuum for a

Re: making tid and HOTness of UPDATE available to logical decoding plugins

2025-12-09 Thread Hannu Krosing
On Tue, Dec 9, 2025 at 7:41 PM Matthias van de Meent wrote: > > On Mon, 8 Dec 2025 at 16:25, Hannu Krosing wrote: > > > ... > > Suggestion to "get the user specify their own identity column" sounds > > good in purely theoretical sense, but can have unacceptable overheads > > in practice, especial

Re: pg_plan_advice

2025-12-09 Thread Robert Haas
On Mon, Dec 8, 2025 at 8:19 PM Jacob Champion wrote: > I really like this idea! Telling the planner, "if you need to make a > decision for [this thing], choose [this way]," seems to be a really > nice way of sidestepping many of the concerns with "user control". > > I've started an attempt to thro

Re: Issues with ON CONFLICT UPDATE and REINDEX CONCURRENTLY

2025-12-09 Thread Mihail Nikalayeu
Hello! After some investigation I ended up with a much simpler fix. It is self-explanatory in code and a commit message. Best regards, Mikhail. From de4fcbcbd35912cea70f0f00f81878ea8b94416c Mon Sep 17 00:00:00 2001 From: Mikhail Nikalayeu Date: Tue, 9 Dec 2025 19:39:06 +0100 Subject: [PATCH v1]

Re: vacuumdb: add --dry-run

2025-12-09 Thread Nathan Bossart
On Tue, Dec 09, 2025 at 07:04:24AM +0800, Chao Li wrote: > I searched over the source tree, and find “Running in xxx mode” in initdb > and option.c: > > [...] > > And “”Executing in dry-run mode” in a few commands: pg_archivecleanup.c, > pg_createsubscriber.c, pg_combinebackup.c and pg_rewind.c.

Re: vacuumdb: add --dry-run

2025-12-09 Thread Nathan Bossart
Committed. -- nathan

Re: pg_plan_advice

2025-12-09 Thread Robert Haas
On Mon, Dec 8, 2025 at 3:39 PM Greg Burd wrote: > Thanks for working on this! I think the idea has merit, I hope it lands > sometime soon. Thanks. I think it needs a good deal more review first, but I appreciate the support. > > Attachments: > > * v5-0001-Store-information-about-range-table-fl

Re: [PATCH] VACUUM: avoid pre-creation transactions holding back cleanup of newly created relations

2025-12-09 Thread Melanie Plageman
On Tue, Dec 9, 2025 at 2:25 PM Andres Freund wrote: > > Isn't the whole idea that it would be safe to allow freezing in this case > incorrect? Consider the following scenario: > > A1: BEGIN TRANSACTION ISOLATION LEVEL REPEATABLE READ; SELECT; > B1: CREATE TABLE foo AS SELECT random(); > B2: VACUU

Re: [PATCH] VACUUM: avoid pre-creation transactions holding back cleanup of newly created relations

2025-12-09 Thread Andres Freund
Hi, On 2025-12-09 14:10:24 -0500, Melanie Plageman wrote: > I'll start by admitting that I am not sure exactly how to do this > feature correctly. Isn't the whole idea that it would be safe to allow freezing in this case incorrect? Consider the following scenario: A1: BEGIN TRANSACTION ISOLATIO

Re: Adding REPACK [concurrently]

2025-12-09 Thread Alvaro Herrera
Hello, many thanks for the new version. Here's a very quick proposal for a new top-of-file comment on cluster.c, * cluster.c * Implementation of REPACK [CONCURRENTLY], also known as CLUSTER and * VACUUM FULL. * * There are two somewhat different ways to rewrite a t

Re: Add a greedy join search algorithm to handle large join problems

2025-12-09 Thread Tomas Vondra
On 12/2/25 14:04, Chengpeng Yan wrote: > Hi, > > > >> On Dec 2, 2025, at 18:56, Tomas Vondra wrote: >> >> I think a much broader evaluation will be needed, comparing not just the >> planning time, but also the quality of the final plan. Which for the >> starjoin tests does not really matter, as

Re: [PATCH] VACUUM: avoid pre-creation transactions holding back cleanup of newly created relations

2025-12-09 Thread Melanie Plageman
Hi Mikhail, Thanks for sending a patch! I'll start by admitting that I am not sure exactly how to do this feature correctly. But there are some things about your patch that I think will definitely not work. I also have some suggestions for how you can split up the project. There are two distinct

Re: amcheck: support for GiST

2025-12-09 Thread Miłosz Bieniek
The following review has been posted through the commitfest application: make installcheck-world: not tested Implements feature: not tested Spec compliant: not tested Documentation:not tested Hi, Together with Sergey we did a review and found a few things that need fix

Re: making tid and HOTness of UPDATE available to logical decoding plugins

2025-12-09 Thread Matthias van de Meent
On Mon, 8 Dec 2025 at 16:25, Hannu Krosing wrote: > > On Mon, Dec 8, 2025 at 2:46 PM Matthias van de Meent > wrote: > > I don't see logical decoding as a viable alternative to any > > indexing-related workload. Creating and maintaining indexes need > > strict limits on their resource usage, and l

Re: log_min_messages per backend type

2025-12-09 Thread Alvaro Herrera
On 2025-Dec-09, Alvaro Herrera wrote: > So here's your v6 again with those fixes as 0003 -- let's see what CI > thinks of this. I haven't looked at your doc changes yet. This passed CI, so I have marked it as Ready for Committer. Further comments are still welcome, of course, but if there are n

Re: Let's add a test for NLS translation of PRI* macros

2025-12-09 Thread Tom Lane
I wrote: > Hence, new version attached that just hard-codes es_ES.UTF-8. > We'll see if cfbot agrees with my local testing. Yay, that passed CI. However, I fear this proves little about what would happen on Windows with NLS enabled, because per the other thread we don't have NLS enabled in the CI

Re: Skipping schema changes in publication

2025-12-09 Thread Shlok Kyal
On Fri, 21 Nov 2025 at 12:26, Peter Smith wrote: > > Hi Shlok. > > Here are some review comments for your patch v28-0003 (EXCEPT TABLE ...). > > The review of this patch is a WIP. In this post I only looked at the test > code. > > == > .../t/037_rep_changes_except_table.pl > > 1. > + > +# Cop

Re: pg_dump:qemu: uncaught target signal 7 (Bus error) - core dumped

2025-12-09 Thread Tom Lane
Srinath Reddy Sadipiralla writes: > I have a question about the initdb success > message to start the server using pg_ctl. Can we update the -l logfile > suggestion it prints at the end to something like -l > /path/to/datadirectory/logfile instead? "-l logfile" should be read as a recommendation

Re: Skipping schema changes in publication

2025-12-09 Thread Shlok Kyal
On Mon, 24 Nov 2025 at 13:03, Peter Smith wrote: > > On Fri, Nov 21, 2025 at 5:55 PM Peter Smith wrote: > > > > Hi Shlok. > > > > Here are some review comments for your patch v28-0003 (EXCEPT TABLE ...). > > > > The review of this patch is a WIP. In this post I only looked at the test > > code.

Re: Skipping schema changes in publication

2025-12-09 Thread Shlok Kyal
On Mon, 8 Dec 2025 at 17:44, Amit Kapila wrote: > > On Mon, Dec 8, 2025 at 5:27 PM shveta malik wrote: > > > > On Thu, Dec 4, 2025 at 5:21 PM Shlok Kyal wrote: > > > > > > I have addressed these in the v29 patch. > > > Will address comments for 0003 and 0004 patch by Peter and comments by > > >

Re: Let's add a test for NLS translation of PRI* macros

2025-12-09 Thread Tom Lane
I wrote: > v4-0001 attached tries to deal with #1 by extracting a codeset > name from pg_database.datctype. That seems to work for me locally, > but I'll be interested to see what cfbot thinks. cfbot didn't like that :-(. Upon further review, it seems that the locale name needs to include a valid

Re: [PATCH] Fix inconsistent title attribute tags in documentation

2025-12-09 Thread Nathan Bossart
Committed, thanks for the patch! -- nathan

RE: AIX support

2025-12-09 Thread Srirama Kucherlapati
Hi Team, (Peter/Heikki) I have implemented the requested modifications in the latest patch. Below are the key technical updates: • Meson Build Configuration: Adjusted below meson.build scripts to incorporate the suggested changes, ensuring proper dependency resolution and improved build consis

Re: log_min_messages per backend type

2025-12-09 Thread Alvaro Herrera
BTW another thing I realized while looking this over, is that we quite uselessly transform the integer backend type to a string, pass it as a string using the --forkchild= argument to the child process, then parse the string back to an int to use as an array index. It would be much easier to just

Re: [Patch] Add WHERE clause support to REFRESH MATERIALIZED VIEW

2025-12-09 Thread Adam Brusselback
> Our situation was a wonderful MV with all the columns we needed (some > hard to calculate) to augment search data done millions of times/day. It > was a thing of beauty. Until we realized we needed to update 1 record > (vendor inventory UPDATE date/time) every time we processed a file > (some

Re: pg_dump:qemu: uncaught target signal 7 (Bus error) - core dumped

2025-12-09 Thread Srinath Reddy Sadipiralla
Hi, This isn’t directly tied to the current thread, but it relates to the discussion about binaries and privileges.I have a question about the initdb success message to start the server using pg_ctl. Can we update the -l logfile suggestion it prints at the end to something like -l /path/to/datadir

Re: Mark function arguments of type "Datum *" as "const Datum *" where possible

2025-12-09 Thread Bertrand Drouvot
Hi, On Fri, Oct 31, 2025 at 10:56:35AM +0100, Peter Eisentraut wrote: > On 28.09.25 05:02, Chao Li wrote: > > > > On Fri, Sep 26, 2025 at 11:00 PM Tom Lane > > wrote: > > > > Yeah.  In particular, probably 99% of such Datum arrays also have an > > associated a

Re: Avoid use scoped block variable

2025-12-09 Thread Ranier Vilela
Em ter., 9 de dez. de 2025 às 13:19, Andres Freund escreveu: > Hi, > > On 2025-12-09 13:06:35 -0300, Ranier Vilela wrote: > > I noticed a possible violation of C rules. > > Some functions rely on local block variables, > > but this are a mistake. > > Once that block exits, the memory of the varia

Re: Avoid use scoped block variable

2025-12-09 Thread Tomas Vondra
On 12/9/25 17:06, Ranier Vilela wrote: > Hi. > > I noticed a possible violation of C rules. > Some functions rely on local block variables,  > but this are a mistake. > Once that block exits, the memory of the variable is released. > > Fix by moving the declaration variables. > When you say "po

Re: Avoid use scoped block variable

2025-12-09 Thread Andres Freund
Hi, On 2025-12-09 13:06:35 -0300, Ranier Vilela wrote: > I noticed a possible violation of C rules. > Some functions rely on local block variables, > but this are a mistake. > Once that block exits, the memory of the variable is released. CStringGetTextDatum() copies its input to a fresh allocati

Avoid use scoped block variable

2025-12-09 Thread Ranier Vilela
Hi. I noticed a possible violation of C rules. Some functions rely on local block variables, but this are a mistake. Once that block exits, the memory of the variable is released. Fix by moving the declaration variables. best regards, Ranier Vilela avoid-use-scoped-block-variable-lockfuncs.pat

Re: Introduce Index Aggregate - new GROUP BY strategy

2025-12-09 Thread Сергей Соловьев
Previous message had bad table formatting. Here fixed version. int | amount  | HashAgg | GroupAgg| IndexAgg| | --- | --- | --- | --- | | 100 | 3249.929602 | 3501.174072 | 3765.727121 | | 1000| 504.420643  | 501.465754  | 575.255906  | | 1   | 5

Re: Introduce Index Aggregate - new GROUP BY strategy

2025-12-09 Thread Sergey Soloviev
Hi! Are you able to provide benchmarks Yes, sure. Test matrix: - number of groups: from 100 to 100 increased by 10 times - different types: int, bigint, uuid, text - strategy: hash, group, index For each key value there are 3 tuples with different 'j' value (for aggregation logic). Also

Re: Add wait event for CommitDelay

2025-12-09 Thread Heikki Linnakangas
On 08/12/2025 21:16, Sami Imseih wrote: Thanks for the review of the patch. Please find the attachment for the updated version. Thanks! v2 LGTM Committed, thanks! - Heikki

Re: Type assertions without GCC builtins

2025-12-09 Thread Jelte Fennema-Nio
On Tue, 9 Dec 2025 at 13:43, Jelte Fennema-Nio wrote: You mean use const_cast in c++ instead of a C-style cast? Would you still want to keep the static asserts. I now understand that you meant to not remove these lines: -#if defined(__cplusplus) -#define unconstify(underlying_type, expr) const

Re: [PATCH] Update comment in nodeBitmapHeapscan.c

2025-12-09 Thread Daniel Gustafsson
> On 9 Dec 2025, at 15:02, Anton Haglund wrote: > On 2025-12-09 14:13, Daniel Gustafsson wrote: >>> On 9 Dec 2025, at 14:04, Anton Haglund wrote: >>> - * ExecBitmapHeapNext workhorse for above >> >> Judging by the commitlog that function has never existed, and the workhorse >> referred to is Bi

  1   2   >