[
https://issues.apache.org/jira/browse/CLEREZZA-564?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Daniel Spicar updated CLEREZZA-564:
-----------------------------------
Attachment: ZZ-564-rdf.cris.core-optimize-20110622-patch.diff
Attached a patch:
- removed optimize call upon closing the IndexWriter (it should not be done
then as the IndexWriter should be closed more often than it has been done until
now - until now it has been only called when the entire GraphIndexer has been
closed, like when deactivating the service that uses it.)
- new optimizeIndex method in LuceneTools starting a thread that optimizes the
index. While the index is being indexed the following is inhibited: closing the
IndexWriter, creating new IndexSearchers, running optimizeIndex (again).
There is no facility to schedule optimizations. You can run an optimization per
script when the service using the GraphIndexer offers a corresponding
interface. Here is an example for doing this with the
platform.cris.IndexService:
(scala script):
import org.apache.clerezza.platform.cris.IndexService
val is = $[IndexService]
is.optimizeIndex
Alternatively the Service using the GraphIndexer could make use of some
Scheduling mechanism to schedule optimizations repeatedly.
> CRIS: call optimize in an extra thread
> --------------------------------------
>
> Key: CLEREZZA-564
> URL: https://issues.apache.org/jira/browse/CLEREZZA-564
> Project: Clerezza
> Issue Type: Improvement
> Reporter: Tsuyoshi Ito
> Attachments: ZZ-564-rdf.cris.core-optimize-20110622-patch.diff
>
>
> Comment from Tommaso (see
> http://mail-archives.apache.org/mod_mbox/incubator-clerezza-dev/201106.mbox/%[email protected]%3E)
> A possible enhancement could be to create an OptimizeThread with a
> timeInterval constructor which optimizes the index, if there is not "much"
> activity (i.e.: analyze isLocked, InfoStream, etc), every timeInterval
> seconds.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira