Package org.apache.jackrabbit.mongomk.impl

Examples of org.apache.jackrabbit.mongomk.impl.MongoNodeStore


                                .pop().get());

        for (int i = 0; i < mksNumber; i++) {
            mongoConnection = new MongoConnection(conf.getHost(),
                    conf.getMongoPort(), conf.getMongoDatabase());
            MongoNodeStore nodeStore = new MongoNodeStore(
                    mongoConnection.getDB());
            // MongoAssert.setNodeStore(nodeStore);
            BlobStore blobStore = new MongoGridFSBlobStore(
                    mongoConnection.getDB());
            mks.add(new MongoMicroKernel(mongoConnection, nodeStore, blobStore));
View Full Code Here


        DBCollection statsCollection = mongoConnection.getDB().getCollection("statistics");
        statsCollection.insert(new Stats[] { commitStats, getNodesStats }, WriteConcern.NONE);
    }

    private void initMicroKernel() throws Exception {
        NodeStore nodeStore = new MongoNodeStore(mongoConnection.getDB());
        BlobStore blobStore = new BlobStoreFS(System.getProperty("java.io.tmpdir"));
        microKernel = new MongoMicroKernel(mongoConnection, nodeStore, blobStore);
    }
View Full Code Here

    private void initHandler() {
        this.handler = new ContinousHandler();
    }

    private void initMicroKernel() throws Exception {
        NodeStore nodeStore = new MongoNodeStore(mongoConnection.getDB());
        BlobStore blobStore = new BlobStoreFS(System.getProperty("java.io.tmpdir"));
        microKernel = new MongoMicroKernel(mongoConnection, nodeStore, blobStore);
    }
View Full Code Here

        MongoConnection connection = new MongoConnection(host, port, db);
        DB mongoDB = connection.getDB();

        logger.info("Connected to database {}", mongoDB);

        MongoNodeStore nodeStore = new MongoNodeStore(mongoDB);
        MongoGridFSBlobStore blobStore = new MongoGridFSBlobStore(mongoDB);
        MongoMicroKernel mk = new MongoMicroKernel(connection, nodeStore, blobStore);

        Properties props = new Properties();
        props.setProperty("oak.mk.type","mongo");
View Full Code Here

    public static MicroKernel mk;

    @Before
    public void setUp() throws Exception {
        DB db = mongoConnection.getDB();
        MongoNodeStore nodeStore = new MongoNodeStore(db);
        MongoAssert.setNodeStore(nodeStore);
        BlobStore blobStore = new MongoGridFSBlobStore(db);
        mk = new MongoMicroKernel(mongoConnection, nodeStore, blobStore);
    }
View Full Code Here

    public void setupMicroKernels() throws Exception {
        mongoConnection2.getDB().dropDatabase();
        // DB1 handled by the AbstractMongoConnectionTest

        DB db = mongoConnection.getDB();
        mk1 = new MongoMicroKernel(mongoConnection, new MongoNodeStore(db),
                new MongoGridFSBlobStore(db));

        DB db2 = mongoConnection2.getDB();
        mk2 = new MongoMicroKernel(mongoConnection2, new MongoNodeStore(db2),
                new MongoGridFSBlobStore(db2));

        DB db3 = mongoConnection3.getDB();
        mk3 = new MongoMicroKernel(mongoConnection3, new MongoNodeStore(db3),
                new MongoGridFSBlobStore(db3));
    }
View Full Code Here

            String diff = buildPyramidDiff("/", 0, numberOfChildren,
                    numberOfNodes, prefixes[i], new StringBuilder()).toString();
            //System.out.println(diff);
            DB db = mongoConnection.getDB();
            MongoMicroKernel mk = new MongoMicroKernel(mongoConnection,
                    new MongoNodeStore(db), new MongoGridFSBlobStore(db));
            GenericWriteTask task = new GenericWriteTask("mk-" + i, mk, diff, 10);
            executor.execute(task);
        }
        executor.shutdown();
        executor.awaitTermination(10, TimeUnit.MINUTES);
View Full Code Here

    public void setUpCluster(MicroKernel[] cluster) throws Exception {
        MongoConnection connection = getMongoConnection();
        DB db = connection.getDB();
        dropCollections(db);

        MongoNodeStore nodeStore = new MongoNodeStore(db);
        BlobStore blobStore = getBlobStore(db);
        MicroKernel mk = new MongoMicroKernel(connection, nodeStore, blobStore);

        for (int i = 0; i < cluster.length; i++) {
            cluster[i] = mk;
View Full Code Here

TOP

Related Classes of org.apache.jackrabbit.mongomk.impl.MongoNodeStore

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.