Re: Concurrency in an RDB

From: Cimode <cimode_at_hotmail.com>
Date: 14 Dec 2006 15:22:25 -0800
Message-ID: <1166138545.166674.233480_at_79g2000cws.googlegroups.com>


NENASHI, Tegiri a écrit :

> "Cimode" <cimode_at_hotmail.com> wrote in
> news:1166113032.469596.104340_at_n67g2000cwd.googlegroups.com:
>
> >
> > Christopher Browne a écrit :
> >
> >> In an attempt to throw the authorities off his trail, Bob Badour
> >> <bbadour
> > _at_pei.sympatico.ca> transmitted:
> >> > Transactions may acquire and release many locks over the duration
> >> > of the transaction which may be orders of magnitude longer than the
> >> > duration of any lock.
> >>
> >> Are you sure they ought to release them?
> >>
> > There is NO direct relationship between locks and deadlocks.
>
> It is not true. Locks can cause dead locks:
>
> Process1: ->lock Resource1--work 2 minutes -> lock Resource2 -> wait for
> Process2 ->dead lock
> Process2: ->lock Resource2--work 1 minute -> lock Resource1 -> wait for
> Process1 ->dead lock
I have never stated that locks put on objects can not cause deadlocks to happen. I was merely trying to clarify for pedagogic purposes that they are of different nature and that a lock does not necessarily cause a deadlock. Deadlock are a situation of exceptional nature. That's is why stating that there's a direct cause effect relationship between the two is hazardous. A lock is a normal mechanism and is not the real cause of the deadlock problem which lies more on the IO/disk swapping contention of ressources. A matter of perspective, idiots like Marshall will probably not perceive in a lifetime. Received on Fri Dec 15 2006 - 00:22:25 CET

Original text of this message