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

Re: Useless explicit mergeinfo records

From: Danil Shopyrin <danil_at_visualsvn.com>
Date: Wed, 27 Aug 2008 20:17:54 +0400

>> 2) Mergeinfo produced during WC-to-WC copy differs from equivalent
>> REPO-to-REPO copy. If you copy file in working copy and there is no
>> mergeinfo in the working copy then the new file will get an empty
>> mergeinfo record. Similar REPO-to-REPO copy operation doesn't produce
>> empty mergeinfo record.
>>
>> This problem was already discussed here:
>> http://svn.haxx.se/users/archive-2008-08/0471.shtml
>
> That's correct. A WC-to-WC copy isn't allowed to speak to the repository,
> so it doesn't have the opportunity to verify that "no mergeinfo" is the
> correct result. To be safe, it sets empty mergeinfo (to block any
> inheritence it couldn't have foreseen due to lack of repository access). As
> you note below, though, there are some cases when we can be smarter about this.

Can appropriate checks be done at commit stage? The logic can be as
follows: if we have "added and copied" paths then we should compute
appropriate mergeinfo for them. As I understand, there is no problems
with connection to the repository at commit stage.

I can provide a 'very dirty prototype patch' if this solution is acceptable.

>> 3) Unnecessary mergeinfo records are produced on copy operations. If
>> user plainly renames file1.txt to file2.txt in the same folder then
>> file2.txt gets explicit merge even if file1.txt didn't have one. In
>> agile environments file renaming is performed very often and this
>> result in whole working copy filled by unnecessary mergeinfo records.
>> This slows down merge operation dramatically.
>
> We agree. I thought there was an issue for this already, but I can't find
> it. In general, the behavior should be: Figure out what the mergeinfo for
> the target would be, and if it's no different than the mergeinfo for the
> source location, don't set/change it.

I also found that these unnecessary mergeinfo records also break
'svn merge --reintegrate' command. Empty mergeinfo records break
--reintegrate option too. This is also described by Mark Phippard at
http://blogs.open.collab.net/svn/2008/07/subversion-merg.html

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe_at_subversion.tigris.org
For additional commands, e-mail: dev-help_at_subversion.tigris.org
Received on 2008-08-27 18:18:09 CEST

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.