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

Re: commit: ldap/servers/slapd/back-bdb add.c back-bdb.h bind.c cache.c compare.c config.c delete.c dn2entry.c dn2id.c filterindex.c id2entry.c idl.c init.c key.c modify.c modrdn.c proto-bdb.h referral.c search.c tools.c

Hallvard B Furuseth wrote:
Howard Chu writes:
My approach for that was to set the NOWAIT flag on the read txns, but
that eats up too much CPU because most of our code immediately retries
whenever it sees the DB_LOCK_NOTGRANTED result. I've removed the
NOWAIT flag again. Still looking at the impact of this change.

Is this the kind of situation where it can help to retry at increasing and somewhat randomized intervals until it succeeds? (Randomized so two threads won't keep getting in each others' way.)

Perhaps. We already have a backoff function in here, I guess it wouldn't hurt to use it. Until now, I've never actually seen retries occur on read operations...

  -- Howard Chu
  CTO, Symas Corp.           http://www.symas.com
  Director, Highland Sun     http://highlandsun.com/hyc/
  Chief Architect, OpenLDAP  http://www.openldap.org/project/