Examples of releaseLatch()


Examples of com.sleepycat.je.tree.BIN.releaseLatch()

      try {
    bin = (BIN) DbInternal.dbGetDatabaseImpl(exampleDb)
        .getTree()
        .getFirstNode();
    DIN dupRoot = (DIN) bin.fetchTarget(0);
    bin.releaseLatch();
    bin = null;
    dupRoot.latch();
    bin = (BIN) DbInternal.dbGetDatabaseImpl(exampleDb)
        .getTree()
        .getFirstNode(dupRoot);
View Full Code Here

Examples of com.sleepycat.je.tree.BIN.releaseLatch()

    dupRoot.latch();
    bin = (BIN) DbInternal.dbGetDatabaseImpl(exampleDb)
        .getTree()
        .getFirstNode(dupRoot);
    bin.compress(null, true);
    bin.releaseLatch();
    bin = null;

    Cursor cursor = exampleDb.openCursor(null, null);
    DatabaseEntry foundKey = new DatabaseEntry();
    DatabaseEntry foundData = new DatabaseEntry();
View Full Code Here

Examples of com.sleepycat.je.tree.BIN.releaseLatch()

               LockMode.DEFAULT);
    cursor.close();
    assertEquals(OperationStatus.SUCCESS, status);
      } finally {
    if (bin != null) {
        bin.releaseLatch();
    }
      }
  }
    }
View Full Code Here

Examples of com.sleepycat.je.tree.BIN.releaseLatch()

  idx = din.findEntry("yrhwlvlgvq".getBytes(), false, true);
  DBIN dbin = (DBIN) din.getTarget(idx);
  Key.DUMP_BINARY = false;
  dbin.log(envImpl.getLogManager());
  din.log(envImpl.getLogManager());
  bin.releaseLatch();
  env.compress();
  bin.log(envImpl.getLogManager());
    }
}
View Full Code Here

Examples of com.sleepycat.je.tree.BIN.releaseLatch()

            DatabaseImpl db =
    env.getDbMapTree().getDb(binRef.getDatabaseId(), lockTimeout);
      BIN bin = searchForBIN(db, binRef);
      if (bin != null) {
    bin.verifyCursors();
    bin.releaseLatch();
      }
  }
    }

    /**
 
View Full Code Here

Examples of com.sleepycat.je.tree.BIN.releaseLatch()

                        /*
                         * Release the bin latch taken by the initial
                         * search. Pruning starts from the top of the tree
                         * and requires that no latches are held.
                         */
                        foundBin.releaseLatch();
                       
                        pruneBIN(binSearch.db,  binRef, idKey, isDBIN,
                                 dupKey, tracker);
                    }
                }
View Full Code Here

Examples of com.sleepycat.je.tree.BIN.releaseLatch()

    if (!bin.isEntryKnownDeleted(index)) {
                    /* If fetchTarget returns null, a deleted LN was cleaned. */
                    node = bin.fetchTarget(index);
                }
                if (node == null) {
        bin.releaseLatch();
        return null;
    }
                if (node.containsDuplicates()) {
                    /* It's a duplicate tree. */
                    duplicateRoot = (DIN) node;
View Full Code Here

Examples of com.sleepycat.je.tree.BIN.releaseLatch()

    }
                if (node.containsDuplicates()) {
                    /* It's a duplicate tree. */
                    duplicateRoot = (DIN) node;
                    duplicateRoot.latch();
                    bin.releaseLatch();
                    duplicateBin = (DBIN) tree.searchSubTree
                        (duplicateRoot, dupKey, SearchType.NORMAL, -1, null,
                         false /*updateGeneration*/);

                    return duplicateBin;
View Full Code Here

Examples of com.sleepycat.je.tree.BIN.releaseLatch()

                    /* We haven't migrated to a duplicate tree yet.
                     * XXX, isn't this taken care of above? */
                    return bin;
                }
            } else {
                bin.releaseLatch();
                return null;
            }
        } catch (DatabaseException DBE) {
            if (bin != null) {
                bin.releaseLatchIfOwner();
View Full Code Here

Examples of com.sleepycat.je.tree.BIN.releaseLatch()

      if (index == -1) {
    return false;
      }
      return true;
  } finally {
      bin.releaseLatch();
      TestUtils.checkLatchCount();
  }
    }

    protected OperationStatus putAndVerifyCursor(Cursor cursor, StringDbt key,
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.