I think you should extend the Directory class to provide a direct access
to the zip file in which the index is stored, and then use that
implementation with IndexWriter and IndexSearcher.

----------------------------------------------------
Waleed Tayea

-----Original Message-----
From: Ahmed El-dawy [mailto:[EMAIL PROTECTED] 
Sent: Sunday, February 19, 2006 9:06 AM
To: java-user@lucene.apache.org
Subject: Re: Accessing Lucene Index stored in a jar file

I need to access it as it is in the zip file. IndexSearcher cannot be
constructed using a zip file or a stream to a file. It can be
constructed to either FSDirectory or RAMDirectory. Both are not useful
in my case.

On 2/19/06, gekkokid <[EMAIL PROTECTED]> wrote:
> couldnt you use the java zip library
>
(http://java.sun.com/j2se/1.5.0/docs/api/java/util/zip/package-summary.h
tml)
> and compress and uncompress it separately? just an idea
>
> ----- Original Message -----
> From: "Ahmed El-dawy" <[EMAIL PROTECTED]>
> To: <java-user@lucene.apache.org>
> Sent: Saturday, February 18, 2006 8:38 PM
> Subject: Accessing Lucene Index stored in a jar file
>
>
> Hello,
>   Is there a way to access a Lucene Index which is stored inside a
> .zip or .jar file?
> This is important because my indexes are very large (> 200 M.B.) and I
> need to compress them. I tried to store documents using
> Store.COMPRESSED, but the compression ratio wasn't satisfying.
>   I need to add the index to a jar file and access it (for read-only)
> without extracting the zip file.
>
> Thanks in advance
> --
> regards,
> Ahmed Saad
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
>
>


--
regards,
Ahmed Saad

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to