On this page I try to collect everything on Resource Locking.
Martin Lohmeier noticed that there is currently no way horde can tell you that anyone is already editing an item when you try to edit an item (notes, wiki, etc). Kevin Myer asked the same question a few weeks ago on the dev list, but no one was working on this. So he decided to solve this problem.
There are (a least) two ways how this can be done:
Locking The easy one is to lock an item for a certain time when someone starts to edit it. If someone else trys to edit it Horde will deny this and tell him / her to wait. The disadvantage of this is that only one person can edit one item at one time (not very good for a groupware). However there is additionally the concept of a "shared" lock which may be useful with the next strategy.
Try to merge The better way would be that Horde trys to merge the changes, similar to cvs. If changes cannot be merged, Horde will tell the user. I think this is what I'll try.
Since I needed a mechanism to lock resources for full WebDAV functionality I have written a Horde_Lock subsystem. The work to date has been committed to Horde CVS HEAD. This subsystem is capable of locking arbitrary resources identified by URI. The locks support timeouts and exclusive vs. shared semantics.
The API has been published in the Horde API documentation. Anyone interested in this project is invited to review the following URL and provide feedback to the Horde Dev mailing list.
These are potential uses for the Lock system that have been requested or proposed by others.
Ben Klang <ben@alkaloid.net>