summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCaspar De Groot2011-07-06 07:55:34 (EDT)
committerCaspar De Groot2011-07-06 07:55:34 (EDT)
commit02e896f459004a9e8696163e94f39ca4bac73ec7 (patch)
tree80282e47089ac045f33410bd151d45abbbb6c309
parentdf4a8e2b5ab0290dcfe5613017d9519b31eeca04 (diff)
downloadcdo-02e896f459004a9e8696163e94f39ca4bac73ec7.zip
cdo-02e896f459004a9e8696163e94f39ca4bac73ec7.tar.gz
cdo-02e896f459004a9e8696163e94f39ca4bac73ec7.tar.bz2
[351046] Offline test and example failuresdrops/M20110708-0410
https://bugs.eclipse.org/bugs/show_bug.cgi?id=351046
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/session/CDOSessionImpl.java11
-rw-r--r--plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/view/CDOStoreImpl.java2
2 files changed, 12 insertions, 1 deletions
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/session/CDOSessionImpl.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/session/CDOSessionImpl.java
index a35d2e4..5759053 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/session/CDOSessionImpl.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/session/CDOSessionImpl.java
@@ -32,6 +32,7 @@ import org.eclipse.emf.cdo.common.protocol.CDOAuthenticator;
import org.eclipse.emf.cdo.common.revision.CDOElementProxy;
import org.eclipse.emf.cdo.common.revision.CDOIDAndVersion;
import org.eclipse.emf.cdo.common.revision.CDOList;
+import org.eclipse.emf.cdo.common.revision.CDORevisable;
import org.eclipse.emf.cdo.common.revision.CDORevision;
import org.eclipse.emf.cdo.common.revision.CDORevisionKey;
import org.eclipse.emf.cdo.common.revision.CDORevisionUtil;
@@ -1155,7 +1156,15 @@ public abstract class CDOSessionImpl extends Container<CDOView> implements Inter
{
InternalCDORevision newRevision = oldRevision.copy();
newRevision.adjustForCommit(commitInfo.getBranch(), commitInfo.getTimeStamp());
+
+ CDORevisable target = delta.getTarget();
+ if (target != null)
+ {
+ newRevision.setVersion(target.getVersion());
+ }
+
delta.apply(newRevision);
+ newRevision.freeze();
return new Pair<InternalCDORevision, InternalCDORevision>(oldRevision, newRevision);
}
}
@@ -1187,6 +1196,8 @@ public abstract class CDOSessionImpl extends Container<CDOView> implements Inter
Pair<CDOCommitInfo, InternalCDOTransaction> currentPair = outOfSequenceInvalidations
.remove(nextPreviousTimeStamp);
+ // If we don't have the invalidation that follows the last one we processed,
+ // then there is nothing we can do right now
if (currentPair == null)
{
break;
diff --git a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/view/CDOStoreImpl.java b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/view/CDOStoreImpl.java
index ef1fe74..09261dd 100644
--- a/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/view/CDOStoreImpl.java
+++ b/plugins/org.eclipse.emf.cdo/src/org/eclipse/emf/internal/cdo/view/CDOStoreImpl.java
@@ -383,7 +383,7 @@ public final class CDOStoreImpl implements CDOStore
value = convertToCDO(cdoObject, feature, value);
- InternalCDORevision oldRevision = getRevision(cdoObject);
+ InternalCDORevision oldRevision = getRevisionForReading(cdoObject);
Object oldValue = oldRevision.get(feature, index);
oldValue = convertToEMF(eObject, oldRevision, feature, index, oldValue);