lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Pulkit Singhal <pulkitsing...@gmail.com>
Subject Re: IndexWriters and write locks
Date Wed, 10 Nov 2010 17:36:23 GMT
I do not actually take the trouble to specify what Lock Factory to use,
hmmm.

Are you suggesting that because I'm using FSDirectory.open() in my code, I
get a locking scheme that works ... while on other machine for other folks,
they get one that runs into issues and throws
java.nio.channels.OverlappingFileLockException?

- Pulkit

On Wed, Nov 10, 2010 at 11:21 AM, Michael McCandless <
lucene@mikemccandless.com> wrote:

> Likely you are using NativeFSLockFactory?
>
> In which case, a leftover lock file does not mean the index is in fact
> locked, since the OS will [correctly] release the lock on process
> exit.
>
> Mike
>
> On Wed, Nov 10, 2010 at 9:38 AM, Pulkit Singhal <pulkitsinghal@gmail.com>
> wrote:
> > Hello,
> >
> > 1) On Windows, I often shut down my application server (which has active
> > IndexWriters open) using the ctrl+c keys.
> > 2) I inspect my directories on the file system I see that the write.lock
> > file is still there.
> > 3) I start the app server again, and do some operations that would
> require
> > IndexWriters to write to the same directories again and it works!
> >
> > I don't understand why I do not run into any exceptions?
> > I mean there is already a lock file present which should prevent the
> > IndexWriters from getting access to the directories ... no?
> > I should be happy but I'm not because other folks are able to get
> exceptions
> > when they bounce their servers an I'm unable to reproduce the problem and
> I
> > can't help them.
> >
> > Any clues? Anyone?
> >
> > Thank You,
> > - Pulkit
> >
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: java-user-unsubscribe@lucene.apache.org
> For additional commands, e-mail: java-user-help@lucene.apache.org
>
>

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message