lucene-java-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Paul <arach...@gmail.com>
Subject Beginner's questions
Date Wed, 27 Mar 2013 03:24:44 GMT
Hi All,

I've just begun to get my feet wet with Lucene and have a few simple questions:

1. Must the index writer read and index files on disk, or can i create documents in memory
and ask the writer to index them?

2. I think I've seen examples of the behavior I asked about in (1). In these examples the
addDocument method's Document argument is created on the fly (new Document(); document.add(String),
etc.). In such cases is it possible to continually update the index, e.g., because the index
source changes, I want to incorporate that change into the index? Let me try to give a practical
example of what I'm trying to say. The application has access to a proprietary database. This
DB is presently only in memory, not on disk. The application knows how to read parts of that
DB and can present them to Lucene for indexing. As the DB changes, I'd like to reflect those
changes in the index built by Lucene.

3. I guess there are 3 kinds of DB changes to consider: additions, deletions, and updates.
So, when a new element is added to the DB, I want to extract certain fields therefrom and
have them indexed. When a row is deleted, I'd want to tell the index that text it had indexed
is no longer valid, at least not at a certain location. And when a row is updated, I'd want
to replace a previously indexed value with its new value.

Forgive me if these questions are put a bit awkwardly. But, knowing little about Lucene, they're
about as coherent as I can make them.

Thank you.

-Paul










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


Mime
View raw message