jackrabbit-oak-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From thom...@apache.org
Subject svn commit: r1386524 - in /jackrabbit/oak/trunk: oak-core/src/main/java/org/apache/jackrabbit/oak/api/ oak-core/src/main/java/org/apache/jackrabbit/oak/core/ oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/name/ oak-core/src/main/java/org/apac...
Date Mon, 17 Sep 2012 09:19:27 GMT
Author: thomasm
Date: Mon Sep 17 09:19:26 2012
New Revision: 1386524

URL: http://svn.apache.org/viewvc?rev=1386524&view=rev
Log:
OAK-304 Rename ContentSession.getCurrentRoot()

Modified:
    jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/api/ContentSession.java
    jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/core/ContentSessionImpl.java
    jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/name/NamespaceRegistryImpl.java
    jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/type/NodeTypeManagerImpl.java
    jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/query/QueryEngineImpl.java
    jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/security/authentication/token/TokenProviderImpl.java
    jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/security/privilege/PrivilegeDefinitionReader.java
    jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/security/privilege/PrivilegeRegistry.java
    jackrabbit/oak/trunk/oak-core/src/test/java/org/apache/jackrabbit/oak/plugins/lucene/AbstractLuceneQueryTest.java
    jackrabbit/oak/trunk/oak-core/src/test/java/org/apache/jackrabbit/oak/query/AbstractQueryTest.java
    jackrabbit/oak/trunk/oak-core/src/test/java/org/apache/jackrabbit/oak/query/QueryTest.java
    jackrabbit/oak/trunk/oak-core/src/test/java/org/apache/jackrabbit/oak/security/user/UserProviderImplTest.java
    jackrabbit/oak/trunk/oak-core/src/test/java/org/apache/jackrabbit/oak/util/JsopUtilTest.java
    jackrabbit/oak/trunk/oak-jcr/src/main/java/org/apache/jackrabbit/oak/jcr/NodeImpl.java
    jackrabbit/oak/trunk/oak-jcr/src/main/java/org/apache/jackrabbit/oak/jcr/SessionDelegate.java

Modified: jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/api/ContentSession.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/api/ContentSession.java?rev=1386524&r1=1386523&r2=1386524&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/api/ContentSession.java
(original)
+++ jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/api/ContentSession.java
Mon Sep 17 09:19:26 2012
@@ -80,7 +80,7 @@ public interface ContentSession extends 
      * @return the current head root
      */
     @Nonnull
-    Root getCurrentRoot();
+    Root getLatestRoot();
 
     /**
      * Get the query engine.

Modified: jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/core/ContentSessionImpl.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/core/ContentSessionImpl.java?rev=1386524&r1=1386523&r2=1386524&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/core/ContentSessionImpl.java
(original)
+++ jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/core/ContentSessionImpl.java
Mon Sep 17 09:19:26 2012
@@ -73,7 +73,7 @@ class ContentSessionImpl implements Cont
 
     @Nonnull
     @Override
-    public Root getCurrentRoot() {
+    public Root getLatestRoot() {
         // TODO: improve initial repository/session. See OAK-41
         synchronized (this) {
             if (!initialised) {

Modified: jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/name/NamespaceRegistryImpl.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/name/NamespaceRegistryImpl.java?rev=1386524&r1=1386523&r2=1386524&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/name/NamespaceRegistryImpl.java
(original)
+++ jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/name/NamespaceRegistryImpl.java
Mon Sep 17 09:19:26 2012
@@ -59,7 +59,7 @@ public class NamespaceRegistryImpl imple
     public void registerNamespace(String prefix, String uri)
             throws RepositoryException {
         try {
-            Root root = session.getCurrentRoot();
+            Root root = session.getLatestRoot();
             Tree namespaces = getOrCreate(root, JcrConstants.JCR_SYSTEM, REP_NAMESPACES);
             namespaces.setProperty(
                     prefix, session.getCoreValueFactory().createValue(uri));
@@ -76,7 +76,7 @@ public class NamespaceRegistryImpl imple
 
     @Override
     public void unregisterNamespace(String prefix) throws RepositoryException {
-        Root root = session.getCurrentRoot();
+        Root root = session.getLatestRoot();
         Tree namespaces = root.getTree(NAMESPACES_PATH);
         if (namespaces == null || !namespaces.hasProperty(prefix)) {
             throw new NamespaceException(
@@ -114,7 +114,7 @@ public class NamespaceRegistryImpl imple
     @Nonnull
     public String[] getPrefixes() throws RepositoryException {
         try {
-            Tree root = session.getCurrentRoot().getTree("/");
+            Tree root = session.getLatestRoot().getTree("/");
             Map<String, String> map = Namespaces.getNamespaceMap(root);
             String[] prefixes = map.keySet().toArray(new String[map.size()]);
             Arrays.sort(prefixes);
@@ -130,7 +130,7 @@ public class NamespaceRegistryImpl imple
     @Nonnull
     public String[] getURIs() throws RepositoryException {
         try {
-            Tree root = session.getCurrentRoot().getTree("/");
+            Tree root = session.getLatestRoot().getTree("/");
             Map<String, String> map = Namespaces.getNamespaceMap(root);
             String[] uris = map.values().toArray(new String[map.size()]);
             Arrays.sort(uris);
@@ -146,7 +146,7 @@ public class NamespaceRegistryImpl imple
     @Nonnull
     public String getURI(String prefix) throws RepositoryException {
         try {
-            Tree root = session.getCurrentRoot().getTree("/");
+            Tree root = session.getLatestRoot().getTree("/");
             Map<String, String> map = Namespaces.getNamespaceMap(root);
             String uri = map.get(prefix);
             if (uri == null) {
@@ -166,7 +166,7 @@ public class NamespaceRegistryImpl imple
     @Nonnull
     public String getPrefix(String uri) throws RepositoryException {
         try {
-            Tree root = session.getCurrentRoot().getTree("/");
+            Tree root = session.getLatestRoot().getTree("/");
             Map<String, String> map = Namespaces.getNamespaceMap(root);
             for (Map.Entry<String, String> entry : map.entrySet()) {
                 if (entry.getValue().equals(uri)) {

Modified: jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/type/NodeTypeManagerImpl.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/type/NodeTypeManagerImpl.java?rev=1386524&r1=1386523&r2=1386524&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/type/NodeTypeManagerImpl.java
(original)
+++ jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/type/NodeTypeManagerImpl.java
Mon Sep 17 09:19:26 2012
@@ -183,7 +183,7 @@ public class NodeTypeManagerImpl extends
 
     @Override
     protected Tree getTypes() {
-        return session.getCurrentRoot().getTree(NODE_TYPES_PATH);
+        return session.getLatestRoot().getTree(NODE_TYPES_PATH);
     }
 
     @Override
@@ -206,7 +206,7 @@ public class NodeTypeManagerImpl extends
     @Override
     public NodeType registerNodeType(NodeTypeDefinition ntd, boolean allowUpdate) throws
RepositoryException {
         // TODO proper node type registration... (OAK-66)
-        Root root = session.getCurrentRoot();
+        Root root = session.getLatestRoot();
         Tree types = getOrCreateNodeTypes(root);
         try {
             NodeType type = internalRegister(types, ntd, allowUpdate);
@@ -221,7 +221,7 @@ public class NodeTypeManagerImpl extends
     public final NodeTypeIterator registerNodeTypes(NodeTypeDefinition[] ntds, boolean allowUpdate)
             throws RepositoryException {
         // TODO handle inter-type dependencies (OAK-66)
-        Root root = session.getCurrentRoot();
+        Root root = session.getLatestRoot();
         Tree types = getOrCreateNodeTypes(root);
         try {
             List<NodeType> list = Lists.newArrayList();
@@ -356,7 +356,7 @@ public class NodeTypeManagerImpl extends
     }
 
     private boolean nodeTypesInContent() {
-        Root currentRoot = session.getCurrentRoot();
+        Root currentRoot = session.getLatestRoot();
         Tree types = currentRoot.getTree(NODE_TYPES_PATH);
         return types != null && types.getChildrenCount() > 0;
     }
@@ -364,7 +364,7 @@ public class NodeTypeManagerImpl extends
     @Override
     public void unregisterNodeType(String name) throws RepositoryException {
         Tree type = null;
-        Root root = session.getCurrentRoot();
+        Root root = session.getLatestRoot();
         Tree types = root.getTree(NODE_TYPES_PATH);
         if (types != null) {
             type = types.getChild(getOakName(name));
@@ -384,7 +384,7 @@ public class NodeTypeManagerImpl extends
 
     @Override
     public void unregisterNodeTypes(String[] names) throws RepositoryException {
-        Root root = session.getCurrentRoot();
+        Root root = session.getLatestRoot();
         Tree types = root.getTree(NODE_TYPES_PATH);
         if (types == null) {
             throw new NoSuchNodeTypeException("Node types can not be unregistered.");

Modified: jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/query/QueryEngineImpl.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/query/QueryEngineImpl.java?rev=1386524&r1=1386523&r2=1386524&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/query/QueryEngineImpl.java
(original)
+++ jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/query/QueryEngineImpl.java
Mon Sep 17 09:19:26 2012
@@ -111,6 +111,8 @@ public class QueryEngineImpl {
         }
         q.setQueryEngine(this);
         q.prepare();
+        // TODO which revision to use? Root does not provide this info
+        // TODO which node state to use? it should come from the Root
         String revision = mk.getHeadRevision();
         return q.executeQuery(revision, store.getRoot());
     }

Modified: jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/security/authentication/token/TokenProviderImpl.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/security/authentication/token/TokenProviderImpl.java?rev=1386524&r1=1386523&r2=1386524&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/security/authentication/token/TokenProviderImpl.java
(original)
+++ jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/security/authentication/token/TokenProviderImpl.java
Mon Sep 17 09:19:26 2012
@@ -84,7 +84,7 @@ public class TokenProviderImpl implement
 
     public TokenProviderImpl(ContentSession contentSession, long tokenExpiration, UserContext
userContext) {
         this.contentSession = contentSession;
-        this.root = contentSession.getCurrentRoot();
+        this.root = contentSession.getLatestRoot();
         this.tokenExpiration = tokenExpiration;
 
         this.userProvider = userContext.getUserProvider(contentSession, root);

Modified: jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/security/privilege/PrivilegeDefinitionReader.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/security/privilege/PrivilegeDefinitionReader.java?rev=1386524&r1=1386523&r2=1386524&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/security/privilege/PrivilegeDefinitionReader.java
(original)
+++ jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/security/privilege/PrivilegeDefinitionReader.java
Mon Sep 17 09:19:26 2012
@@ -62,7 +62,7 @@ class PrivilegeDefinitionReader {
     }
 
     PrivilegeDefinitionReader(ContentSession contentSession) {
-        this(contentSession.getCurrentRoot().getTree(PRIVILEGES_PATH));
+        this(contentSession.getLatestRoot().getTree(PRIVILEGES_PATH));
     }
 
     Map<String, PrivilegeDefinition> readDefinitions() {

Modified: jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/security/privilege/PrivilegeRegistry.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/security/privilege/PrivilegeRegistry.java?rev=1386524&r1=1386523&r2=1386524&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/security/privilege/PrivilegeRegistry.java
(original)
+++ jackrabbit/oak/trunk/oak-core/src/main/java/org/apache/jackrabbit/oak/security/privilege/PrivilegeRegistry.java
Mon Sep 17 09:19:26 2012
@@ -108,7 +108,7 @@ public class PrivilegeRegistry implement
     //------------------------------------------------------------< private >---
 
     private void internalRegisterDefinitions(PrivilegeDefinition toRegister) throws RepositoryException
{
-        Root root = contentSession.getCurrentRoot();
+        Root root = contentSession.getLatestRoot();
 
         try {
             // make sure the privileges path is defined

Modified: jackrabbit/oak/trunk/oak-core/src/test/java/org/apache/jackrabbit/oak/plugins/lucene/AbstractLuceneQueryTest.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-core/src/test/java/org/apache/jackrabbit/oak/plugins/lucene/AbstractLuceneQueryTest.java?rev=1386524&r1=1386523&r2=1386524&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-core/src/test/java/org/apache/jackrabbit/oak/plugins/lucene/AbstractLuceneQueryTest.java
(original)
+++ jackrabbit/oak/trunk/oak-core/src/test/java/org/apache/jackrabbit/oak/plugins/lucene/AbstractLuceneQueryTest.java
Mon Sep 17 09:19:26 2012
@@ -65,7 +65,7 @@ public abstract class AbstractLuceneQuer
     public void before() throws Exception {
         super.before();
         session = createAdminSession();
-        root = session.getCurrentRoot();
+        root = session.getLatestRoot();
         vf = session.getCoreValueFactory();
         qe = session.getQueryEngine();
     }
@@ -96,6 +96,6 @@ public abstract class AbstractLuceneQuer
     }
 
     protected Result executeQuery(String statement) throws ParseException {
-        return qe.executeQuery(statement, SQL2, Long.MAX_VALUE, 0, null, session.getCurrentRoot(),
null);
+        return qe.executeQuery(statement, SQL2, Long.MAX_VALUE, 0, null, session.getLatestRoot(),
null);
     }
 }
\ No newline at end of file

Modified: jackrabbit/oak/trunk/oak-core/src/test/java/org/apache/jackrabbit/oak/query/AbstractQueryTest.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-core/src/test/java/org/apache/jackrabbit/oak/query/AbstractQueryTest.java?rev=1386524&r1=1386523&r2=1386524&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-core/src/test/java/org/apache/jackrabbit/oak/query/AbstractQueryTest.java
(original)
+++ jackrabbit/oak/trunk/oak-core/src/test/java/org/apache/jackrabbit/oak/query/AbstractQueryTest.java
Mon Sep 17 09:19:26 2012
@@ -65,7 +65,7 @@ public abstract class AbstractQueryTest 
         session = createAdminSession();
         vf = session.getCoreValueFactory();
         qe = session.getQueryEngine();
-        root = session.getCurrentRoot();
+        root = session.getLatestRoot();
     }
 
 }
\ No newline at end of file

Modified: jackrabbit/oak/trunk/oak-core/src/test/java/org/apache/jackrabbit/oak/query/QueryTest.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-core/src/test/java/org/apache/jackrabbit/oak/query/QueryTest.java?rev=1386524&r1=1386523&r2=1386524&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-core/src/test/java/org/apache/jackrabbit/oak/query/QueryTest.java
(original)
+++ jackrabbit/oak/trunk/oak-core/src/test/java/org/apache/jackrabbit/oak/query/QueryTest.java
Mon Sep 17 09:19:26 2012
@@ -232,7 +232,7 @@ public class QueryTest extends AbstractQ
 
     private Result executeQuery(String statement, String language, HashMap<String, CoreValue>
sv) throws ParseException {
         return qe.executeQuery(statement, language, Long.MAX_VALUE, 0, sv,
-                session.getCurrentRoot(), null);
+                session.getLatestRoot(), null);
     }
 
     /**

Modified: jackrabbit/oak/trunk/oak-core/src/test/java/org/apache/jackrabbit/oak/security/user/UserProviderImplTest.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-core/src/test/java/org/apache/jackrabbit/oak/security/user/UserProviderImplTest.java?rev=1386524&r1=1386523&r2=1386524&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-core/src/test/java/org/apache/jackrabbit/oak/security/user/UserProviderImplTest.java
(original)
+++ jackrabbit/oak/trunk/oak-core/src/test/java/org/apache/jackrabbit/oak/security/user/UserProviderImplTest.java
Mon Sep 17 09:19:26 2012
@@ -75,7 +75,7 @@ public class UserProviderImplTest extend
     @Before
     public void setUp() throws Exception {
         contentSession = createAdminSession();
-        root = contentSession.getCurrentRoot();
+        root = contentSession.getLatestRoot();
 
         defaultConfig = new UserConfig("admin");
         defaultUserPath = defaultConfig.getConfigValue(UserConfig.PARAM_USER_PATH, UserConstants.DEFAULT_USER_PATH);

Modified: jackrabbit/oak/trunk/oak-core/src/test/java/org/apache/jackrabbit/oak/util/JsopUtilTest.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-core/src/test/java/org/apache/jackrabbit/oak/util/JsopUtilTest.java?rev=1386524&r1=1386523&r2=1386524&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-core/src/test/java/org/apache/jackrabbit/oak/util/JsopUtilTest.java
(original)
+++ jackrabbit/oak/trunk/oak-core/src/test/java/org/apache/jackrabbit/oak/util/JsopUtilTest.java
Mon Sep 17 09:19:26 2012
@@ -42,7 +42,7 @@ public class JsopUtilTest extends Abstra
     public void before() throws Exception {
         super.before();
         session = createAdminSession();
-        root = session.getCurrentRoot();
+        root = session.getLatestRoot();
         vf = session.getCoreValueFactory();
     }
 

Modified: jackrabbit/oak/trunk/oak-jcr/src/main/java/org/apache/jackrabbit/oak/jcr/NodeImpl.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-jcr/src/main/java/org/apache/jackrabbit/oak/jcr/NodeImpl.java?rev=1386524&r1=1386523&r2=1386524&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-jcr/src/main/java/org/apache/jackrabbit/oak/jcr/NodeImpl.java
(original)
+++ jackrabbit/oak/trunk/oak-jcr/src/main/java/org/apache/jackrabbit/oak/jcr/NodeImpl.java
Mon Sep 17 09:19:26 2012
@@ -1218,7 +1218,7 @@ public class NodeImpl extends ItemImpl<N
         try {
             ContentSession session = sessionDelegate.getContentSession();
             CoreValueFactory factory = session.getCoreValueFactory();
-            Root root = session.getCurrentRoot();
+            Root root = session.getLatestRoot();
             Tree tree = root.getTree(dlg.getPath());
             if (tree == null) {
                 throw new ItemNotFoundException();
@@ -1291,7 +1291,7 @@ public class NodeImpl extends ItemImpl<N
         String lockOwner = sessionDelegate.getOakPathOrThrow(JCR_LOCK_OWNER);
         String lockIsDeep = sessionDelegate.getOakPathOrThrow(JCR_LOCK_IS_DEEP);
         try {
-            Root root = sessionDelegate.getContentSession().getCurrentRoot();
+            Root root = sessionDelegate.getContentSession().getLatestRoot();
             Tree tree = root.getTree(dlg.getPath());
             if (tree == null) {
                 throw new ItemNotFoundException();

Modified: jackrabbit/oak/trunk/oak-jcr/src/main/java/org/apache/jackrabbit/oak/jcr/SessionDelegate.java
URL: http://svn.apache.org/viewvc/jackrabbit/oak/trunk/oak-jcr/src/main/java/org/apache/jackrabbit/oak/jcr/SessionDelegate.java?rev=1386524&r1=1386523&r2=1386524&view=diff
==============================================================================
--- jackrabbit/oak/trunk/oak-jcr/src/main/java/org/apache/jackrabbit/oak/jcr/SessionDelegate.java
(original)
+++ jackrabbit/oak/trunk/oak-jcr/src/main/java/org/apache/jackrabbit/oak/jcr/SessionDelegate.java
Mon Sep 17 09:19:26 2012
@@ -92,7 +92,7 @@ public class SessionDelegate {
         this.contentSession = contentSession;
         this.workspace = new WorkspaceImpl(this);
         this.session = new SessionImpl(this);
-        this.root = contentSession.getCurrentRoot();
+        this.root = contentSession.getLatestRoot();
         this.conflictHandler = new AnnotatingConflictHandler(contentSession.getCoreValueFactory());
         this.autoRefresh = autoRefresh;
         this.idManager = new IdentifierManager(contentSession.getQueryEngine(), root);
@@ -371,7 +371,7 @@ public class SessionDelegate {
         }
 
         try {
-            Root currentRoot = contentSession.getCurrentRoot();
+            Root currentRoot = contentSession.getLatestRoot();
             currentRoot.copy(srcPath, destPath);
             currentRoot.commit(DefaultConflictHandler.OURS);
         }
@@ -390,7 +390,7 @@ public class SessionDelegate {
     public void move(String srcPath, String destPath, boolean transientOp)
             throws RepositoryException {
 
-        Root moveRoot = transientOp ? root : contentSession.getCurrentRoot();
+        Root moveRoot = transientOp ? root : contentSession.getLatestRoot();
 
         // check destination
         Tree dest = moveRoot.getTree(destPath);



Mime
View raw message