[subxacts] Fixing TODO items - Mailing list pgsql-patches

From Alvaro Herrera
Subject [subxacts] Fixing TODO items
Date
Msg-id 20040726200143.GA11479@dcc.uchile.cl
Whole thread Raw
Responses Re: [subxacts] Fixing TODO items
Re: [subxacts] Fixing TODO items
Re: [subxacts] Fixing TODO items
List pgsql-patches
Hackers,

Here is a patch that fixes some of the TODO items in the nested xacts
list:

handle large objects
password file
namespace (temp namespace cleanup)
files
Make TransactionIdIsInProgress more efficient.  Make a subxid cache and
  a negative xid cache.
Nesting level report via a ParameterStatus message sent just before
  ReadyForQuery (Z message).
Allow a readonly subtransaction inside a read-write parent, but not
  viceversa
Several tests in tqual.c have been 'optimized'.  This means most uses of
  SubTransXidsHaveCommonAncestor are gone.  Also there are additional
  places where HEAP_XMAX_INVALID is set.



There are some likely controversial changes; the Xid caches, in the
first place.  I have tested carefully but I'm not sure if all the
possible race conditions are accounted for.

Second, the storage/file/fd.c management.  I unified the arrays for
AllocateDir and AllocateFile in a single array.  It works fine AFAICS,
but I'd feel better if someone more knowledgeable takes a look.

Password file was already reviewed -- comments needed some work, which
is in.  Temp namespace handling uses the same design idea.

Large objects are managed setting the CurrentResourceOwner to
TopTransactionResourceOwner; they are manually freed on subtransaction
abort (if allocated inside the subtransaction), and kept open till main
transaction commit.


Please review this patch.  In the meantime I'll concentrate on some SGML
docs and sourcecode comments where needed.

--
Alvaro Herrera (<alvherre[a]dcc.uchile.cl>)
"I personally became interested in Linux while I was dating an English major
who wouldn't know an operating system if it walked up and bit him."
(Val Henson)

Attachment

pgsql-patches by date:

Previous
From: Peter Eisentraut
Date:
Subject: Re: win32 version info
Next
From: Bruce Momjian
Date:
Subject: Re: [HACKERS] Function to kill backend