Package com.sleepycat.je.latch

Examples of com.sleepycat.je.latch.Latch


            configMgr.getBoolean(EnvironmentParams.LOCK_OLD_LOCK_EXCEPTIONS);
        lockTables = new Map[nLockTables];
        lockTableLatches = new Latch[nLockTables];
        for (int i = 0; i < nLockTables; i++) {
            lockTables[i] = new HashMap<Long,Lock>();
            lockTableLatches[i] = new Latch("Lock Table " + i);
        }
        this.envImpl = envImpl;
        memoryBudget = envImpl.getMemoryBudget();

        stats = new StatGroup(GROUP_NAME, GROUP_DESC);
View Full Code Here


        /* See if we're configured to do a checksum when reading in objects. */
        doChecksumOnRead =
            configManager.getBoolean(EnvironmentParams.LOG_CHECKSUM_READ);

        logWriteLatch = new Latch(DEBUG_NAME);
        readBufferSize =
            configManager.getInt(EnvironmentParams.LOG_FAULT_READ_SIZE);

        /* Do the stats definitions. */
        stats = new StatGroup(GROUP_NAME, GROUP_DESC);
View Full Code Here

                }
            }

            /* Cache of files. */
            fileCache = new FileCache(configManager);
            fileCacheLatch = new Latch(DEBUG_NAME + "_fileCache");

            /* Start out as if no log existed. */
            currentFileNum = 0L;
            nextAvailableLsn =
                DbLsn.makeLsn(currentFileNum, firstLogEntryOffset());
View Full Code Here

    FSyncManager(EnvironmentImpl envImpl) {
        timeout = envImpl.getConfigManager().getDuration
            (EnvironmentParams.LOG_FSYNC_TIMEOUT);
        this.envImpl = envImpl;

        fsyncLatch = new Latch("fsyncLatch");
        fsyncInProgress = false;
        nextFSyncWaiters = new FSyncGroup(timeout, envImpl);

        stats = new StatGroup(LogStatDefinition.FSYNCMGR_GROUP_NAME,
                              LogStatDefinition.FSYNCMGR_GROUP_DESC);
View Full Code Here

    /**
     * Creates a new handle but does not initialize it.  The init method must
     * be called before using the handle to access the file.
     */
    FileHandle(long fileNum, String label) {
        fileLatch = new Latch("file_" + label + "_fileHandle");
        this.fileNum = fileNum;
    }
View Full Code Here

    LogBuffer(int capacity, EnvironmentImpl env)
        throws DatabaseException {

        buffer = ByteBuffer.allocate(capacity);
        readLatch = new Latch(DEBUG_NAME);
        reinit();
    }
View Full Code Here

        startupTracker.start(Phase.TOTAL_ENV_OPEN);

        try {
            this.envHome = envHome;
            envState = DbEnvState.INIT;
            mapTreeRootLatch = new Latch("MapTreeRoot");
            exceptionListenerUsers = Collections.synchronizedSet
                (new HashSet<ExceptionListenerUser>());

            /* Do the stats definition. */
            stats = new StatGroup(ENV_GROUP_NAME, ENV_GROUP_DESC);
View Full Code Here

                  EnvironmentImpl envImpl)
        throws DatabaseException {

        this.fileManager = fileManager;
        this.envImpl = envImpl;
        bufferPoolLatch = new Latch(DEBUG_NAME + "_FullLatch");

        /* Configure the pool. */
        DbConfigManager configManager = envImpl.getConfigManager();
        runInMemory = envImpl.isMemOnly();
        reset(configManager);
View Full Code Here

                        int initialCapacity,
                        int level) {
        setDatabase(db);
  EnvironmentImpl env =
      (databaseImpl == null) ? null : databaseImpl.getDbEnvironment();
        latch = new Latch(shortClassName() + getNodeId(), env);
        generation = 0;
        dirty = false;
        nEntries = 0;
        this.identifierKey = identifierKey;
  entryTargets = new Node[initialCapacity];
View Full Code Here

    public DaemonThread(long waitTime, String name, EnvironmentImpl env) {
        this.waitTime = waitTime;
        this.name = name;
  this.env = env;
        workQueue = new HashSet();
        workQueueLatch = new Latch(name + " work queue", env);
    }
View Full Code Here

TOP

Related Classes of com.sleepycat.je.latch.Latch

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.