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

Re: "local add, incoming add upon merge" incorrect message

From: Kiren Pillay <kirenpillay1_at_gmail.com>
Date: Thu, 26 Jul 2012 18:51:36 +0200

Hi Stefan,

Thanks for your explanation, it is starting to make sense now. We
experience lots of merging issues in our environment but I think its due to
lack of understanding on our part!

Aslo, I am interested in why this V1-1-1-preprod branch causes the
conflict. Could you maybe have a look at this snippet of the SVN log where
I suspect things went wrong? I think the copy from v1-1-0 to trunk is the
issue?

update to 1.2.0 final
------------------------------------------------------------------------
r6933 | richard | 2011-06-13 14:49:04 +0200 (Mon, 13 Jun 2011) | 1 line
Changed paths:
   A /pams/server/trunk (from /pams/server/branches/V1-1-1-preprod:6896)
   R /pams/server/trunk/business_services/main_servlet (from
/pams/server/branches/V1-1-1-preprod/business_services/main_servlet:6927)
   D
/pams/server/trunk/core/ppfe-connectors/src/main/resources/META-INF/spring/poolmanager.properties
   D
/pams/server/trunk/core/ppfe-connectors/src/test/resources/poolmanager.properties

Copy from 1.1.1 PREPROD deployed 2011/06/10
------------------------------------------------------------------------
r6889 | richard | 2011-06-09 09:24:59 +0200 (Thu, 09 Jun 2011) | 1 line
Changed paths:
   M
/pams/server/branches/V1-1-1-preprod/business_services/bs_airtimeTransfer/pom.xml
   M
/pams/server/branches/V1-1-1-preprod/business_services/bs_archtype/pom.xml
   M
/pams/server/branches/V1-1-1-preprod/business_services/bs_archtype/src/main/resources/archetype-resources/pom.xml
   M
/pams/server/branches/V1-1-1-preprod/business_services/bs_blackberry/pom.xml
   M
/pams/server/branches/V1-1-1-preprod/business_services/bs_common/pom.xml
   M
/pams/server/branches/V1-1-1-preprod/business_services/main_servlet/pom.xml
   M
/pams/server/branches/V1-1-1-preprod/business_services/pams-bs-bonusVoucher/pom.xml
   M
/pams/server/branches/V1-1-1-preprod/business_services/pams-bs-in/pom.xml
   M
/pams/server/branches/V1-1-1-preprod/business_services/pams-bs-irDataQuery/pom.xml
   M
/pams/server/branches/V1-1-1-preprod/business_services/pams-bs-mini-recharge/pom.xml
   M
/pams/server/branches/V1-1-1-preprod/business_services/pams-bs-mmsLogService/pom.xml
   M
/pams/server/branches/V1-1-1-preprod/business_services/pams-bs-queryVoucherNumber/pom.xml
   M
/pams/server/branches/V1-1-1-preprod/business_services/pams-bs-subscriber-account/pom.xml
   M
/pams/server/branches/V1-1-1-preprod/business_services/pams-bs-subscriber-bundles/pom.xml
   M
/pams/server/branches/V1-1-1-preprod/business_services/pams-bs-subscriberProfileQuery/pom.xml
   M
/pams/server/branches/V1-1-1-preprod/business_services/pams-bs-youthProposition/pom.xml
   M /pams/server/branches/V1-1-1-preprod/business_services/pom.xml
   M
/pams/server/branches/V1-1-1-preprod/business_services/rms_facade/pom.xml
   M
/pams/server/branches/V1-1-1-preprod/business_services/subscriberProfileInQuery/pom.xml
   M /pams/server/branches/V1-1-1-preprod/core/advantage/pom.xml
   M /pams/server/branches/V1-1-1-preprod/core/audit/pom.xml
   M /pams/server/branches/V1-1-1-preprod/core/common/pom.xml
   M /pams/server/branches/V1-1-1-preprod/core/pams-pams-dao/pom.xml
   M /pams/server/branches/V1-1-1-preprod/core/pams-rms-dao/pom.xml
   M
/pams/server/branches/V1-1-1-preprod/core/pams-schema/pams-core-xsd/bin/pom.xml
   M
/pams/server/branches/V1-1-1-preprod/core/pams-schema/pams-core-xsd/pom.xml
   M
/pams/server/branches/V1-1-1-preprod/core/pams-schema/pams-core-xsd-client/bin/pom.xml
   M
/pams/server/branches/V1-1-1-preprod/core/pams-schema/pams-core-xsd-client/pom.xml
   M
/pams/server/branches/V1-1-1-preprod/core/pams-schema/pams-core-xsd-server/pom.xml
   M /pams/server/branches/V1-1-1-preprod/core/pams-schema/pom.xml
   M /pams/server/branches/V1-1-1-preprod/core/pom.xml
   M /pams/server/branches/V1-1-1-preprod/core/ppfe-connectors/pom.xml
   M /pams/server/branches/V1-1-1-preprod/core/ppfe_dao/pom.xml
   M /pams/server/branches/V1-1-1-preprod/pom.xml

Bump up to version 1.1.0 preprod
------------------------------------------------------------------------
r6888 | richard | 2011-06-09 09:18:35 +0200 (Thu, 09 Jun 2011) | 3 lines
Changed paths:
   A /pams/server/branches/V1-1-1-preprod (from
/pams/server/branches/V1-1-0-preprod:6866)

Create 1.1.1 pre prod from r 6866, before multiple ip mode

------------------------------------------------------------------------
r6866 | richard | 2011-06-08 12:01:48 +0200 (Wed, 08 Jun 2011) | 1 line
Changed paths:
   M
/pams/server/branches/V1-1-0-preprod/business_services/main_servlet/pom.xml

fix scm location for preprod
------------------------------------------------------------------------
r6861 | richard | 2011-06-08 08:47:12 +0200 (Wed, 08 Jun 2011) | 1 line
Changed paths:
   M
/pams/server/branches/V1-1-0-preprod/business_services/bs_airtimeTransfer/pom.xml
   M
/pams/server/branches/V1-1-0-preprod/business_services/bs_archtype/pom.xml
   M
/pams/server/branches/V1-1-0-preprod/business_services/bs_archtype/src/main/resources/archetype-resources/pom.xml
   M
/pams/server/branches/V1-1-0-preprod/business_services/bs_blackberry/pom.xml
   M
/pams/server/branches/V1-1-0-preprod/business_services/bs_common/pom.xml
   M
/pams/server/branches/V1-1-0-preprod/business_services/main_servlet/pom.xml
   M
/pams/server/branches/V1-1-0-preprod/business_services/pams-bs-bonusVoucher/pom.xml
   M
/pams/server/branches/V1-1-0-preprod/business_services/pams-bs-in/pom.xml
   M
/pams/server/branches/V1-1-0-preprod/business_services/pams-bs-irDataQuery/pom.xml
   M
/pams/server/branches/V1-1-0-preprod/business_services/pams-bs-mini-recharge/pom.xml
   M
/pams/server/branches/V1-1-0-preprod/business_services/pams-bs-mmsLogService/pom.xml
   M
/pams/server/branches/V1-1-0-preprod/business_services/pams-bs-queryVoucherNumber/pom.xml
   M
/pams/server/branches/V1-1-0-preprod/business_services/pams-bs-subscriber-account/pom.xml
   M
/pams/server/branches/V1-1-0-preprod/business_services/pams-bs-subscriber-bundles/pom.xml
   M
/pams/server/branches/V1-1-0-preprod/business_services/pams-bs-subscriberProfileQuery/pom.xml
   M
/pams/server/branches/V1-1-0-preprod/business_services/pams-bs-youthProposition/pom.xml
   M /pams/server/branches/V1-1-0-preprod/business_services/pom.xml
   M
/pams/server/branches/V1-1-0-preprod/business_services/rms_facade/pom.xml
   M
/pams/server/branches/V1-1-0-preprod/business_services/subscriberProfileInQuery/pom.xml
   M /pams/server/branches/V1-1-0-preprod/core/advantage/pom.xml
   M /pams/server/branches/V1-1-0-preprod/core/audit/pom.xml
   M /pams/server/branches/V1-1-0-preprod/core/common/pom.xml
   M /pams/server/branches/V1-1-0-preprod/core/pams-pams-dao/pom.xml
   M /pams/server/branches/V1-1-0-preprod/core/pams-rms-dao/pom.xml
   M
/pams/server/branches/V1-1-0-preprod/core/pams-schema/pams-core-xsd/bin/pom.xml
   M
/pams/server/branches/V1-1-0-preprod/core/pams-schema/pams-core-xsd/pom.xml
   M
/pams/server/branches/V1-1-0-preprod/core/pams-schema/pams-core-xsd-client/bin/pom.xml
   M
/pams/server/branches/V1-1-0-preprod/core/pams-schema/pams-core-xsd-client/pom.xml
   M
/pams/server/branches/V1-1-0-preprod/core/pams-schema/pams-core-xsd-server/pom.xml
   M /pams/server/branches/V1-1-0-preprod/core/pams-schema/pom.xml
   M /pams/server/branches/V1-1-0-preprod/core/pom.xml
   M /pams/server/branches/V1-1-0-preprod/core/ppfe-connectors/pom.xml
   M /pams/server/branches/V1-1-0-preprod/core/ppfe_dao/pom.xml
   M /pams/server/branches/V1-1-0-preprod/pom.xml

Move version to 1.1.0 PREPROD, and FCAPS to 1.0.0 PREPROD
------------------------------------------------------------------------
r6860 | richard | 2011-06-08 08:39:48 +0200 (Wed, 08 Jun 2011) | 3 lines
Changed paths:
   A /pams/server/branches/V1-1-0-preprod (from
/pams/server/branches/V1-1-0-QA:6859)

On Thu, Jul 26, 2012 at 3:55 PM, Stefan Sperling <stsp_at_elego.de> wrote:

> On Thu, Jul 26, 2012 at 11:53:16AM +0200, Kiren Pillay wrote:
> > Hi
> >
> > I have an additional question:
> >
> > It looks like the latest version of both branches have exactly the same.
> It
> > looks like the conflict occured in a revision that has been merged a
> while
> > back in its history ( svn://bcx-svn/
> >
> vodacom.za/pams/server/branches/V1-1-1-preprod/business_services/main_servlet/src/main/resources/testconfigs/pams.properties_at_6896
> )
> > . Is there any reason for this?
> >
>
> Hard to say without direct access to the 'svn log' output.
> Try running 'svn log -v' on the merge commits. If a file was newly
> added rather than modified, it shows up as:
> A myfile
> rather than:
> M myfile
> Or you might see:
> R myfile
> which means replaced (deleted and added in the same revision).
>
> Since an addition or deletion is an explicit operation in Subversion
> it will also be merged as such. This can get ugly in case somebody
> accidentally replaces a file. E.g. suppose rather than using 'svn revert'
> to undo edits, somebody naively runs 'svn delete' on the modified file
> followed by 'svn add' to re-add the pristine version of the file,
> and commits this change.
> If you then keep merging to and fro between two branches and never fold
> the 'add' (or 'replace') operation into a normal 'modification' operation,
> the merges will keep flagging 'add vs. add' tree conflicts. Each merge
> will try to add the object again since the addition is part of the
> changeset being merge. An addition is supposed to create a new object,
> either on top of a non-conflicted deleted object or at a path where no
> object exists. Anything else is flagged as a conflict.
>
> To fold an 'add' into a 'modify', revert the affected path after the
> merge and then merge file content from the other branch either manually
> or via a --ignore-ancestry merge. E.g. if merging from trunk to a
> branch try something like:
>
> svn merge ^/trunk
> C myfile
> > add vs. add conflict
> svn revert myfile # undo add vs. add conflict
> svn merge --ignore-ancestry ^/trunk/myfile myfile
>
> More information about what --ignore-ancestry can be found at
>
> http://svnbook.red-bean.com/en/1.7/svn.branchmerge.advanced.html#svn.branchmerge.advanced.ancestry
>
> > I suspect its because we haven't been doing reintegrate merges until
> > recently?
>
> That is quite possible. A non-reintegrate merge can produce a delta
> with different semantics and might produce an addition or replace
> where a reintegrate merge would just produce a modified file.
> Users often don't understand this or feel they shouldn't have to,
> and a missing --reintegrate option can sometimes cause merge problems
> even for later merges.
>
> BTW, steps are being taken to make the --reintegrate option unnecessary
> in Subversion 1.8, so this user interface problem will hopefully be
> fixed by then.
>
> > Is there a way to stop this from happening in future?
>
> Yes. Follow the best practices described in this chapter of the svnbook:
> http://svnbook.red-bean.com/en/1.7/svn.branchmerge.html
> A short summary that every user performing merges should know is
> provided in the output of 'svn help merge' in Subversion 1.7, also
> available at: http://subversion.apache.org/docs/svn-merge.txt
>
Received on 2012-07-26 18:52:10 CEST

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

This site is subject to the Apache Privacy Policy and the Apache Public Forum Archive Policy.