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 Dan Funk <da...@gmail.com> on 2005/12/09 17:51:25 UTC

exporting and importing Lucene documents

We build indexes, then share those indexes (along with files and database
records) with our client installations.

 We now have multiple clients, and they are beginning to say things like,
"I'd like this group of documents here, and this little bit over here, and
ah .... yea that document there too, but not all that other stuff." Damn
clients.

We need to keep our installation simple and fairly idiot proof.  I don't
want them to spend hours/days building indexes at installation time.

What I would like to do is have a primary index with all documents pre-build
at our office, then pull select lucene documents out of that index, and
build a second that would be ready to send to our client.  Is this going to
be any more efficient than just building a new index from scratch?  Is there
a better method?  Such as duplicating the index and deleting ids that I
don't want in the new index?

Thanks,

Dan

Re: exporting and importing Lucene documents

Posted by Chris Hostetter <ho...@fucit.org>.
as long as the you are interested in doing things at document granularity
(and not on a field granularity - ie: some clients want certain fields,
and others don't) then you can use a combination of composition from small
indexes, and deleting of unwanted data.

without understanding exactly what kidns of critera your clients are
talking about when they say "i want this and this and this but not that"
it's hard to know exactly what would be best for you, but assuming it's
and index of books that have categorization and publication years
you could easily do something like build a seperate index for each year,
then use create a new index for each client in which you call
IndexWriter.addIndexes(Directory) on the set of year specific indexes they
want, and then use IndexReader.delete(Term) to throw out books in
categories they don't like.



: Date: Fri, 9 Dec 2005 16:51:25 +0000
: From: Dan Funk <da...@gmail.com>
: Reply-To: java-user@lucene.apache.org
: To: java-user@lucene.apache.org
: Subject: exporting and importing Lucene documents
:
: We build indexes, then share those indexes (along with files and database
: records) with our client installations.
:
:  We now have multiple clients, and they are beginning to say things like,
: "I'd like this group of documents here, and this little bit over here, and
: ah .... yea that document there too, but not all that other stuff." Damn
: clients.
:
: We need to keep our installation simple and fairly idiot proof.  I don't
: want them to spend hours/days building indexes at installation time.
:
: What I would like to do is have a primary index with all documents pre-build
: at our office, then pull select lucene documents out of that index, and
: build a second that would be ready to send to our client.  Is this going to
: be any more efficient than just building a new index from scratch?  Is there
: a better method?  Such as duplicating the index and deleting ids that I
: don't want in the new index?
:
: Thanks,
:
: Dan
:



-Hoss


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