lucenenet-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Pauli Østerø (JIRA) <>
Subject [jira] Commented: (LUCENENET-113) adding documents to index does, in rare cases, cause an access denied to segments.gen
Date Sat, 19 Apr 2008 00:54:22 GMT


Pauli Østerø commented on LUCENENET-113:

Depends on if that is really the case. Seeing that Windows reports "DELETE PEND" and NOT (!)
ACCESS DENIED via FileMon confirms my suspecion that this is really not a File Access issue.
Looking into the directory after this error is thrown also reveals that the file doesn't exists.
This was actually was puzzled me the most at first, because how could .Net throw an Access
Denied error on a files thats really not there.

I have tried to find any component that might could have a lock on the files, but there is
no antivirus, no defragmenting programs, no nothing.

Seeing that this is exception is thrown only sometimes, and can be "solved" by doing a thread-sleep,
and thereby slowing down the process of deletion and creating the segments.gen file also raises
my suspecion to the lock-less method of updating an index. I can show you a dump of my FileMon
trace if it helps.

> adding documents to index does, in rare cases, cause an access denied to segments.gen
> -------------------------------------------------------------------------------------
>                 Key: LUCENENET-113
>                 URL:
>             Project: Lucene.Net
>          Issue Type: Bug
>         Environment: Windows 2003
> Lucene.Net
>            Reporter: Pauli Østerø
>            Priority: Critical
> When updating an index via an indexwriter, does cause an access denied for segments.gen.
> After investigation with FileMon the problem seems to be Lucene deleting and creating
the segments.gen with such a speed, that Windows occasionally reports "DELETE PEND" when trying
to open the file, which causes Lucene to crash.
> A quick fix has been to do a try-catch when adding documents, and sleeping the thread
for 100 ms when encountering the UnathorizedException and trying to add the document again.

This message is automatically generated by JIRA.
You can reply to this email to add a comment to the issue online.

View raw message