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

Locking non-existent paths. Time to discuss.

From: Ben Collins-Sussman <sussman_at_collab.net>
Date: 2005-03-16 20:09:09 CET

Even though it's very late in the game, there are some critical
decisions we need to make about locking features. They tend to
cascade out from each other.

* Fact: libsvn_fs allows already locks on non-existent paths. This
   feature exists to be interoperable with generic DAV clients. In DAV
   parlance, such things are called 'lock-null' resources. That is:
   they're 'null' resources (they don't exist), but are still locked.

* Fact: DAV clients expect to be able to PROPFIND on lock-null
   resources (to see the lock), and they also expect lock-null objects
   to be listed as children of directories. (Done by doing depth-1
   PROPFIND on a directory.) cmpilato and I are currently working on
   adding these behaviors to mod_dav_svn.

Question 1: Given that lock-null resources might exist, should svn
clients be able to see them? And to what extent?

     * 'svnadmin lslocks' already shows them.

     * 'svn status -u' shows remote locks on real files. Should it
       also show remote lock-null objects? This may prove very
       difficult to do; lundblad is working on it.

     * should 'svn info URL' show lock information if URL is a
       lock-null resource? It would be easy to do.

     * should 'svn ls' (i.e. svn_ra_get_dir()) show lock-null resources?

Question 2: Should the svn client (and API) be able to lock
nonexistent paths?

     * 'svn lock URL' is able to do this right now, though we could
       easily prevent it if we wanted to.

     * philip has argued that it would be useful to 'svn lock' a
       schedule-add file. While it may not prevent others from wasting
       time on conflicting schedule-adds, it *does* have the effect of
       reserving the whole path; that is, nobody can delete any parent
       directory of the schedule-add file.

cmpilato and I are running up against these questions on our quest to
make mod_dav_svn list lock-null children in directory listings.
Should mod_dav_svn only be showing these things to generic DAV
clients? Or should svn clients see them too? And if so, that would
mean making all three RA layers show lock-null children... and at that
point, perhaps svn_fs_dir_entries() should be returning them, right?

So we need to get these larger questions sorted out first.

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org
Received on Wed Mar 16 20:10:24 2005

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.