You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Michael Brouwer <mi...@tlaloc.net> on 2004/10/13 17:53:10 UTC

Locking functional spec: branches

Something that strikes me as a limitation of the current locking spec 
is that it is limited to wc's only.

I like to think of a wc as a special case of a branch that hasn't made 
it into the repository yet.  If for some reason you want to move your 
wc from one machine to another, an easy way to do this is to make a 
branch for the change you are working on.  commit your partially 
completed work and checkout the branch in the new location.

IMHO it should be possible to have a branch (rather than a particular 
wc) own the lock on a file (probably limited to the version of the file 
that the branch contains direct copies of).

A good example of this would be if you use an IDE that writes binary or 
unmergable project files.  Let say you make a branch to work on a 
change to the project which modifies the project file and several 
sources as well (or perhaps other unmergable resources such as tiff 
files etc.).  It would totally make sense for this branch to own the 
lock on files until you merge the branch back to the version from which 
it was copies (and which contains the files that are locked).

Michael


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: Locking functional spec: branches

Posted by Branko Čibej <br...@xbc.nu>.
Michael Brouwer wrote:

> Something that strikes me as a limitation of the current locking spec 
> is that it is limited to wc's only.
>
> I like to think of a wc as a special case of a branch that hasn't made 
> it into the repository yet.  If for some reason you want to move your 
> wc from one machine to another, an easy way to do this is to make a 
> branch for the change you are working on.  commit your partially 
> completed work and checkout the branch in the new location.
>
> IMHO it should be possible to have a branch (rather than a particular 
> wc) own the lock on a file (probably limited to the version of the 
> file that the branch contains direct copies of).

A lock cannot be owned by an object in the repository, it has to be 
owned by a principal. In fact locks are not owned by WCs, but by users. 
It is reasonable to allow a user to remove their WC, fly to melbourne, 
checkout again and use the lock discovery mechanism to retrieve their 
lock tokens.

-- Brane


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org