Re: [PATCHES] LockObject patch

2004-12-20 Thread Tom Lane
Alvaro Herrera <[EMAIL PROTECTED]> writes: > On Mon, Dec 20, 2004 at 03:09:31PM -0500, Tom Lane wrote: >> I wonder whether it wouldn't be possible to clean up the "XactLockTable" >> kluge with this --- ie, instead of denoting transaction locks by a >> special relation ID, denote them by a special c

Re: [PATCHES] LockObject patch

2004-12-20 Thread Alvaro Herrera
On Mon, Dec 20, 2004 at 03:52:57PM -0500, Bruce Momjian wrote: > When we roll over OID's do we make sure we never return InvalidOid? Yes. From GetNewObjectId() /* * Check for wraparound of the OID counter. We *must* not return 0 * (InvalidOid); and as long as we have

Re: [PATCHES] LockObject patch

2004-12-20 Thread Bruce Momjian
Alvaro Herrera wrote: > On Mon, Dec 20, 2004 at 03:09:31PM -0500, Tom Lane wrote: > > Alvaro Herrera <[EMAIL PROTECTED]> writes: > > > Here is the LockObject patch I was able to come up with. It's almost > > > the same patch that Rod Taylor published two years ago; basically, it > > > expands LOCK

Re: [PATCHES] LockObject patch

2004-12-20 Thread Alvaro Herrera
On Mon, Dec 20, 2004 at 03:09:31PM -0500, Tom Lane wrote: > Alvaro Herrera <[EMAIL PROTECTED]> writes: > > Here is the LockObject patch I was able to come up with. It's almost > > the same patch that Rod Taylor published two years ago; basically, it > > expands LOCKTAG with a ClassId attribute, an

Re: [PATCHES] LockObject patch

2004-12-20 Thread Tom Lane
Alvaro Herrera <[EMAIL PROTECTED]> writes: > Here is the LockObject patch I was able to come up with. It's almost > the same patch that Rod Taylor published two years ago; basically, it > expands LOCKTAG with a ClassId attribute, and provides a LockObject > method to allow locking arbitrary object

Re: [PATCHES] LockObject patch

2004-12-20 Thread Tom Lane
Alvaro Herrera <[EMAIL PROTECTED]> writes: > I just noticed that this uses the current database Id in the LOCKTAG ... > I think I'll just make it use InvalidOid, as we will only use it to lock > shared objects by now. It can be changed when (and if) we need > different semantics in the future. In

Re: [PATCHES] LockObject patch

2004-12-19 Thread Alvaro Herrera
On Sun, Dec 19, 2004 at 11:40:40PM -0300, Alvaro Herrera wrote: Hackers, > Here is the LockObject patch I was able to come up with. It's almost > the same patch that Rod Taylor published two years ago; basically, it > expands LOCKTAG with a ClassId attribute, and provides a LockObject > method t

[PATCHES] LockObject patch

2004-12-19 Thread Alvaro Herrera
Hackers, Here is the LockObject patch I was able to come up with. It's almost the same patch that Rod Taylor published two years ago; basically, it expands LOCKTAG with a ClassId attribute, and provides a LockObject method to allow locking arbitrary objects. I omitted the uses of the new functio