[hibernate-issues] [Hibernate-JIRA] Commented: (HSEARCH-135) Create a RAMDirectoryProvider from an existing Lucene FSDirectory

Hardy Ferentschik (JIRA) noreply at atlassian.com
Mon Dec 3 15:03:56 EST 2007


    [ http://opensource.atlassian.com/projects/hibernate/browse/HSEARCH-135?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_29030 ] 

Hardy Ferentschik commented on HSEARCH-135:
-------------------------------------------

Just want to get some feedback on the following idea. I would like to implement a custom DirectoryProvider where the Lucene Directory is backed up by two different Directory implementations. For index creation I want to use a FSDirectory and for use with a IndexReader I want to use a RAMDirectory. This way I get the best of both worlds. The FSDirectory in order to create a persistence index and the RAMDirectoy to speed up searches.

As far as I can see this should work without major complications, however at the moment DirectoryProvider has only one single method to retrieve the Directory - getDirectory(). I would need a way to retrieve the directory depending on the usecase. For example you could have an additional boolean flag, getDirectory(boolean write). Or you could have two different methods - getReaderDirectory() and getWriterDirectory(). 

Any comments?

> Create a RAMDirectoryProvider from an existing Lucene FSDirectory
> -----------------------------------------------------------------
>
>                 Key: HSEARCH-135
>                 URL: http://opensource.atlassian.com/projects/hibernate/browse/HSEARCH-135
>             Project: Hibernate Search
>          Issue Type: New Feature
>          Components: directory provider
>            Reporter: Hardy Ferentschik
>
> It would be nice to have the ability to use a Lucene RAM index which gets constucted from an existing Lucene file based indexed. For example in an JMS setup the master could create a file based Lucene index, share it out to the slaves which in turn use this file based index to populate a RAM index. This would give you the best of two worlds. 
> Not sure how hard it would be to implement this in an unclustered environment.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://opensource.atlassian.com/projects/hibernate/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        



More information about the hibernate-issues mailing list