Package com.sleepycat.je.tree

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


                 * we can check whether the lock owner's abort LSN is greater
                 * than the log LSN; if so, the log LSN is obsolete.  Before
                 * doing this we must release all latches to avoid a deadlock.
     */
                if (parentDIN != null) {
                    parentDIN.releaseLatch();
                    parentDIN = null;
                }
                bin.releaseLatch();
    long abortLsn = locker.getOwnerAbortLsn(nodeId);
    if (abortLsn != DbLsn.NULL_LSN &&
View Full Code Here


            dupRoot.latch();
      releaseBIN();
            DupCountLN dupCountLN = (DupCountLN)
                dupRoot.getDupCountLNRef().fetchTarget(database, dupRoot);
            /* We can't hold latches when we acquire locks. */
            dupRoot.releaseLatch();
            getReadLock(dupCountLN, LockType.READ);
            dupRootCount = dupCountLN.getDupCount();
        } else {
      releaseBIN();
        }
View Full Code Here

             * duplicate tree, we also have to update the duplicate tree count.
             */
            ChildReference dupCountRef = dupRoot.getDupCountLNRef();
            DupCountLN dcl = (DupCountLN)
                dupCountRef.fetchTarget(database, dupRoot);
            dupRoot.releaseLatch();
            LockResult dclGrantAndInfo = locker.lock
                (dcl.getNodeId(), LockType.WRITE, database);
            /*
             * The write lock request might have blocked while waiting for a
View Full Code Here

      assert dcl.getDupCount() >= 0;
            EnvironmentImpl envImpl = database.getDbEnvironment();
            long dupCountLsn =
                dcl.log(envImpl, database.getId(), dupKey, oldDclLsn, locker);
            dupRoot.updateDupCountLNRef(dupCountLsn);
            dupRoot.releaseLatch();

            locker.addDeleteInfo(dupBin, new Key(lnKey));
        } else {
            locker.addDeleteInfo(bin, new Key(lnKey));
        }
View Full Code Here

                releaseBIN();
                DupCountLN dupCountLN = (DupCountLN)
                    dupRoot.getDupCountLNRef().fetchTarget(database, dupRoot);

                /* We can't hold latches when we acquire locks. */
                dupRoot.releaseLatch();

                /*
                 * Call lock directly.  There is no need to call lockLN because
                 * the node ID cannot change (a slot cannot be reused) for a
                 * DupCountLN.
 
View Full Code Here

            releaseBINs();

            if (isDup) {
                dupRoot.incrementDuplicateCount
                    (dclLockResult, dupKey, locker, false /*increment*/);
                dupRoot.releaseLatch();
                dupRoot = null;

                locker.addDeleteInfo(dupBin, new Key(lnKey));
            } else {
                locker.addDeleteInfo(bin, new Key(lnKey));
View Full Code Here

                                DupCountLN dcl = duplicateRoot.getDupCountLN();
                                if (dcl != null) {
                                    dcl.accumulateStats(treeStatsAccumulator);
                                }
                            } finally {
                                duplicateRoot.releaseLatch();
                            }
                        } finally {
                            releaseBIN();
                        }
                    }
View Full Code Here

                            duplicateRoot.
                                updateDupCountLNRefAndNullTarget(abortLsn);
                            replaced = true;
                        }
                    } finally {
                        duplicateRoot.releaseLatch();
                    }
    }
            } else {
                if (found) {
                    /* This LN is in the tree. See if it needs replacing. */
 
View Full Code Here

                DupCountLN dupCountLN = (DupCountLN)
                    dupRoot.getDupCountLNRef().fetchTarget(databaseImpl,
                                                           dupRoot);

                /* We can't hold latches when we acquire locks. */
                dupRoot.releaseLatch();

                /*
                 * Call lock directly.  There is no need to call lockLN because
                 * the node ID cannot change (a slot cannot be reused) for a
                 * DupCountLN.
 
View Full Code Here

            releaseBINs();

            if (isDup) {
                dupRoot.incrementDuplicateCount
                    (dclLockResult, dupKey, locker, false /*increment*/);
                dupRoot.releaseLatch();
                dupRootIsLatched = false;
                dupRoot = null;

                locker.addDeleteInfo(dupBin, new Key(lnKey));
            } else {
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.