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

Re: transaction roots

From: Greg Stein <gstein_at_lyra.org>
Date: 2001-03-29 23:45:44 CEST

On Thu, Mar 29, 2001 at 07:50:12AM -0600, Ben Collins-Sussman wrote:
> Greg Stein <gstein@lyra.org> writes:
> > Can anybody see a problem with creating transactions based on the latest,
> > and verifying that the base of each desired change matches that within the
> > latest tree?
> My complaint is that you're making mod_dav_svn do a whole bunch of
> work that is *already* being done my svn_fs_merge() at commit-time.

I'm doing the check sooner, rather than later. I see no problem with that.

> Why reinvent the wheel? When you call svn_fs_commit_txn, it will
> automatically decide if the user is out-of-date. You don't need to do
> this check yourself as you build a txn against 'youngest'.

Why wait for commit_txn? That occurs *after* all the data has been delivered
to the server. On my poor little 56k modem, that could be 15 minutes later.
Then, *one* file is out of date, I say "fuck!", update that one file, and
recommit the whole bloody thing.

> Why create a new codepath to test? There's no need to have two
> different methods of building and committing transactions, depending
> on which ra layer you use. That's just an ugly, internal
> inconsistency.

Okay, then drop ra_local and we have one code path to test. :-)

> Just build a txn based on whatever revision the client passes to your
> replace_root() function. When you get a replace_dir(rev) and rev !=
> the parent's rev, then call svn_fs_copy. That's what ra_local does.

replace_root? What's that?

mod_dav_svn does not have a replace_root call, and the replace_root on the
client is not marshalled over the wire. IOW, the base_revision parameter to
replace_root is dropped on the floor.

My question about the transaction roots, and using the latest, also leads to
the fact that I never need to do an svn_fs_copy. If you want to talk about
extra work, ra_local is the one doing the work with those copies :-)

Now, let's get back to the original question. Is there a *problem* with
using the latest revision for the transaction root, rather than an arbitrary
revision (i.e. the one passed to replace_root).


Greg Stein, http://www.lyra.org/
Received on Sat Oct 21 14:36:26 2006

This is an archived mail posted to the Subversion Dev mailing list.