Re: DISCARD ALL (Again) - Mailing list pgsql-hackers

From Stephen Frost
Subject Re: DISCARD ALL (Again)
Date
Msg-id 20140418021515.GT2556@tamriel.snowman.net
Whole thread Raw
In response to Re: DISCARD ALL (Again)  (David G Johnston <david.g.johnston@gmail.com>)
List pgsql-hackers
* David G Johnston (david.g.johnston@gmail.com) wrote:
> > On 04/17/2014 05:24 PM, Tom Lane wrote:
> > > On the whole I'm not sure this is something we ought to get into.
> > > If you really need a fresh session, maybe you should start a
> > > fresh session.
> >
> Isn't the whole point to avoid the reconnection overhead, especially for
> connection poolers?  DISCARD ALL shouldn't cause any cleanup that wouldn't
> otherwise occur when a session disconnects.  True global data (not just
> session global) should be excluded.

Err, this is per-backend global data, so it will get cleaned up on
session disconnect.

> A better wording of the promise would be: "discard all" leaves the session
> in the same state it would be in if the underlying connection were dropped
> and re-established.

This is not accurate.
Thanks,
    Stephen

pgsql-hackers by date:

Previous
From: David G Johnston
Date:
Subject: Re: DISCARD ALL (Again)
Next
From: "Joshua D. Drake"
Date:
Subject: Re: DISCARD ALL (Again)