Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 145616 - Logical Model Merge can not get the ancestor revision for double moved case
Summary: Logical Model Merge can not get the ancestor revision for double moved case
Status: RESOLVED DUPLICATE of bug 145552
Alias: None
Product: Platform
Classification: Eclipse Project
Component: CVS (show other bugs)
Version: 3.2   Edit
Hardware: PC Windows XP
: P3 normal (vote)
Target Milestone: ---   Edit
Assignee: platform-cvs-inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2006-06-06 15:46 EDT by Duc Luu CLA
Modified: 2006-06-06 16:17 EDT (History)
0 users

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Duc Luu CLA 2006-06-06 15:46:27 EDT
I have a problem of loading the ancestor revision for the following double file move case.

Base (ancestor) model:
======================
/Blank Model.emx
   |
   +--- /folder1/ModelFragment_1.efx.efx


Remote model: User 1 moved file ModelFragment_1.efx from folder1 to folder2 and committed the changed
=============
/Blank Model.emx
   |
   +--- /foler2/ModelFragment_1.efx


Local model: User 2 moved file ModelFragment_1.efx from folder1 to folder3 and and do update
============
/Blank Model.emx
   |
   +---/folder3/ModelFragment_1.efx

When user 2 do update, he gets an incoming add delta for /folder2/ModelFragment_1.efx and a outgoing add delta for /folder3/ModelFragment_1.efx.
But there is no delta for /folder1/ModelFragment_1.efx on the synchronize tree.
So, there is no way of getting the content of the common ancestor revision /folder1/ModelFragment_1.efx.
 
I also try to fetch the ancestor content from RemoteResourceMappingContext.fetchBaseContents(IFile file,...) But it is empty.

I tested with text files and it also does NOT show the outgoing delete either

Base:   /testText/folder1/test1.txt
Remote: /testText/folder2/test1.txt  (file test1.txt moved from folder1 to new folder2)
Local:  /testText/folder3/test1.txt  (file test1.txt moved from folder1 to new folder3)

There is NO outgoing delete of /testText/folder1/test1.txt shown in the diff tree.

For normal file operation (text file, java file), this automatically deletion is acceptable since user don't need to take action for double deletion case. But not for the logical model merge case.

As you can see from the logical model merge, there are conflicting changes with other files in the logical model and we need to perform the full context logical merge. So, we need to load all files belong to the logical models from 3 contributors. Also there could be changes from the deleted file that the user need to know of (ie. elements moved out from the deleted file into other sub unit files).

The user may also want to revert the double file moved operation and put the file back to the original location (ie. under folder1) by reject the incoming deletion and reject the outgoing deletion via the IMergeContext.reject() method.
Comment 1 Michael Valenta CLA 2006-06-06 16:17:13 EDT

*** This bug has been marked as a duplicate of 145552 ***