
On Thu, Mar 27, 2008 at 05:40:39PM +0100, Duncan Mac-Vicar Prett wrote:
Hi guys, I had this in my queue since Easter. to make it short, our current global lock sucks, and it will suck more when we get packagekit, zypper and yast running at the same time :-)
My prototype has passed the two initial test cases.
The idea is a scoped object, that is, to make it work you create it, and once it is out of scope, it releases the lock.
Locks are by name. And you can create writer or readers mutex for a named region. The name you give to the mutex will determine which region it will protect, and if you are entering it as reader or writer, and the behavior: wait until free, wait with timeout, or abort if locked.
How about some hierarchy between the locks? Is it needed? Can it be implemented? My idea is to have locks like "pool" "cache" "repos.d" all covered by "GLOBAL" or something like that. -- Martin Vidner, YaST developer http://en.opensuse.org/User:Mvidner Kuracke oddeleni v restauraci je jako fekalni oddeleni v bazenu -- To unsubscribe, e-mail: zypp-devel+unsubscribe@opensuse.org For additional commands, e-mail: zypp-devel+help@opensuse.org