Package org.xtreemfs.babudb.config

Examples of org.xtreemfs.babudb.config.ConfigBuilder


     */
    public static void main(String[] args) throws BabuDBException {
       
        System.out.println("Setting up the BabuDB instances ... ");
       
        ConfigBuilder builder0 = new ConfigBuilder();
        builder0.setDataPath("/tmp/babudb0", "/tmp/babudb0/log").setLogAppendSyncMode(SyncMode.SYNC_WRITE);
        builder0.addPlugin("myBabuDBPath/pluginConfig0.properties");
        BabuDBConfig config0 = builder0.build();

        ConfigBuilder builder1 = new ConfigBuilder();
        builder1.setDataPath("/tmp/babudb1", "/tmp/babudb1/log").setLogAppendSyncMode(SyncMode.SYNC_WRITE);
        builder1.addPlugin("myBabuDBPath/pluginConfig1.properties");
        BabuDBConfig config1 = builder1.build();

        BabuDB babuDB0 = BabuDBFactory.createBabuDB(config0);
        BabuDB babuDB1 = BabuDBFactory.createBabuDB(config1);
       
        System.out.println("Creating database \"myDatabase\" ... ");
View Full Code Here


     *             if an error occurs while dumping the database
     */
    public static void dumpDB(String dbDir, String logDir, boolean compression, RecordFormatter formatter,
        PrintStream out) throws BabuDBException {
       
        BabuDB databaseSystem = BabuDBFactory.createBabuDB(new ConfigBuilder().setDataPath(dbDir, logDir)
                .setCompressed(compression).build());
       
        out.println("<BabuDB version=\"" + BabuDBFactory.BABUDB_VERSION + "\">");
       
        Map<String, Database> dbs = databaseSystem.getDatabaseManager().getDatabases();
View Full Code Here

TOP

Related Classes of org.xtreemfs.babudb.config.ConfigBuilder

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.