You are viewing a plain text version of this content. The canonical link for it is here.
Posted to oak-issues@jackrabbit.apache.org by "Julian Reschke (JIRA)" <ji...@apache.org> on 2013/12/09 15:46:08 UTC
[jira] [Commented] (OAK-1266) DocumentStore implementation for SQL
databases
[ https://issues.apache.org/jira/browse/OAK-1266?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13843211#comment-13843211 ]
Julian Reschke commented on OAK-1266:
-------------------------------------
The patch below swaps the MemoryDocumentStore with the SQLDocumentStore. Beware: test failures.
Index: oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/mongomk/MongoMK.java
===================================================================
--- oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/mongomk/MongoMK.java (revision 1549583)
+++ oak-core/src/main/java/org/apache/jackrabbit/oak/plugins/mongomk/MongoMK.java (working copy)
@@ -29,6 +29,7 @@
import com.google.common.cache.CacheBuilder;
import com.google.common.cache.Weigher;
import com.mongodb.DB;
+
import org.apache.jackrabbit.mk.api.MicroKernel;
import org.apache.jackrabbit.mk.api.MicroKernelException;
import org.apache.jackrabbit.mk.blobs.BlobStore;
@@ -45,7 +46,9 @@
import org.apache.jackrabbit.oak.commons.PathUtils;
import org.apache.jackrabbit.oak.plugins.mongomk.Node.Children;
import org.apache.jackrabbit.oak.plugins.mongomk.blob.MongoBlobStore;
+import org.apache.jackrabbit.oak.plugins.mongomk.util.LoggingDocumentStoreWrapper;
import org.apache.jackrabbit.oak.plugins.mongomk.util.Utils;
+import org.apache.jackrabbit.oak.plugins.sqlpersistence.SQLDocumentStore;
import static com.google.common.base.Preconditions.checkNotNull;
@@ -714,7 +717,9 @@
public DocumentStore getDocumentStore() {
if (documentStore == null) {
- documentStore = new MemoryDocumentStore();
+ documentStore = new SQLDocumentStore();
+ // documentStore = new LoggingDocumentStoreWrapper(new SQLDocumentStore());
+ // documentStore = new MemoryDocumentStore();
}
return documentStore;
}
> DocumentStore implementation for SQL databases
> ----------------------------------------------
>
> Key: OAK-1266
> URL: https://issues.apache.org/jira/browse/OAK-1266
> Project: Jackrabbit Oak
> Issue Type: New Feature
> Components: mongomk
> Reporter: Julian Reschke
> Assignee: Julian Reschke
> Fix For: 1.0
>
>
> There should be an alternative DocumentStore implementation that persists to SQL databases rather than MongoDB.
--
This message was sent by Atlassian JIRA
(v6.1.4#6159)