| com.sleepycat.je.cleaner.CleanerTest
CleanerTest | public class CleanerTest extends TestCase (Code) | | |
CleanerTest | public CleanerTest()(Code) | | |
testCleanFileHole | public void testCleanFileHole() throws Throwable(Code) | | See if we can clean in the middle of the file set.
|
testCleanInternalNodes | public void testCleanInternalNodes() throws DatabaseException(Code) | | Ensure that INs are cleaned.
|
testCleanerStop | public void testCleanerStop() throws Throwable(Code) | | Tests that setting je.env.runCleaner=false stops the cleaner from
processing more files even if the target minUtilization is not met
[#15158].
|
testCleanerWithDupes | public void testCleanerWithDupes() throws Throwable(Code) | | |
testFileSummaryLNMemoryUsage | public void testFileSummaryLNMemoryUsage() throws DatabaseException(Code) | | Tests that memory is budgeted correctly for FileSummaryLNs that are
inserted and deleted after calling setTrackedSummary. The size of the
FileSummaryLN changes during logging when setTrackedSummary is called,
and this is accounted for specially in Tree.logLNAfterInsert. [#15831]
|
testMutableConfig | public void testMutableConfig() throws DatabaseException(Code) | | Tests that cleaner mutable configuration parameters can be changed and
that the changes actually take effect.
|
testSR13191 | public void testSR13191() throws Throwable(Code) | | Test for SR13191. This SR shows a problem where a MapLN is initialized
with a DatabaseImpl that has a null EnvironmentImpl. When the Database
gets used, a NullPointerException occurs in the Cursor code which
expects there to be an EnvironmentImpl present. The MapLN gets init'd
by the Cleaner reading through a log file and encountering a MapLN which
is not presently in the DbTree. As an efficiency, the Cleaner calls
updateEntry on the BIN to try to insert the MapLN into the BIN so that
it won't have to fetch it when it migrates the BIN. But this is bad
since the MapLN has not been init'd properly. The fix was to ensure
that the MapLN is init'd correctly by calling postFetchInit on it just
prior to inserting it into the BIN.
This test first creates an environment and two databases. The first
database it just adds to the tree with no data. This will be the MapLN
that eventually gets instantiated by the cleaner. The second database
is used just to create a bunch of data that will get deleted so as to
create a low utilization for one of the log files. Once the data for
db2 is created, the log is flipped (so file 0 is the one with the MapLN
for db1 in it), and the environment is closed and reopened. We insert
more data into db2 until we have enough .jdb files that file 0 is
attractive to the cleaner. Call the cleaner to have it instantiate the
MapLN and then use the MapLN in a Database.get() call.
|
testTrackerMemoryBudget | public void testTrackerMemoryBudget() throws DatabaseException(Code) | | Checks that the memory budget is updated properly by the
UtilizationTracker. Prior to a bug fix [#15505] amounts were added to
the budget but not subtracted when two TrackedFileSummary objects were
merged. Merging occurs when a local tracker is added to the global
tracker. Local trackers are used during recovery, checkpoints, lazy
compression, and reverse splits.
|
testUnexpectedFileDeletion | public void testUnexpectedFileDeletion() throws DatabaseException, IOException(Code) | | Tests that when a file being cleaned is deleted, we ignore the error and
don't repeatedly try to clean it. This is happening when we mistakedly
clean a file after it has been queued for deletion. The workaround is
to catch LogFileNotFoundException in the cleaner and ignore the error.
We're testing the workaround here by forcing cleaning of deleted files.
[#15528]
|
|
|