Author: baedke
Date: Fri Mar 13 15:26:46 2015
New Revision: 1666481

URL: http://svn.apache.org/r1666481
Log:
OAK-1859: Migration from TarMK to MongoMK

Trivial code beautification.


Modified:
    
jackrabbit/oak/branches/1.0/oak-upgrade/src/main/java/org/apache/jackrabbit/oak/upgrade/RepositorySidegrade.java

Modified: 
jackrabbit/oak/branches/1.0/oak-upgrade/src/main/java/org/apache/jackrabbit/oak/upgrade/RepositorySidegrade.java
URL: 
http://svn.apache.org/viewvc/jackrabbit/oak/branches/1.0/oak-upgrade/src/main/java/org/apache/jackrabbit/oak/upgrade/RepositorySidegrade.java?rev=1666481&r1=1666480&r2=1666481&view=diff
==============================================================================
--- 
jackrabbit/oak/branches/1.0/oak-upgrade/src/main/java/org/apache/jackrabbit/oak/upgrade/RepositorySidegrade.java
 (original)
+++ 
jackrabbit/oak/branches/1.0/oak-upgrade/src/main/java/org/apache/jackrabbit/oak/upgrade/RepositorySidegrade.java
 Fri Mar 13 15:26:46 2015
@@ -16,6 +16,7 @@
  */
 package org.apache.jackrabbit.oak.upgrade;
 
+import java.io.File;
 import javax.jcr.RepositoryException;
 
 import com.google.common.base.Charsets;
@@ -73,6 +74,24 @@ public class RepositorySidegrade {
     /**
      * Copies the full content from the source to the target repository.
      * <p>
+     * The source repository <strong>must not be modified</strong> while
+     * the copy operation is running to avoid an inconsistent copy.
+     * <p>
+     * Note that both the source and the target repository must be closed
+     * during the copy operation as this method requires exclusive access
+     * to the repositories.
+     *
+     * @param source source node store
+     * @param target target node store
+     * @throws RepositoryException if the copy operation fails
+     */
+    public static void copy(NodeStore source, NodeStore target)
+            throws RepositoryException {
+        new RepositorySidegrade(source, target).copy();
+    }
+    /**
+     * Copies the full content from the source to the target repository.
+     * <p>
      * The source repository <strong>must not be modified</strong> while
      * the copy operation is running to avoid an inconsistent copy.
      * <p>


Reply via email to