| From: | Alvaro Herrera <alvherre(at)dcc(dot)uchile(dot)cl> | 
|---|---|
| To: | Dennis Bjorklund <db(at)zigo(dot)dhs(dot)org> | 
| Cc: | Bruce Momjian <pgman(at)candle(dot)pha(dot)pa(dot)us>, Pavel Stehule <stehule(at)kix(dot)fsv(dot)cvut(dot)cz>, Zeugswetter Andreas SB SD <ZeugswetterA(at)spardat(dot)at>, Andreas Pflug <pgadmin(at)pse-consulting(dot)de>, Simon Riggs <simon(at)2ndquadrant(dot)com>, Josh Berkus <josh(at)agliodbs(dot)com>, pgsql-hackers(at)postgresql(dot)org | 
| Subject: | Re: Nested Transactions, Abort All | 
| Date: | 2004-07-10 01:57:07 | 
| Message-ID: | 20040710015707.GA28878@dcc.uchile.cl | 
| Views: | Whole Thread | Raw Message | Download mbox | Resend email | 
| Thread: | |
| Lists: | pgsql-hackers | 
On Fri, Jul 09, 2004 at 11:28:23PM +0200, Dennis Bjorklund wrote:
> On Fri, 9 Jul 2004, Alvaro Herrera wrote:
> 
> > Yes, we free some things.  Granted it's not a lot, but we have stacks
> > for several things that will be always be growing with savepoints,
> 
> They will not always be growing for savepoints, you can free things when 
> using savepoints just as with subtransactions.
I still don't see when I can release a savepoint's state.
You showed a particular case, where we can finish a released savepoint
that is the innermost transaction.  However, as soon as there is another
savepoint set after the released savepoint was set, we can't free the
second.
I mean this:
begin;
  ... work ...;
  savepoint foo;
  ... more work ...;
  savepoint bar;
  ... yet more ... ;
  release foo;
At this time I can't release savepoint foo because the implementation
(nested) requires me to keep it open as long as savepoint bar exists.
If I released bar at a later time, I could close both, but not before.
-- 
Alvaro Herrera (<alvherre[a]dcc.uchile.cl>)
"¿Qué importan los años?  Lo que realmente importa es comprobar que
a fin de cuentas la mejor edad de la vida es estar vivo"  (Mafalda)
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Alvaro Herrera | 2004-07-10 01:58:02 | Re: Nested Transactions, Abort All | 
| Previous Message | Bruce Momjian | 2004-07-10 01:52:19 | Re: [HACKERS] [GENERAL] PgSQL 7.4.2 - NaN on Tru64 UNIX |