Re: [RFC] ASOF Join

2021-11-20 Thread Todd Hubers
>But anyways this looks like just a syntactic sugar. LATERAL >JOINS should logically work just fine. Any optimisation should >deal with the LATERAL syntax style anyway. Agreed. However, if a rewrite is implemented, it then becomes encoded into PostgreSQL code what ASOF maps to. Anyone

Re: [RFC] ASOF Join

2021-11-20 Thread Ilya Anfimov
On Thu, Nov 18, 2021 at 05:11:16PM +0300, Alexander Kuzmenkov wrote: > Hi hackers, > > There was some interest in implementing ASOF joins in Postgres, see > e.g. this prototype patch by Konstantin Knizhnik: >

Re: Parallel Full Hash Join

2021-11-20 Thread Justin Pryzby
On Wed, Nov 17, 2021 at 01:45:06PM -0500, Melanie Plageman wrote: > On Sat, Nov 6, 2021 at 11:04 PM Justin Pryzby wrote: > > > > > Rebased patches attached. I will change status back to "Ready for > > > Committer" > > > > The CI showed a crash on freebsd, which I reproduced. > >

Re: logical decoding/replication: new functions pg_ls_logicaldir and pg_ls_replslotdir

2021-11-20 Thread Bharath Rupireddy
On Sun, Nov 21, 2021 at 6:58 AM Michael Paquier wrote: > > On Sat, Nov 20, 2021 at 12:29:51AM +, Bossart, Nathan wrote: > > On 11/17/21, 11:39 PM, "Bharath Rupireddy" > > wrote: > >> Please review the attached v2. > > > > LGTM. I've marked this one as ready-for-committer. > > One issue

Re: Feature Proposal: Connection Pool Optimization - Change the Connection User

2021-11-20 Thread Todd Hubers
Hi Tom, Justin, and Andrey, Thanks everybody for your feedback so far! I agree, there are a few unknowns for the design and impact and there are many details to iron out. *Benchmarking* - Overall I think it's best to explore improvements with benchmarking. The key goal of this proposal pertains

Re: VS2022: Support Visual Studio 2022 on Windows

2021-11-20 Thread Michael Paquier
On Sat, Nov 20, 2021 at 05:54:30PM +, Hans Buschmann wrote: > My skills with git are minmal yet and I am working on a correct > development platform, so sorry for any inconveniances from my side. No need to worry here. We all learn all the time. I have been able to apply your patch with a

Re: logical decoding/replication: new functions pg_ls_logicaldir and pg_ls_replslotdir

2021-11-20 Thread Michael Paquier
On Sat, Nov 20, 2021 at 12:29:51AM +, Bossart, Nathan wrote: > On 11/17/21, 11:39 PM, "Bharath Rupireddy" > wrote: >> Please review the attached v2. > > LGTM. I've marked this one as ready-for-committer. One issue that I have with this patch is that there are zero regression tests. Could

Re: Improving psql's \password command

2021-11-20 Thread Bossart, Nathan
On 11/20/21, 1:58 PM, "Tom Lane" wrote: > "Bossart, Nathan" writes: >> I did find some missing control-C handling in >> pg_receivewal/pg_recvlogical, though. Attached is a patch for those. > > Meh ... I'm inclined to fix those programs by just moving their pqsignal > calls down to after their

Re: Test::More version

2021-11-20 Thread Andrew Dunstan
On 11/20/21 11:14, Tom Lane wrote: > Andrew Dunstan writes: >> Yeah, so I think at this stage we're just waiting for you to update >> prairiedog and we can make this change. > Oh! I was intentionally waiting to do that, with the idea of verifying > that the version-detection test works ;-).

Re: Improving psql's \password command

2021-11-20 Thread Tom Lane
"Bossart, Nathan" writes: > On 11/19/21, 9:17 AM, "Tom Lane" wrote: >> Hmm, initdb's prompt-for-superuser-password might need it. > I'm able to cancel the superuser password prompt in initdb already. > It looks like the signal handlers aren't set up until after > get_su_pwd(). Right; I misread

Re: Feature Proposal: Connection Pool Optimization - Change the Connection User

2021-11-20 Thread Tom Lane
Justin Pryzby writes: > On Sun, Nov 21, 2021 at 03:11:03AM +1100, Todd Hubers wrote: >> - Google Document with Commenting turned on >> https://docs.google.com/document/d/1u6mVKEHfKtR80UrMLNYrp5D6cCSW1_arcTaZ9HcAKlw/edit?usp=sharing. > You proposed a PQ protocol version of SET ROLE/SET SESSION

Re: RecoveryInProgress() has critical side effects

2021-11-20 Thread Heikki Linnakangas
On 17/11/2021 00:04, Andres Freund wrote: On 2021-11-16 16:30:27 -0500, Robert Haas wrote: I'm still not entirely clear on whether you prefer v1-0002, v2-0002, or something else. I think it basically doesn't matter much. It's such a small piece of the cost compared to either the cost of a

Re: Feature Proposal: Connection Pool Optimization - Change the Connection User

2021-11-20 Thread Justin Pryzby
On Sun, Nov 21, 2021 at 03:11:03AM +1100, Todd Hubers wrote: > I have just joined to start a community consultation process for a > proposal. I just finished the proposal document, I spent time writing a > Problem and Solution section, and I have done quite a bit of upfront > exploration of the

AW: VS2022: Support Visual Studio 2022 on Windows

2021-11-20 Thread Hans Buschmann
Hello Daniel, Thank you for looking into it. My skills with git are minmal yet and I am working on a correct development platform, so sorry for any inconveniances from my side . When upgraded Microsoft jumped directly from Preview 7 to Preview 7.1 of VS2022 by skipping the release version of

Re: Feature Proposal: Connection Pool Optimization - Change the Connection User

2021-11-20 Thread Andrey Borodin
Hi Todd! > I have just joined to start a community consultation process for a proposal. > I just finished the proposal document, I spent time writing a Problem and > Solution section, and I have done quite a bit of upfront exploration of the > code. > > See: > > * Google Document with

Re: TOAST - why separate visibility map

2021-11-20 Thread Tom Lane
Andres Freund writes: > On November 19, 2021 12:31:00 PM PST, Tom Lane wrote: >> It might be feasible to drop the visibility map for toast tables, though. > I think it be a bad idea - the VM is used by vacuum to avoid rereading > already vacuumed ranges. Loosing that for large toast tables

Re: Test::More version

2021-11-20 Thread Tom Lane
Andrew Dunstan writes: > Yeah, so I think at this stage we're just waiting for you to update > prairiedog and we can make this change. Oh! I was intentionally waiting to do that, with the idea of verifying that the version-detection test works ;-). I'm prepared to do it as soon as you push an

Feature Proposal: Connection Pool Optimization - Change the Connection User

2021-11-20 Thread Todd Hubers
Hi, I have just joined to start a community consultation process for a proposal. I just finished the proposal document, I spent time writing a Problem and Solution section, and I have done quite a bit of upfront exploration of the code. See: - Google Document with Commenting turned on

Re: update with no changes

2021-11-20 Thread Andrew Dunstan
On 11/20/21 10:03, Marcos Pegoraro wrote: > > suppress_redundant_updates_trigger was created precisely because it's > not always easy to create application code in such a way that it > generates no redundant updates. However, there is a cost to using it, > and the break even

Re: update with no changes

2021-11-20 Thread Marcos Pegoraro
> > suppress_redundant_updates_trigger was created precisely because it's > not always easy to create application code in such a way that it > generates no redundant updates. However, there is a cost to using it, > and the break even point can be surprisingly high. It should therefore > be used

Re: update with no changes

2021-11-20 Thread Andrew Dunstan
On 11/19/21 12:57, Marcos Pegoraro wrote: > > I get the idea of letting the server centralize logic like this - > but frankly if the application is choosing to send all that data > across the wire just to have the server throw it away the > application is wasting network I/O.  If

rename SnapBuild* macros in slot.c

2021-11-20 Thread Bharath Rupireddy
Hi, It seems like the same macro names for SnapBuildOnDiskNotChecksummedSize and SnapBuildOnDiskChecksummedSize are being used in slot.c and snapbuild.c. I think, in slot.c, we can rename them to ReplicationSlotOnDiskNotChecksummedSize and ReplicationSlotOnDiskChecksummedSize similar to the other

Re: Test::More version

2021-11-20 Thread Andrew Dunstan
On 11/15/21 12:43, Tom Lane wrote: > > So, discounting prairiedog's intentionally trailing-edge installation, > the oldest stuff in the buildfarm is 0.98, of which there are five > instances belonging to four different owners. > > Based on this, I'm inclined to think we should select 0.98 as the

Re: Should rename "startup process" to something else?

2021-11-20 Thread Andrew Dunstan
On 11/18/21 15:22, Tom Lane wrote: > Alvaro Herrera writes: >> If we change the name, and I support the idea that we do, I think a >> good name would be "wal replay". I think "recovery" is not great >> precisely because in a standby there is likely no crash that we're >> recovering from. >

Re: Pasword expiration warning

2021-11-20 Thread Andrew Dunstan
On 11/19/21 19:17, Bossart, Nathan wrote: > On 11/19/21, 7:56 AM, "Tom Lane" wrote: >> That leads me to wonder about server-side solutions. It's easy >> enough for the server to see that it's used a password with an >> expiration N days away, but how could that be reported to the >> client?

Re: pg_get_publication_tables() output duplicate relid

2021-11-20 Thread Amit Kapila
On Fri, Nov 19, 2021 at 10:58 AM Amit Kapila wrote: > > On Fri, Nov 19, 2021 at 7:19 AM Amit Langote wrote: > > > > The problematic case is attaching the partition *after* the subscriber > > has already marked the root parent as synced and/or ready for > > replication. Refreshing the