lucene-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Robert Engels" <reng...@ix.netcom.com>
Subject RE: Question about RemoteSearchable, RMI and queries in parallel
Date Thu, 13 Apr 2006 02:29:18 GMT
I think you may need a much more advanced design - with change detection,
parallel query execution, and index modification.

A lot of it depends on you semantics of a search - does it mean at the
results are 'almost right' at a moment in time, or are pending index changes
made first before any queries. How you define this will affect the
architecture greatly.


-----Original Message-----
From: wenjie zheng [mailto:wenjie.zheng@gmail.com]
Sent: Wednesday, April 12, 2006 8:45 PM
To: java-dev@lucene.apache.org
Subject: Question about RemoteSearchable, RMI and queries in parallel


My question is a little bit long. Thanks for your patience.

I am working on project which requires remote searching ability. So I use
RMI and RemoteSearchable class. Here is the system structure:
Server A has all the indices on it and the RemoteSearchable object running
on it. Server B accepts queries and use ParallelMultiSearcher  and RMI to
search the indices on Server A.
There are many indices on Server A, based on query I received, I choose
different index to search from .

For example, if I the query is from X, we will search indexX; if the query
is from Y, we will search indexY. In order to do that, I changed the
Searchable interface a little bit by adding function load(String folder) and
implement it in all the subclasses. What load() does is to close the
underlining reader of the first index and open the reader for the second
index.

So here is the problem I bumped into. When there are more than one queries
coming at the same time and I wanted to process them in parallel,  the
load() function called by the second query may accidently close the the
reader of the first index, while searching on the first index is not
finished yet.

So, do I have to queue the queries up and execute them one after the other?
Or do I have other options?

Thanks,
Wenjie


---------------------------------------------------------------------
To unsubscribe, e-mail: java-dev-unsubscribe@lucene.apache.org
For additional commands, e-mail: java-dev-help@lucene.apache.org


Mime
View raw message