lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Shai Erera (JIRA)" <>
Subject [jira] [Updated] (LUCENE-3139) LuceneTestCase.afterClass does not print enough information if a temp-test-dir fails to delete
Date Wed, 25 May 2011 07:57:47 GMT


Shai Erera updated LUCENE-3139:

    Attachment: LUCENE-3139.patch

Patch fixes MockIndexOutputWrapper to always call delegate.close().

On the way, I fixed TestPersistentSnapshotDeletionPolicy to always close the PSDP, as well
as fixed a "leak" in PSDP itself.

I will commit this one. There are still tests that fail to delete directories, but I think
we should iterate on them separately, as all seem to be related to how MockIOWrapper handles
those maybeThrowDeterminsticEx. I'll send a separate mail.

This issue is about fixing LTC so that it outputs more information about directories that
fail to delete. You can simulate failures, on Windows, by running tests w/,
then track the stacktraces that are printed.

> LuceneTestCase.afterClass does not print enough information if a temp-test-dir fails
to delete
> ----------------------------------------------------------------------------------------------
>                 Key: LUCENE-3139
>                 URL:
>             Project: Lucene - Java
>          Issue Type: Test
>          Components: general/test
>            Reporter: Shai Erera
>            Priority: Minor
>             Fix For: 3.2, 4.0
>         Attachments: LUCENE-3139.patch, LUCENE-3139.patch, LUCENE-3139.patch
> I've hit an exception from LTC.afterClass when _TestUtil.rmDir failed (on write.lock,
as if some test did not release resources). However, I had no idea which test caused that
(i.e. opened the temp directory and did not release resources).
> I think we should do the following:
> * Track in LTC a map from dirName -> StackTraceElement
> * In afterClass if _TestUtil.rmDir fails, print the STE of that particular dir, so we
know where was this directory created from
> * Make tempDirs private and create accessor method, so that we control the inserts to
this map (today the Set is updated by LTC, _TestUtils and TestBackwards !)

This message is automatically generated by JIRA.
For more information on JIRA, see:

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message