| Summary: | Revision not revised on rawImport for deleted objects. | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Product: | [Modeling] EMF | Reporter: | Pascal Lehmann <pascal.lehmann> | ||||||||||
| Component: | cdo.core | Assignee: | Eike Stepper <stepper> | ||||||||||
| Status: | CLOSED FIXED | QA Contact: | Eike Stepper <stepper> | ||||||||||
| Severity: | normal | ||||||||||||
| Priority: | P3 | ||||||||||||
| Version: | 4.0 | ||||||||||||
| Target Milestone: | --- | ||||||||||||
| Hardware: | All | ||||||||||||
| OS: | All | ||||||||||||
| Whiteboard: | offline-01 | ||||||||||||
| Attachments: |
|
||||||||||||
|
Description
Pascal Lehmann
Created attachment 179455 [details]
Testcase
The attached test contains a merge which should usually fail because the same object was modified offline while deleted online.
However, since the changeSet does not contain the detached object (because of the bug), the following exception is thrown on commit:
java.util.ConcurrentModificationException: Attempt by Transaction[4:-1] to modify historical revision: Customer@OID5:0v1
1) The number of lines that you changed is smaller than 250. confirmed. 2) You are the only author of these changed lines. confirmed. 3) You apply the EPL to these changed lines. confirmed. Created attachment 179458 [details]
Proposed patch
I added the missing version check to the SQL query.
1) The number of lines that you changed is smaller than 250.
confirmed.
2) You are the only author of these changed lines.
confirmed.
3) You apply the EPL to these changed lines.
confirmed.
Created attachment 179461 [details]
Combined Patch - for future reference
Thank you, Pascal!
Committed to HEAD Created attachment 179757 [details]
Patch v2
I was a bit hasty when posting the patch, it does not only revise the previous version for deleted revisions, but also the deleted version itself.
Added another check to the SQL query so only one will get revised.
1) The number of lines that you changed is smaller than 250.
confirmed.
2) You are the only author of these changed lines.
confirmed.
3) You apply the EPL to these changed lines.
confirmed.
reopened, because of better patch. Committed patch v2 to HEAD Available in R20110608-1407 |