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

Re: svn commit: r1558224 - in /subversion/trunk/subversion:libsvn_fs_fs/tree.c libsvn_fs_x/tree.c tests/libsvn_fs/fs-test.c

From: Stefan Fuhrmann <stefan.fuhrmann_at_wandisco.com>
Date: Wed, 15 Jan 2014 16:32:42 +0100

On Wed, Jan 15, 2014 at 12:07 PM, Philip Martin
<philip.martin_at_wandisco.com>wrote:

> This change doesn't work over RA the way I would expect. I'd expect
> these two commits to work:
>
> svnadmin create repo
> svn import -mm repo/format file://`pwd`/repo/A/f
> svn import -mm repo/format file://`pwd`/repo/A/g
> svn co http://localhost:8888/obj/repo/A wc1
> echo 1 >> wc1/f
> svn co http://localhost:8888/obj/repo/A wc2
> svn ps p v wc2
> echo 2 >> wc2/g
>
> $ svn st wc1
> M wc1/f
>
> $ svn st wc2
> M wc2
> M wc2/g
>
> But the commit fails with an out-of-date error before reaching the FS
> layer:
>
> $ svn ci -mm wc1
> Transmitting file data .
> Committed revision 3
> $ svn ci -mm wc2
> Sending wc2
> Sending wc2/g
> ../src/subversion/svn/commit-cmd.c:182,
> ../src/subversion/libsvn_client/commit.c:1076,
> ../src/subversion/libsvn_client/commit.c:154:
> (apr_err=SVN_ERR_RA_OUT_OF_DATE)
> svn: E170004: Commit failed (details follow):
> ../src/subversion/libsvn_client/commit.c:991,
> ../src/subversion/libsvn_client/commit_util.c:1884,
> ../src/subversion/libsvn_delta/path_driver.c:294,
> ../src/subversion/libsvn_delta/path_driver.c:100,
> ../src/subversion/libsvn_ra_serf/commit.c:1775,
> ../src/subversion/libsvn_ra_serf/commit.c:934,
> ../src/subversion/libsvn_ra_serf/util.c:933,
> ../src/subversion/libsvn_ra_serf/util.c:907,
> ../src/subversion/libsvn_ra_serf/util.c:872,
> ../src/subversion/libsvn_ra_serf/multistatus.c:560:
> (apr_err=SVN_ERR_RA_OUT_OF_DATE)
> svn: E170004: Directory '/A' is out of date
>

I am aware that this limitation still exists. The patch only
handles concurrent transactions but does not address
the out-of-date working copy problem.

As you already figured out, there is an explicit check in
the repos layer that prevents property changes on dirs
that are not at the txn base revision, i.e. node-HEAD at the
time of the begin of that txns. The reason is that the API
does not actually have a "change prop" but only a "set
prop" function. Prop changes to the same node between
wc BASE and txn base would simply be lost.

So, we still have a theoretical scalability issue but now
it is the time a "svn up --depth=empty" at the root node
(in theory a constant value) that should be less than the
average time between commits.

-- Stefan^2.
Received on 2014-01-15 16:33:14 CET

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