[Date Prev][Date Next] [Chronological] [Thread] [Top]

RE: back-bdb future

> -----Original Message-----
> From: Kurt D. Zeilenga [mailto:Kurt@OpenLDAP.org]

> At 10:06 AM 3/16/2003, Howard Chu wrote:
> >Do we still have read deadlock problems?
> Yes.  Jong hit one yesterday when testing on an 8-way.
> >I haven't seen any. I believe read
> >transactions can only hurt things, because locks are held
> for the life of the
> >transaction. Reads outside of transactions release their
> locks right away,
> >which assures that their locks cause the least possible
> interference.
> The key, I think, is to use N+2 transactions.  1 for finding the
> baseObject, 1 for determining the candidate set,  1 for each
> candidate.
> That way, each lock is not held for an excessive period of time.

Before we go down that path, what do you think about using a lock timeout?
(Have you already tried this?) You can set a separate timeout in the DB_ENV
for txn locks and regular locks. I suggest we only set one or the other.
Setting a timeout for the txn  locks may be easiest, because we already have
the retry logic in place.

  -- Howard Chu
  Chief Architect, Symas Corp.       Director, Highland Sun
  http://www.symas.com               http://highlandsun.com/hyc
  Symas: Premier OpenSource Development and Support