You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by sv...@mobsol.be on 2007/12/10 09:05:59 UTC

Request for review: partial repository sync feature

Yesterday I finished the work on the partial repository sync feature on the
svnsync-folder branch. If someone has time to review the changes on that
branches before I merge it back to trunk that would be nice.

This is how it works:
- In svnsync init you can now specify a url to any path in the repository, ex.
http://repos/svn/trunk/www .
- During replay a filter is used that filters out all paths expect:
  - /trunk/www
  - /trunk   (depth empty)
  - /        (depth empty)   -> I have to check if propmods on '/' are actually
included, didn't test it but they should be.
- All revisions on the master of which all files and directories are filtered
out result in empty revisions on the slave.
- This works over all ra layers.

The filter has the same effect as not having read access to /trunk/www. This
means things like moving to /trunk/ww is converted to Add and moving from
/trunk/www is converted to Delete, I didn't have to change anything there.

Since changes to mod_dav_svn had to be made to make this work, the 'partial
replay' feature will only work with a 1.5 server. I added a 'partial-replay'
capability to find this out in a clean way. We return an error when a user
wants to sync a part of the repository on a 1.4 server.

The diff to review is:
$ svn diff http://svn.collab.net/repos/svn/trunk@28341
http://svn.collab.net/repos/svn/branches/svnsync-folder

thx,

Lieven

----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.

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

Re: Request for review: partial repository sync feature

Posted by sv...@mobsol.be.
Quoting "C. Michael Pilato" <cm...@collab.net>:

> svnlgo@mobsol.be wrote:
> > Yesterday I finished the work on the partial repository sync feature on the
> > svnsync-folder branch. If someone has time to review the changes on that
> > branches before I merge it back to trunk that would be nice.
> >
> > This is how it works:
> > - In svnsync init you can now specify a url to any path in the repository,
> ex.
> > http://repos/svn/trunk/www .
> > - During replay a filter is used that filters out all paths expect:
> >   - /trunk/www
> >   - /trunk   (depth empty)
> >   - /        (depth empty)   -> I have to check if propmods on '/' are
> actually
> > included, didn't test it but they should be.
> > - All revisions on the master of which all files and directories are
> filtered
> > out result in empty revisions on the slave.
> > - This works over all ra layers.
> >
> > The filter has the same effect as not having read access to /trunk/www.
>
> You mean, "as having read access only to /trunk/www", right?

Oh, you're absolutely right. My mistake.

Lieven

----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.

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

Re: Request for review: partial repository sync feature

Posted by "C. Michael Pilato" <cm...@collab.net>.
svnlgo@mobsol.be wrote:
> Yesterday I finished the work on the partial repository sync feature on the
> svnsync-folder branch. If someone has time to review the changes on that
> branches before I merge it back to trunk that would be nice.
> 
> This is how it works:
> - In svnsync init you can now specify a url to any path in the repository, ex.
> http://repos/svn/trunk/www .
> - During replay a filter is used that filters out all paths expect:
>   - /trunk/www
>   - /trunk   (depth empty)
>   - /        (depth empty)   -> I have to check if propmods on '/' are actually
> included, didn't test it but they should be.
> - All revisions on the master of which all files and directories are filtered
> out result in empty revisions on the slave.
> - This works over all ra layers.
> 
> The filter has the same effect as not having read access to /trunk/www.

You mean, "as having read access only to /trunk/www", right?

(+1 on the concept; haven't reviewed the patch.)

-- 
C. Michael Pilato <cm...@collab.net>
CollabNet   <>   www.collab.net   <>   Distributed Development On Demand


Re: Request for review: partial repository sync feature

Posted by sv...@mobsol.be.
Quoting David Glasser <gl...@davidglasser.net>:

> On Dec 10, 2007 1:05 AM,  <sv...@mobsol.be> wrote:
> >
> > Yesterday I finished the work on the partial repository sync feature on the
> > svnsync-folder branch. If someone has time to review the changes on that
> > branches before I merge it back to trunk that would be nice.
> >
> > This is how it works:
> > - In svnsync init you can now specify a url to any path in the repository,
> ex.
> > http://repos/svn/trunk/www .
> > - During replay a filter is used that filters out all paths expect:
> >   - /trunk/www
> >   - /trunk   (depth empty)
> >   - /        (depth empty)   -> I have to check if propmods on '/' are
> actually
> > included, didn't test it but they should be.
> > - All revisions on the master of which all files and directories are
> filtered
> > out result in empty revisions on the slave.
> > - This works over all ra layers.
> >
> > The filter has the same effect as not having read access to /trunk/www.
> This
> > means things like moving to /trunk/ww is converted to Add and moving from
> > /trunk/www is converted to Delete, I didn't have to change anything there.
> >
> > Since changes to mod_dav_svn had to be made to make this work, the 'partial
> > replay' feature will only work with a 1.5 server. I added a
> 'partial-replay'
> > capability to find this out in a clean way. We return an error when a user
> > wants to sync a part of the repository on a 1.4 server.
> >
> > The diff to review is:
> > $ svn diff http://svn.collab.net/repos/svn/trunk@28341
> > http://svn.collab.net/repos/svn/branches/svnsync-folder
>
> This also still only reports syncing identical paths with svnsync,
> right?  ie, you can't sync /trunk/www to the root of a repo with this,
> or anything to not-the-root?  (And this may commit lots of empty
> revisions, just like with authz?)
>
> (These aren't problems, just want to make sure I fully understand.)

Yes on both your questions. You'll get a slave repository with the exact same
structure as the master, but limited to one folder.

The main use cases are to sync one project from a repository with
/project/trunk|branches|tags structure or to sync one branch.

If you have other use cases in mind let them know.

Lieven


----------------------------------------------------------------
This message was sent using IMP, the Internet Messaging Program.

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

Re: Request for review: partial repository sync feature

Posted by David Glasser <gl...@davidglasser.net>.
On Dec 10, 2007 1:05 AM,  <sv...@mobsol.be> wrote:
>
> Yesterday I finished the work on the partial repository sync feature on the
> svnsync-folder branch. If someone has time to review the changes on that
> branches before I merge it back to trunk that would be nice.
>
> This is how it works:
> - In svnsync init you can now specify a url to any path in the repository, ex.
> http://repos/svn/trunk/www .
> - During replay a filter is used that filters out all paths expect:
>   - /trunk/www
>   - /trunk   (depth empty)
>   - /        (depth empty)   -> I have to check if propmods on '/' are actually
> included, didn't test it but they should be.
> - All revisions on the master of which all files and directories are filtered
> out result in empty revisions on the slave.
> - This works over all ra layers.
>
> The filter has the same effect as not having read access to /trunk/www. This
> means things like moving to /trunk/ww is converted to Add and moving from
> /trunk/www is converted to Delete, I didn't have to change anything there.
>
> Since changes to mod_dav_svn had to be made to make this work, the 'partial
> replay' feature will only work with a 1.5 server. I added a 'partial-replay'
> capability to find this out in a clean way. We return an error when a user
> wants to sync a part of the repository on a 1.4 server.
>
> The diff to review is:
> $ svn diff http://svn.collab.net/repos/svn/trunk@28341
> http://svn.collab.net/repos/svn/branches/svnsync-folder

This also still only reports syncing identical paths with svnsync,
right?  ie, you can't sync /trunk/www to the root of a repo with this,
or anything to not-the-root?  (And this may commit lots of empty
revisions, just like with authz?)

(These aren't problems, just want to make sure I fully understand.)

--dave


-- 
David Glasser | glasser@davidglasser.net | http://www.davidglasser.net/

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