mirror of https://github.com/OpenIdentityPlatform/OpenDJ.git

boli
23.50.2007 9f63f0439a36954ce46507cbc0059135f3fff56f
opendj-sdk/opends/src/server/org/opends/server/backends/jeb/EntryContainer.java
@@ -1521,8 +1521,6 @@
        }
      }
      // Increment the entry count.
      id2entry.adjustRecordCount(txn, 1);
    }
    /**
@@ -2021,8 +2019,6 @@
      id2cBuffered.flush();
      id2sBuffered.flush();
      // Decrement the entry count.
      id2entry.adjustRecordCount(txn, -getDeletedEntryCount());
    }
    /**
@@ -3253,7 +3249,7 @@
   */
  public long getEntryCount() throws DatabaseException
  {
    return id2entry.getRecordCount(null);
    return id2entry.getRecordCount();
  }
  /**
@@ -3538,15 +3534,18 @@
    // DATABASE_READ/DATABASE_WRITE
    StringBuilder builder = new StringBuilder();
    builder.append(operation);
    if (status == OperationStatus.SUCCESS)
    if(status != null)
    {
      builder.append(" (ok)");
    }
    else
    {
      builder.append(" (");
      builder.append(status.toString());
      builder.append(")");
      if (status == OperationStatus.SUCCESS)
      {
        builder.append(" (ok)");
      }
      else
      {
        builder.append(" (");
        builder.append(status.toString());
        builder.append(")");
      }
    }
    builder.append(" db=");
    builder.append(database.getDatabaseName());
@@ -3737,6 +3736,21 @@
  }
  /**
   * Get the count of key/data pairs in the database in a JE database.
   * This is a simple wrapper around the JE Database.count method.
   * @param database the JE database handle.
   * @return The count of key/data pairs in the database.
   * @throws DatabaseException If an error occurs in the JE operation.
   */
  public static long count(Database database) throws DatabaseException
  {
    long count = database.count();
    assert debugAccess("count", DATABASE_READ, null, database,
        null, null, null);
    return count;
  }
  /**
   * Remove a database from disk.
   *
   * @param name The short database name, to which the entryContainer name will