Re: Add new error_action COPY ON_ERROR "log"

2024-03-15 Thread Michael Paquier
On Wed, Mar 13, 2024 at 07:32:37PM +0530, Bharath Rupireddy wrote: > I'm attaching the v8 patch set implementing the above idea. With this, > [1] is sent to the client, [2] is sent to the server log. This > approach not only reduces the duplicate info in the NOTICE and CONTEXT > messages, but also

Re: type cache cleanup improvements

2024-03-15 Thread Teodor Sigaev
Okay, I've applied this piece for now. Not sure I'll have much room to look at the rest. Thank you very much! Rest of patches, rebased. -- Teodor Sigaev E-mail: teo...@sigaev.ru WWW:

Re: Memory consumed by child SpecialJoinInfo in partitionwise join planning

2024-03-15 Thread Amit Langote
Hi Ashutosh, On Mon, Feb 19, 2024 at 10:01 PM Ashutosh Bapat wrote: > On Sun, Feb 18, 2024 at 10:55 PM Tomas Vondra > wrote: > > > > Hi, > > > > I took a quick look at this patch today. I certainly agree with the > > intent to reduce the amount of memory during planning, assuming it's not > >

Re: Add the ability to limit the amount of memory that can be allocated to backends.

2024-03-15 Thread Alexander Lakhin
Hello Anton, 14.03.2024 23:36, Anton A. Melnikov wrote: On 13.03.2024 10:41, Anton A. Melnikov wrote: Here is a version updated for the current master. During patch updating i mistakenly added double counting of deallocatated blocks. That's why the tests in the patch tester failed. Fixed

Re: Weird test mixup

2024-03-15 Thread Heikki Linnakangas
On 15/03/2024 09:39, Michael Paquier wrote: On Thu, Mar 14, 2024 at 07:13:53PM -0400, Tom Lane wrote: I can see that some tests would want to be able to inject code cluster-wide, but I bet that's going to be a small minority. I suggest that we invent a notion of "global" vs "local" injection

Re: remaining sql/json patches

2024-03-15 Thread jian he
On Mon, Mar 11, 2024 at 11:30 AM jian he wrote: > > On Sun, Mar 10, 2024 at 10:57 PM jian he wrote: > > > > one more issue. > > Hi > one more documentation issue. > after applied V42, 0001 to 0003, > there are 11 appearance of `FORMAT JSON` in functions-json.html > still not a single place

Re: Infinite loop in XLogPageRead() on standby

2024-03-15 Thread Ants Aasma
On Wed, 13 Mar 2024 at 04:56, Kyotaro Horiguchi wrote: > > At Mon, 11 Mar 2024 16:43:32 +0900 (JST), Kyotaro Horiguchi > wrote in > > Oh, I once saw the fix work, but seems not to be working after some > > point. The new issue was a corruption of received WAL records on the > > first standby,

Re: MERGE ... RETURNING

2024-03-15 Thread Dean Rasheed
On Fri, 15 Mar 2024 at 11:06, Dean Rasheed wrote: > > Updated patch attached. > I have gone over this patch again in detail, and I believe that the code is in good shape. All review comments have been addressed, and the only thing remaining is the syntax question. To recap, this adds support

Re: Change prefetch and read strategies to use range in pg_prewarm ... and raise a question about posix_fadvise WILLNEED

2024-03-15 Thread Nazir Bilal Yavuz
Hi, On Thu, 7 Mar 2024 at 15:26, Cédric Villemain wrote: > > On 07/03/2024 12:19, Nazir Bilal Yavuz wrote: > > > > I did not test read performance but I am planning to do that soon. I did not have the time to check other things you mentioned but I tested the read performance. The table size is

Re: Adding comments to help understand psql hidden queries

2024-03-15 Thread Jim Jones
Hi Greg, hi David On 01.02.24 23:39, David Christensen wrote: > On Thu, Feb 1, 2024 at 4:34 PM Greg Sabino Mullane wrote: >> The use of the --echo-hidden flag in psql is used to show people the way >> psql performs its magic for its backslash commands. None of them has more >> magic than "\d

Re: Extensible storage manager API - SMGR hook Redux

2024-03-15 Thread Aleksander Alekseev
Hi, > Thought I would show off what is possible with this patchset. > > [...] Just wanted to let you know that cfbot doesn't seem to be entirely happy with the patch [1]. Please consider submitting an updated version. Best regards, Aleksander Alekseev (wearing co-CFM hat) [1]:

Re: Support json_errdetail in FRONTEND builds

2024-03-15 Thread Tom Lane
Daniel Gustafsson writes: > I can't see how refusing to free memory owned and controlled by someone else, > and throwing an error if attempted, wouldn't be a sound defensive programming > measure. I think the argument is about what "refusal" looks like. An Assert seems OK to me, but anything

Re: [HACKERS] make async slave to wait for lsn to be replayed

2024-03-15 Thread Alexander Korotkov
On Mon, Mar 11, 2024 at 12:44 PM Alexander Korotkov wrote: > I've decided to put my hands on this patch. > > On Thu, Mar 7, 2024 at 2:25 PM Amit Kapila wrote: > > +1 for the second one not only because it avoids new words in grammar > > but also sounds to convey the meaning. I think you can

Re: Introduce XID age and inactive timeout based replication slot invalidation

2024-03-15 Thread Nathan Bossart
On Thu, Mar 14, 2024 at 12:24:00PM +0530, Amit Kapila wrote: > On Wed, Mar 13, 2024 at 9:24 PM Bharath Rupireddy > wrote: >> On Wed, Mar 13, 2024 at 9:21 AM Amit Kapila wrote: >> > > So, how about we turn conflict_reason to only report the reasons that >> > > actually cause conflict with

Re: CF entries for 17 to be reviewed

2024-03-15 Thread Aleksander Alekseev
Hi, > > Aleksander, I would greatly appreciate if you join me in managing CF. > > Together we can move more stuff :) > > Currently, I'm going through "SQL Commands". And so far I had not come to > > "Performance" and "Server Features" at all... So if you can handle updating > > statuses of

Re: [HACKERS] Allow INSTEAD OF DELETE triggers to modify the tuple for RETURNING

2024-03-15 Thread Aleksander Alekseev
Hi, > it took me a while to figure out why the doc build fails. > > [...] > > Anyway, based on your patch, I modified it, also added a slightly more > complicated test. Thank you for keeping the patch up-to-date. Unfortunately, it seems to be needing another rebase, according to cfbot. Best

Re: Weird test mixup

2024-03-15 Thread Heikki Linnakangas
On 15/03/2024 16:00, Tom Lane wrote: Heikki Linnakangas writes: On 15/03/2024 13:09, Heikki Linnakangas wrote: I committed a patch to do that, to put out the fire. That's turning the buildfarm quite red. Many, but not all animals are failing like this: It may be even worse than it

Re: Weird test mixup

2024-03-15 Thread Heikki Linnakangas
On 15/03/2024 14:10, Heikki Linnakangas wrote: On 15/03/2024 13:09, Heikki Linnakangas wrote: I committed a patch to do that, to put out the fire. That's turning the buildfarm quite red. Many, but not all animals are failing like this: ---

Re: Weird test mixup

2024-03-15 Thread Tom Lane
Heikki Linnakangas writes: > On 15/03/2024 13:09, Heikki Linnakangas wrote: >> I committed a patch to do that, to put out the fire. > That's turning the buildfarm quite red. Many, but not all animals are > failing like this: It may be even worse than it appears from the buildfarm status page.

Re: [PoC] Improve dead tuple storage for lazy vacuum

2024-03-15 Thread Masahiko Sawada
On Fri, Mar 15, 2024 at 4:36 PM John Naylor wrote: > > On Thu, Mar 14, 2024 at 7:04 PM Masahiko Sawada wrote: > > > > On Thu, Mar 14, 2024 at 6:55 PM John Naylor wrote: > > > > > > On Thu, Mar 14, 2024 at 12:06 PM Masahiko Sawada > > > wrote: > > > > > > > > On Thu, Mar 14, 2024 at 1:29 PM

Re: recovery modules

2024-03-15 Thread Nathan Bossart
rebased for cfbot -- Nathan Bossart Amazon Web Services: https://aws.amazon.com >From d3f497906daf1c405059b2c292f1eeb5cfeb742b Mon Sep 17 00:00:00 2001 From: Nathan Bossart Date: Wed, 15 Feb 2023 14:28:53 -0800 Subject: [PATCH v19 1/5] introduce routine for checking mutually exclusive string

Re: Popcount optimization using AVX512

2024-03-15 Thread Nathan Bossart
On Thu, Mar 14, 2024 at 07:50:46PM +, Amonson, Paul D wrote: > As for new performance numbers: I just ran a full suite like I did > earlier in the process. My latest results an equivalent to a pgbench > scale factor 10 DB with the target column having varying column widths > and appropriate

Re: Synchronizing slots from primary to standby

2024-03-15 Thread Bertrand Drouvot
Hi, On Thu, Mar 14, 2024 at 02:22:44AM +, Zhijie Hou (Fujitsu) wrote: > Hi, > > Since the standby_slot_names patch has been committed, I am attaching the last > doc patch for review. > Thanks! 1 === + continue subscribing to publications now on the new primary server without + any

Re: Improving EXPLAIN's display of SubPlan nodes

2024-03-15 Thread Tom Lane
Dean Rasheed writes: > One thing that concerns me about making even greater use of "$n" is > the potential for confusion with generic plan parameters. True. > Another possibility is to put the SubPlan and InitPlan names inline, > rather than outputting "FROM SubPlan ...". I had a go at hacking

Re: POC: Extension for adding distributed tracing - pg_tracing

2024-03-15 Thread Aleksander Alekseev
Hi Anthonin, > [...] > > The usual approach is to have pre-allocated memory. This must actually be > written (zeroed usually) or it might be lazily allocated only on page fault. > And it can't be copy on write memory allocated once in postmaster startup > then inherited by fork. > > That

RE: Popcount optimization using AVX512

2024-03-15 Thread Amonson, Paul D
> -Original Message- > From: Nathan Bossart > Sent: Friday, March 15, 2024 8:06 AM > To: Amonson, Paul D > Cc: Andres Freund ; Alvaro Herrera ip.org>; Shankaran, Akash ; Noah Misch > ; Tom Lane ; Matthias van de > Meent ; pgsql- > hack...@lists.postgresql.org > Subject: Re: Popcount

Re: Reports on obsolete Postgres versions

2024-03-15 Thread Michael Banck
On Fri, Mar 15, 2024 at 11:17:53AM +0100, Daniel Gustafsson wrote: > > On 14 Mar 2024, at 16:48, Peter Eisentraut wrote: > > One could instead, for example, describe those as "maintenance releases": > > That might indeed be a better name for what we provide. +1

Re: Statistics Import and Export

2024-03-15 Thread Corey Huinker
> > ANALYZE takes out one lock StatisticRelationId per relation, not per > attribute like we do now. If we didn't release the lock after every > attribute, and we only called the function outside of a larger transaction > (as we plan to do with pg_restore) then that is the closest we're going to >

Re: Make COPY format extendable: Extract COPY TO format implementations

2024-03-15 Thread Sutou Kouhei
Hi, In "Re: Make COPY format extendable: Extract COPY TO format implementations" on Wed, 13 Mar 2024 16:00:46 +0800, jian he wrote: >> More use cases will help us which callbacks are needed. We >> will be able to collect more use cases by providing basic >> callbacks. > Let's say the

Re: Support json_errdetail in FRONTEND builds

2024-03-15 Thread Alvaro Herrera
On 2024-Mar-14, Tom Lane wrote: > Michael Paquier writes: > > Hmm. I am not sure how much protection this would offer, TBH. One > > thing that I find annoying with common/stringinfo.c as it is currently > > is that we have two exit() calls in the enlarge path, and it does not > > seem wise to

Re: Possibility to disable `ALTER SYSTEM`

2024-03-15 Thread Jelte Fennema-Nio
On Thu, 14 Mar 2024 at 22:15, Maciek Sakrejda wrote: > In this case, the end user with access to Postgres superuser > privileges presumably also has access to the outside configuration > mechanism. The goal is not to prevent them from changing settings, but > to offer guard rails that prevent

Re: Reports on obsolete Postgres versions

2024-03-15 Thread Daniel Gustafsson
> On 14 Mar 2024, at 16:48, Peter Eisentraut wrote: > On 13.03.24 18:12, Bruce Momjian wrote: >> I think "minor" is a better term since it contrasts with "major". We >> don't actually supply patches to upgrade minor versions. > > There are potentially different adjectives that could apply to

Re: Introduce XID age and inactive timeout based replication slot invalidation

2024-03-15 Thread shveta malik
On Thu, Mar 14, 2024 at 7:58 PM Bharath Rupireddy wrote: > > While we wait to hear from others on this, I'm attaching the v9 patch > set implementing the above idea (check 0001 patch). Please have a > look. I'll come back to the other review comments soon. > patch002: 1) I would like to

Re: [PoC] Improve dead tuple storage for lazy vacuum

2024-03-15 Thread John Naylor
On Thu, Mar 14, 2024 at 7:04 PM Masahiko Sawada wrote: > > On Thu, Mar 14, 2024 at 6:55 PM John Naylor wrote: > > > > On Thu, Mar 14, 2024 at 12:06 PM Masahiko Sawada > > wrote: > > > > > > On Thu, Mar 14, 2024 at 1:29 PM John Naylor > > > wrote: > > > > Okay, here's an another idea: Change

Re: Support json_errdetail in FRONTEND builds

2024-03-15 Thread Daniel Gustafsson
> On 15 Mar 2024, at 01:10, Michael Paquier wrote: > > On Thu, Mar 14, 2024 at 10:56:46AM +0100, Daniel Gustafsson wrote: >> +/* don't allow destroys of read-only StringInfos */ >> +Assert(str->maxlen != 0); >> Considering that StringInfo.c don't own the memory here I think it's >>

Re: Weird test mixup

2024-03-15 Thread Heikki Linnakangas
On 15/03/2024 13:09, Heikki Linnakangas wrote: On 15/03/2024 01:13, Tom Lane wrote: Michael Paquier writes: Or we could just disable runningcheck because of the concurrency requirement in this test. The test would still be able to run, just less times. No, actually we *must* mark all these

Re: Support json_errdetail in FRONTEND builds

2024-03-15 Thread Daniel Gustafsson
> On 15 Mar 2024, at 09:38, Alvaro Herrera wrote: > > On 2024-Mar-14, Tom Lane wrote: > >> Michael Paquier writes: >>> Hmm. I am not sure how much protection this would offer, TBH. One >>> thing that I find annoying with common/stringinfo.c as it is currently >>> is that we have two exit()

Re: Weird test mixup

2024-03-15 Thread Heikki Linnakangas
On 15/03/2024 01:13, Tom Lane wrote: Michael Paquier writes: Or we could just disable runningcheck because of the concurrency requirement in this test. The test would still be able to run, just less times. No, actually we *must* mark all these tests NO_INSTALLCHECK if we stick with the

Re: Possibility to disable `ALTER SYSTEM`

2024-03-15 Thread Jelte Fennema-Nio
On Fri, 15 Mar 2024 at 11:08, Daniel Gustafsson wrote: > Another quirk for the documentation of this: if I disable ALTER SYSTEM I would > assume that postgresql.auto.conf is no longer consumed, but it still is (and > still need to be), so maybe "enable/disable" is the wrong choice of words?

Re: Add bump memory context type and use it for tuplesorts

2024-03-15 Thread Tomas Vondra
On 3/15/24 03:21, David Rowley wrote: > On Tue, 12 Mar 2024 at 23:57, Tomas Vondra > wrote: >> Attached is an updated version of the mempool patch, modifying all the >> memory contexts (not just AllocSet), including the bump context. And >> then also PDF with results from the two machines,

Re: Disabling Heap-Only Tuples

2024-03-15 Thread Matthias van de Meent
On Wed, 13 Mar 2024 at 14:27, Laurenz Albe wrote: > > On Thu, 2023-09-21 at 16:18 -0700, Andres Freund wrote: > > I think a minimal working approach could be to have the configuration be > > based > > on the relation size vs space known to the FSM. If the target block of an > > update is higher

Re: speed up a logical replica setup

2024-03-15 Thread Amit Kapila
On Fri, Mar 15, 2024 at 9:23 AM Euler Taveira wrote: > Did you consider adding options for publication/subscription/slot names as mentioned in my previous email? As discussed in a few emails above, it would be quite confusing for users to identify the logical replication objects once the standby

Re: meson: Specify -Wformat as a common warning flag for extensions

2024-03-15 Thread Sutou Kouhei
Hi, In <49e97fd0-c17e-4cbc-aeee-80ac51400...@eisentraut.org> "Re: meson: Specify -Wformat as a common warning flag for extensions" on Wed, 13 Mar 2024 08:38:28 +0100, Peter Eisentraut wrote: > I think the fix then is to put -Wall into CFLAGS in > Makefile.global. Looking at a diff of

Re: UUID v7

2024-03-15 Thread Aleksander Alekseev
Hi, > > So maybe we don't need the _extract_variant function? > > I think it's the best possible solution. The variant has no value besides > detecting if a version can be extracted. +1 to the idea. I doubt that anyone will miss it. -- Best regards, Aleksander Alekseev

Re: Possibility to disable `ALTER SYSTEM`

2024-03-15 Thread Daniel Gustafsson
> On 15 Mar 2024, at 03:58, Bruce Momjian wrote: > > On Thu, Mar 14, 2024 at 07:43:15PM -0400, Robert Haas wrote: >> On Thu, Mar 14, 2024 at 5:15 PM Maciek Sakrejda wrote: >>> It's not a security feature: it's a usability feature. >>> >>> It's a usability feature because, when Postgres

Re: Inconsistent printf placeholders

2024-03-15 Thread Kyotaro Horiguchi
At Fri, 15 Mar 2024 16:20:27 +0900 (JST), Kyotaro Horiguchi wrote in > I checked for that kind of msgids in a bit more intensive way. The > numbers are the line numbers in ja.po of backend. I didn't check the > same for other modules. > > > ###: invalid timeline %lld > >@

Be strict when request to flush past end of WAL in WaitXLogInsertionsToFinish

2024-03-15 Thread Bharath Rupireddy
Hi, While working on [1], it was identified that WaitXLogInsertionsToFinish emits a LOG message, and adjusts the upto ptr to proceed further when caller requests to flush past the end of generated WAL. There's a comment explaining no caller should ever do that intentionally except in cases with

Re: Shared detoast Datum proposal

2024-03-15 Thread Nikita Malakhov
Hi! Here's a slightly improved version of patch Tomas provided above (v2), with cache invalidations and slices caching added, still as PoC. The main issue I've encountered during tests is that when the same query retrieves both slices and full value - slices, like substring(t,...) the order of

Re: Inconsistent printf placeholders

2024-03-15 Thread Kyotaro Horiguchi
At Fri, 15 Mar 2024 16:01:28 +1300, David Rowley wrote in > On Fri, 15 Mar 2024 at 15:27, Kyotaro Horiguchi > wrote: > > I have considered only the two messages. Actually, buffile.c and md.c > > are already like that. The attached aligns the messages in > > pg_combinebackup.c and

Re: Infinite loop in XLogPageRead() on standby

2024-03-15 Thread Alexander Kukushkin
Hi Kyotaro, On Wed, 13 Mar 2024 at 03:56, Kyotaro Horiguchi wrote: I identified the cause of the second issue. When I tried to replay the > issue, the second standby accidentally received the old timeline's > last page-spanning record till the end while the first standby was > promoting (but it

Re: Weird test mixup

2024-03-15 Thread Michael Paquier
On Thu, Mar 14, 2024 at 07:13:53PM -0400, Tom Lane wrote: > Michael Paquier writes: >> Or we could just disable runningcheck because of the concurrency >> requirement in this test. The test would still be able to run, just >> less times. > > No, actually we *must* mark all these tests

Re: Introduce XID age and inactive timeout based replication slot invalidation

2024-03-15 Thread Bharath Rupireddy
On Fri, Mar 15, 2024 at 10:15 AM shveta malik wrote: > > > > > wal_level_insufficient it's the reason for conflict with recovery". > > +1 on maintaining both conflicting and invalidation_reason Thanks. > Thanks for the patch. JFYI, patch09 does not apply to HEAD, some > recent commit caused the

Re: [HACKERS] make async slave to wait for lsn to be replayed

2024-03-15 Thread Alexander Korotkov
On Fri, Mar 15, 2024 at 10:32 PM Kartyshov Ivan wrote: > > On 2024-03-15 22:59, Kartyshov Ivan wrote: > > On 2024-03-11 13:44, Alexander Korotkov wrote: > >> I picked the second option and left only the AFTER clause for the > >> BEGIN statement. I think this should be enough for the beginning. >

Re: BitmapHeapScan streaming read user and prelim refactoring

2024-03-15 Thread Andres Freund
Hi, On 2024-03-14 17:39:30 -0400, Melanie Plageman wrote: > I will soon send out a summary of what we investigated off-list about > 0010 (though we didn't end up concluding anything). My "fix" (leaving > BitmapAdjustPrefetchIterator() above table_scan_bitmap_next_block()) > eliminates the

Re: Support json_errdetail in FRONTEND builds

2024-03-15 Thread Michael Paquier
On Fri, Mar 15, 2024 at 11:23:07PM +0100, Daniel Gustafsson wrote: > On 15 Mar 2024, at 21:56, Andrew Dunstan wrote: >> On Fri, Mar 15, 2024 at 10:15 AM Tom Lane > > wrote: >> Yeah, I agree an Assert seems safest here. Cool. >> I'd like to get this done ASAP so I can

Re: add AVX2 support to simd.h

2024-03-15 Thread Nathan Bossart
On Fri, Mar 15, 2024 at 12:41:49PM -0500, Nathan Bossart wrote: > I've also attached the results of running this benchmark on my machine at > HEAD, after applying 0001, and after applying both 0001 and 0002. 0001 > appears to work pretty well. When there is a small "tail," it regresses a > small

Re: BitmapHeapScan streaming read user and prelim refactoring

2024-03-15 Thread Melanie Plageman
On Fri, Mar 15, 2024 at 5:14 PM Andres Freund wrote: > > Hi, > > On 2024-03-14 17:39:30 -0400, Melanie Plageman wrote: > > I will soon send out a summary of what we investigated off-list about > > 0010 (though we didn't end up concluding anything). My "fix" (leaving > >

Re: pg_upgrade failing for 200+ million Large Objects

2024-03-15 Thread Tom Lane
This patch seems to have stalled out again. In hopes of getting it over the finish line, I've done a bit more work to address the two loose ends I felt were probably essential to deal with: * Duplicative blob ACLs are now merged into a single TOC entry (per metadata group) with the GRANT/REVOKE

Re: Statistics Import and Export

2024-03-15 Thread Jeff Davis
On Fri, 2024-03-15 at 15:30 -0700, Jeff Davis wrote: > Still looking, but one quick comment is that the third argument of > dumpRelationStats() should be const, which eliminates a warning. A few other comments: * pg_set_relation_stats() needs to do an ACL check so you can't set the stats on

Re: Add basic tests for the low-level backup method.

2024-03-15 Thread Michael Paquier
On Fri, Mar 15, 2024 at 06:37:35PM +1300, David Steele wrote: > This seems like a reasonable explanation to me. FYI, drongo has just passed the test. fairywren uses TAP, does not run the recovery tests. -- Michael signature.asc Description: PGP signature

Re: Support json_errdetail in FRONTEND builds

2024-03-15 Thread Andrew Dunstan
On Fri, Mar 15, 2024 at 10:15 AM Tom Lane wrote: > Daniel Gustafsson writes: > > I can't see how refusing to free memory owned and controlled by someone > else, > > and throwing an error if attempted, wouldn't be a sound defensive > programming > > measure. > > I think the argument is about

Re: Support json_errdetail in FRONTEND builds

2024-03-15 Thread Daniel Gustafsson
> On 15 Mar 2024, at 21:56, Andrew Dunstan wrote: > On Fri, Mar 15, 2024 at 10:15 AM Tom Lane > wrote: > Daniel Gustafsson mailto:dan...@yesql.se>> writes: > > I can't see how refusing to free memory owned and controlled by someone > > else, > > and throwing an error

Re: Statistics Import and Export

2024-03-15 Thread Jeff Davis
On Fri, 2024-03-15 at 03:55 -0400, Corey Huinker wrote: > > Statistics are preserved by default, but this can be disabled with > the option --no-statistics. This follows the prevailing option > pattern in pg_dump, etc. I'm not sure if saving statistics should be the default in 17. I'm inclined

Re: Vectored I/O in bulk_write.c

2024-03-15 Thread Thomas Munro
I canvassed Andres off-list since smgrzeroextend() is his invention, and he wondered if it was a good idea to blur the distinction between the different zero-extension strategies like that. Good question. My take is that it's fine: mdzeroextend() already uses fallocate() only for nblocks > 8,

Re: Weird test mixup

2024-03-15 Thread Michael Paquier
On Fri, Mar 15, 2024 at 11:23:31AM +0200, Heikki Linnakangas wrote: > For the gin test, a single "SELECT injection_points_attach_local()" at the > top of the test file would be most convenient. > > If I have to do "SELECT > injection_points_condition('gin-finish-incomplete-split', :'datname');"

Re: Streaming I/O, vectored I/O (WIP)

2024-03-15 Thread Thomas Munro
I am planning to push the bufmgr.c patch soon. At that point the new API won't have any direct callers yet, but the traditional ReadBuffer() family of functions will internally reach StartReadBuffers(nblocks=1) followed by WaitReadBuffers(), ZeroBuffer() or nothing as appropriate. Any more

Re: Support json_errdetail in FRONTEND builds

2024-03-15 Thread Andrew Dunstan
> On Mar 16, 2024, at 8:53 AM, Daniel Gustafsson wrote: > >  >> >> On 15 Mar 2024, at 21:56, Andrew Dunstan wrote: >> On Fri, Mar 15, 2024 at 10:15 AM Tom Lane > > wrote: >> Daniel Gustafsson mailto:dan...@yesql.se>> writes: >>> I can't see how refusing to free

Re: [HACKERS] make async slave to wait for lsn to be replayed

2024-03-15 Thread Kartyshov Ivan
On 2024-03-15 22:59, Kartyshov Ivan wrote: On 2024-03-11 13:44, Alexander Korotkov wrote: I picked the second option and left only the AFTER clause for the BEGIN statement. I think this should be enough for the beginning. Thank you for your rework on your patch, here I made some fixes: 0)

Re: add AVX2 support to simd.h

2024-03-15 Thread Nathan Bossart
On Wed, Jan 10, 2024 at 09:06:08AM +0700, John Naylor wrote: > If we have say 25 elements, I mean (for SSE2) check the first 16, then > the last 16. Some will be checked twice, but that's okay. I finally got around to trying this. 0001 adds this overlapping logic. 0002 is a rebased version of

Re: Introduce XID age and inactive timeout based replication slot invalidation

2024-03-15 Thread Bertrand Drouvot
Hi, On Thu, Mar 14, 2024 at 12:24:00PM +0530, Amit Kapila wrote: > On Wed, Mar 13, 2024 at 9:24 PM Bharath Rupireddy > wrote: > > > > On Wed, Mar 13, 2024 at 9:21 AM Amit Kapila wrote: > > > > > > > So, how about we turn conflict_reason to only report the reasons that > > > > actually cause

Re: MERGE ... RETURNING

2024-03-15 Thread Jeff Davis
On Fri, 2024-03-15 at 11:20 +, Dean Rasheed wrote: > To recap, this adds support for a single RETURNING list at the end of > a MERGE command, and a special MERGE_ACTION() function that may be > used in the RETURNING list to return the action command string > ('INSERT', 'UPDATE', or 'DELETE')

Re: [HACKERS] make async slave to wait for lsn to be replayed

2024-03-15 Thread Alexander Korotkov
On Fri, Mar 15, 2024 at 4:20 PM Alexander Korotkov wrote: > On Mon, Mar 11, 2024 at 12:44 PM Alexander Korotkov > wrote: > > I've decided to put my hands on this patch. > > > > On Thu, Mar 7, 2024 at 2:25 PM Amit Kapila > wrote: > > > +1 for the second one not only because it avoids new words

Re: Fix expecteddir argument in pg_regress

2024-03-15 Thread Daniel Gustafsson
> On 14 Mar 2024, at 11:45, Daniel Gustafsson wrote: > >> On 11 Mar 2024, at 09:23, Anthonin Bonnefoy >> wrote: > >> pg_regress accepts the expecteddir argument. However, it is never used >> and outputdir is used instead to get the expected files paths. > > Nice catch,

RE: Popcount optimization using AVX512

2024-03-15 Thread Amonson, Paul D
> -Original Message- > From: Amonson, Paul D > Sent: Friday, March 15, 2024 8:31 AM > To: Nathan Bossart ... > When I tested the code outside postgres in a micro benchmark I got 200- > 300% improvements. Your results are interesting, as it implies more than > 300% improvement. Let me do

Re: Weird test mixup

2024-03-15 Thread Thomas Munro
On Sat, Mar 16, 2024 at 7:27 AM Tom Lane wrote: > Are there limits on the runtime of CI or cfbot jobs? Maybe > somebody should go check those systems. Those get killed at a higher level after 60 minutes (configurable but we didn't change it AFAIK): https://cirrus-ci.org/faq/#instance-timed-out

Re: Reports on obsolete Postgres versions

2024-03-15 Thread Jeremy Schneider
On 3/15/24 3:17 AM, Daniel Gustafsson wrote: >> On 14 Mar 2024, at 16:48, Peter Eisentraut wrote: >> On 13.03.24 18:12, Bruce Momjian wrote: > >>> I think "minor" is a better term since it contrasts with "major". We >>> don't actually supply patches to upgrade minor versions. >> >> There are

Re: Weird test mixup

2024-03-15 Thread Tom Lane
Heikki Linnakangas writes: > On 15/03/2024 16:00, Tom Lane wrote: >> It may be even worse than it appears from the buildfarm status page. >> My animals were stuck in infinite loops that required a manual "kill" >> to get out of, and it's reasonable to assume there are others that >> will require

Re: [HACKERS] make async slave to wait for lsn to be replayed

2024-03-15 Thread Kartyshov Ivan
On 2024-03-11 13:44, Alexander Korotkov wrote: I picked the second option and left only the AFTER clause for the BEGIN statement. I think this should be enough for the beginning. Thank you for your rework on your patch, here I made some fixes: 0) autocomplete 1) less jumps 2) more description

Re: Introduce XID age and inactive timeout based replication slot invalidation

2024-03-15 Thread Bharath Rupireddy
On Fri, Mar 15, 2024 at 12:49 PM shveta malik wrote: > > patch002: > > 1) > I would like to understand the purpose of 'inactive_count'? Is it only > for users for monitoring purposes? We are not using it anywhere > internally. inactive_count metric helps detect unstable replication slots

Add TAP tests for backtrace functionality (was Re: Add test module for verifying backtrace functionality)

2024-03-15 Thread Bharath Rupireddy
On Tue, Feb 20, 2024 at 11:30 AM Bharath Rupireddy wrote: > > On Tue, Feb 13, 2024 at 2:11 AM Bharath Rupireddy > wrote: > > > > Hi, > > > > Postgres has a good amount of code for dealing with backtraces - two > > GUCs backtrace_functions and backtrace_on_internal_error, > > errbacktrace; all of