Package com.sleepycat.db

Examples of com.sleepycat.db.DbEnv


* @version $Revision: 1.1 $
*/
public class BDbQueueMessageContainerTest extends MessageContainerTestSupport {

    protected PersistenceAdapter createPersistenceAdapter() throws Exception {
        DbEnv env = createEnvironment();
        return new BDbPersistenceAdapter(env);
    }
View Full Code Here


* @version $Revision: 1.1 $
*/
public class BDbQueueMessageContainerTest extends MessageContainerTestSupport {

    protected PersistenceAdapter createPersistenceAdapter() throws Exception {
        DbEnv env = createEnvironment();
        return new BDbPersistenceAdapter(env);
    }
View Full Code Here

* @version $Revision: 1.1 $
*/
public class BDbQueueMessageContainerTest extends MessageContainerTestSupport {

    protected PersistenceAdapter createPersistenceAdapter() throws Exception {
        DbEnv env = createEnvironment();
        return new BDbPersistenceAdapter(env);
    }
View Full Code Here

    private static ThreadLocal threadLocalTxn = new ThreadLocal();
    public static final int TRANSACTION_FLAGS = Db.DB_TXN_SYNC;
    private static DbEnv cachedEnvironment;

    public static DbEnv createEnvironment(File dir, boolean runRecovery) throws DbException, FileNotFoundException {
        DbEnv env = new DbEnv(0);

        // Open the Berkeley DB environment in transactional mode.
        int envFlags = Db.DB_INIT_TXN | Db.DB_INIT_LOCK | Db.DB_INIT_LOG | Db.DB_INIT_MPOOL |
                Db.DB_CREATE;

        if (runRecovery) {
            envFlags |= Db.DB_RECOVER;
        }
        env.open(dir.getPath(), envFlags, 0);
        return env;
    }
View Full Code Here

    private static ThreadLocal threadLocalTxn = new ThreadLocal();
    public static final int TRANSACTION_FLAGS = Db.DB_TXN_SYNC;
    private static DbEnv cachedEnvironment;

    public static DbEnv createEnvironment(File dir, boolean runRecovery) throws DbException, FileNotFoundException {
        DbEnv env = new DbEnv(0);

        // Open the Berkeley DB environment in transactional mode.
        int envFlags = Db.DB_INIT_TXN | Db.DB_INIT_LOCK | Db.DB_INIT_LOG | Db.DB_INIT_MPOOL |
                Db.DB_CREATE;

        if (runRecovery) {
            envFlags |= Db.DB_RECOVER;
        }
        env.open(dir.getPath(), envFlags, 0);
        return env;
    }
View Full Code Here

TOP

Related Classes of com.sleepycat.db.DbEnv

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.