[svn.haxx.se] · SVN Dev · SVN Users · SVN Org · TSVN Dev · TSVN Users · Subclipse Dev · Subclipse Users · this month's index

RE: [RFC] Conceptual locking procedure for database access [#11511]

From: Oliver Klozoff <stevieoh_at_fastmail.fm>
Date: 2004-12-23 17:14:22 CET

> Like this:
>
> For every process ID slot {
> if we dont' have a slot yet and the slot is empty {
   -> We are preempted
   -> Another process gets to this point, locks slot,
      marks slot as non-empty
> Acquire lock on the process slot (NOWAIT)
   -> Slot is locked by other process; acquire fails
> if acquire was successful {
> Overwrite the slot with our process ID
> we have a slot now
> }
> if acquire failed {
> ERROR; this can't happen
   -> Oops, it just did
> }
> }
>
> I think this covers all cases, and it guarantees that we
> can't have a slot that's marked as empty and is locked at the
> same time. That's a good sanity check, IMO.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Thu Dec 23 17:15:45 2004

This is an archived mail posted to the Subversion Dev mailing list.

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.