On Sun, 23 Jan 2005, Alvaro Herrera wrote:

On Sun, Jan 23, 2005 at 01:37:30PM +0200, Heikki Linnakangas wrote:

As the patch gets more attention, I'm sure more issues will come up.

I see the changes to the lock manager are huge.  Can you explain what's
the idea behind those?  Do you release the locks and then reacquire
them, or do you reassign them to a pseudo process?

I reassign them to a pseudo process (persistedLocksProc).

Much of the changes in lock.c are just about moving code around. Some copy-paste code has been put in functions. LockAcquire has been
changed to take PGPROC as an argument, so that locks can be acquired on behalf of the pseudo process.


Then there's completely new code for persisting locks on PREPARE TRANSACTION and reacquiring them on recovery.

If it helps, I could try to split it into two patches, one with code rearrangements that don't change current behaviour, and then the actual 2PC stuff on top of that.

Are there possibilities of deadlock somewhere?

Not that I know of.

- Heikki

---------------------------(end of broadcast)---------------------------
TIP 5: Have you checked our extensive FAQ?

http://www.postgresql.org/docs/faq

Reply via email to