Hi all,

I'm trying Oak 1.2 after years on Jackrabbit, and I'm not sure to fully 
understand some of new concepts.

So I work on jUnit test to check all implementations: Segment and Document + 
BlogStore.
Should be easy but...I miss some points. I'm not using OSGi nor Mongodb.

Tests try to get a javax.jcr.Repository object for each combination, then, to 
be short:
. Login/logout
. Register CND/namespace
. Add a node hierarchy
. Add a File with properties
. Query with available languages (Jack had many (XPATH, SQL2..,) not yet on 
this step for Oak)


If I well-read documentation I have first to choose a NodeStore implementation 
either Segment or Document, then optionally a BlogStore, depending of first 
choice, lot of possibilities, but can't really find how to create each of them.

>From http://jackrabbit.apache.org/oak/docs/plugins/blobstore.html, could 
>someone help providing some information how with java code:
. Create a DocumentNodeStore using FileDataStore and FileBlobStore
. Create a DocumentNodeStore using S3DataStore

I got this for SegmentNodeStore, but can't find a way for DocumentNodeStore :

        @Test
        public void testSegmentNodeStoreWithFileBlobStore()
                        throws RepositoryException, IOException {
                File directory = new File("./target/SegmentStore");
                SegmentStore store = FileStore.newFileStore(directory)
                                .withBlobStore(new 
FileBlobStore("./target/FileBlobStore"))
                                .create();
                Repository repository = new Jcr(new Oak(new 
SegmentNodeStore(store)))
                                .createRepository();
                checkLogin(repository);
        }

Any information welcomed too.

Regards,
Fred

Reply via email to