L. Dusseault Internet Draft Xythos Document: draft-dusseault-dav-quota-00.txt C. Warner Expires: 2002 August 2001 Quota and Size Properties for DAV Collections Status of this Memo This document is an Internet-Draft and is in full conformance with all provisions of Section 10 of RFC2026. Internet-Drafts are working documents of the Internet Engineering Task Force (IETF), its areas, and its working groups. Note that other groups may also distribute working documents as Internet- Drafts. Internet-Drafts are draft documents valid for a maximum of six months and may be updated, replaced, or obsoleted by other documents at any time. It is inappropriate to use Internet-Drafts as reference material or to cite them other than as "work in progress." The list of current Internet-Drafts can be accessed at http://www.ietf.org/ietf/1id-abstracts.txt The list of Internet-Draft Shadow Directories can be accessed at http://www.ietf.org/shadow.html. Abstract WebDAV servers are frequently deployed with directory quota (size) limitations. This Internet-Draft discusses the two properties and minor behaviors needed to interoperably deal with quotas on WebDAV repositories. Table of Contents Status of this Memo................................................1 Abstract...........................................................1 New Properties.....................................................2 DAV:quota ......................................................2 DAV:quotaused ..............................................2 Error reporting....................................................2 Notes..............................................................2 References.........................................................4 Author's Addresses.................................................4 Dusseault Informational - Expires February 2002 1 DAV Collection Size and Quota August 2001 New Properties DAV:quota The DAV:quota property is used to express, in bytes, the total amount of storage space allocated to a directory. The value of this property will usually be protected, although a user with sufficient privileges may be permitted to change the value. DAV:quotaused The DAV:quotaused value is calculated by the server to indicate approximately how much storage space is already taken up in this directory (in bytes). It includes sub-directories and all resources inside those subdirectories. It is optional. The value need not be entirely accurate but must be at least as accurate as the client could calculate themselves by summing values for ôgetcontentlengthö. If the value cannot be made more accurate, then this property should be omitted. Support for this property enhances the client experience, because together with DAV:quota, the client can manage its files to avoid running out of allocated storage space. Clients may not be able to calculate the value adequately on their own, depending on how storage, including resource bodies and perhaps property values, is counted by the server. Error reporting WebDAV (RFC2518) defines the status code 507 (Insufficient Storage). This status code should be used when a client request (e.g. a PUT, PROPFIND, MKCOL, MOVE or COPY) is forbidden because it would exceed their allotted quota. In order to differentiate the response from other storage problems, the server should include an XML error body with the precondition tag, as defined by DeltaV. HTTP/1.1 507 Insufficient Storage Content-Length: 100 Content-Type: text/xml Notes Server implementations store and account for their data in many different ways. Some of the challenges: - Some server implementations find it prohibitive to count property value size, others may choose to close that loophole for better accounting. - Older versions of resources may be stored as well. Dusseault Informational - Expires February 2002 2 DAV Collection Size and Quota August 2001 - Variants of one resource may exist with different content lengths - Content may be dynamically generated. - Resource bodies can be compressed Since server storage accounting can vary so much, clients should expect the following : - The size of a file on the clientÆs file system, or in a PUT message, may not correspond to the amount of storage required by the server to store the resource. Thus, the client cannot predict 100% accurately whether a given file will be allowed given the storage quota. - Deleting a resource may not free up the same amount of storage as indicated by the ôgetcontentlengthö value for the resource. If deleting a resource does not free up any quota, the file has probably been moved to a ôtrashö folder or ôrecycle binö. - The size or ôquotausedö is not necessarily a sum of the ôgetcontentlengthö properties for resources stored in the directory. Dusseault Informational - Expires February 2002 3 DAV Collection Size and Quota August 2001 References Author's Addresses Lisa Dusseault Xythos 77 Maiden Lane, Suite 200 Phone: 1-415-248-9004 San Francisco, CA, USA Email: lisa@xythos.com Clark Warner Email: clark@thewarners.com Dusseault Informational - Expires February 2002 4