You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@lucene.apache.org by Eran Sevi <er...@gmail.com> on 2008/03/19 14:54:44 UTC

Multi process writer access to an index

Hi,


I'm trying to write to a specific index from several different processes and
encounter problems with locked files (deletable for example).

I don't perform any specific locking because as I understand it there should
be file-specific locking mechanism used by lucene API. This doesn't seem to
be working as I am able to instantiate an IndexWriter on the same index
simultaneously, but I encounter problems when I try to close/optimize it .



Please help me understand if lucene doesn't support this kind of access, and
what's the proper way to write to the same index from two or more different
processes/computers.



Thanks,

Eran S.

Re: Multi process writer access to an index

Posted by Erick Erickson <er...@gmail.com>.
You'll get more meaningful answers if you provide some details:
Things that come to mind:

op system (windows? *nix?)

file system (NFS? local? NTFS?)

An example of the error you receive (a stack trace would be good).

The code you're executing when you get the error.

Imagine you're trying to advise someone else and think about
what you'd find useful and try to provide that, please.

Best
Erick


On Wed, Mar 19, 2008 at 9:54 AM, Eran Sevi <er...@gmail.com> wrote:

> Hi,
>
>
> I'm trying to write to a specific index from several different processes
> and
> encounter problems with locked files (deletable for example).
>
> I don't perform any specific locking because as I understand it there
> should
> be file-specific locking mechanism used by lucene API. This doesn't seem
> to
> be working as I am able to instantiate an IndexWriter on the same index
> simultaneously, but I encounter problems when I try to close/optimize it .
>
>
>
> Please help me understand if lucene doesn't support this kind of access,
> and
> what's the proper way to write to the same index from two or more
> different
> processes/computers.
>
>
>
> Thanks,
>
> Eran S.
>