Amaya

Cooperating through WebDAV

About WebDAV

WebDAV (WWW Distributed Authoring and Versioning) is a set of extensions to the HTTP protocol, which allows users to collaboratively edit and manage web resources on remote servers. It aims to extend the HTTP protocol to develop new distributed authoring tools in the web, specially emphasizing the collaborative authoring of web pages.

The lock mechanism defined in WebDAV has been design to prevent the resources overwriting (that is, to prevent the lost update problem) using the operations lock and unlock. A lock controls the write access to a resource by limiting HTTP writing operations, like PUT, POST and DELETE. This means that only somebody who knows the lock will be able to execute those operations. The WebDAV protocol also defines two lock scopes: an exclusive and a shared lock. An exclusive lock guarantees that one person possess the lock, and no one else will be able to lock the resource (it does not affect the resource reading). A shared lock allows a group of users to create their locks over a resource, but they must trust each other to prevent access problems. Besides, each lock has a timeout, but the user cannot forget that locks may disappear in the server due to exceptions in the server.

You can find more informations about WebDAV in RFC 2518 and also at the WebDAV.org website.

WebDAV support in Amaya

Amaya has an optional and limited support for WebDAV. This includes the following operations: lock/unlock a WebDAV compilant resource, view the WebDAV properties of a resource, and lock discovery capabilities. Besides, it also includes some awareness functions, that can automatically inform users about locked resources.

Sharing documents

The WebDAV support present in Amaya intents to help small groups of users to edit collaboratively their web pages. To illustrate how it works, here is an example: supose that you have a WebDAV server (indeed, you must have a Web server that supports WebDAV to work with it) named davserver.mycompany.com, and you and your colleagues want to edit collaboratively some documents that are in the WebDAV folder /shared/ (WebDAV folders are called collections).

So, imagine that you need to change the document http://davserver.mycompany.com/shared/Doc1.html. To do so, you load the document in your Amaya editor, and then you can lock this document (Lock resource entry in Tools/Cooperation menu. Once you locked the document, if one of your colleagues tries to save some change in this document, s/he will be warned about your lock, and updates will not be lost automatically. Thus, while the document is locked, you can safely modify it, and when you have finished your work and saved the document, you can unlock it, allowing you colleague to lock the document and do his/her modifications.

If you want to be aware whether a colleague has locked a Web page, you can use the View resource properties entry in the Tools / Cooperation menu to see all the properties of the page, or you can configure Amaya to automatically inform you if the page is locked. To do so, you will need to open the Preferences / WebDAV dialog box, mark the General Awareness option and put your shared folder name in the User's WedDAV Resource List field (http://davserver.mycompany.com/shared/, in our example). Once you did this, when loading a page locked by a colleague under http://davserver.mycompany.com/shared/ folder, you will be notified by Amaya about this.

WebDAV options

The following options can be set with the Preferences / WebDAV dialog box. They are also available in the Amaya registry:

User's personal reference (URL)
An URL that identifies the user. Example: mailto:myself@myhost.com or http://myhost.com/myhomepage.html

Registry: DAV_USER_URL= [ URL ]

Lock Depth
If depth is infinite, a lock over a collection (folder) will affect all components. Otherwise, the lock will affect only the collection, preventing an user that does not know the lock to create or remove components.

Registry: DAV_DEPTH= [ infinity | 0 ]

Lock Scope
The lock scope: exclusive or shared.

Registry: DAV_LOCK_SCOPE= [ exclusive | shared ]

Lock Timeout
The desired timeout for the lock. "Infinite" means that there is no timeout value, and "Other (Seconds)" will try to get a timeout value of x seconds (value x specified by the next field).
Registry: DAV_TIMEOUT= [ Infinite | Second-XXXX ]
General Awareness
Indicates if you want basic awareness information about locked resources

Registry: DAV_AWARENESS= [ yes | no ]

Awareness on exit
Indicates if you want to receive information about your own locks, when you leave a resource.

Registry: DAV_AWARENESS_ONEXIT=[ yes | no ]

User's WebDAV Resource List (URL URL)
A list of the URLs of the resources you use as WebDAV resources.

Registry: DAV_URLS= [ URL URL URL ... ]

Compiling Amaya with WebDAV

WebDAV support is an optional feature of Amaya. To compile and use it, you need the following:

Once you made the cvs check-out of Libwww with WebDAV support and get Amaya sources, you should follow this bootstrap instructions (under Linux/Unix environments - for windows environments, see Amaya and Libwww homepage):

At libwww folder:

At Amaya folder: