: for performance reasons I cache Hits for a certain Query in memcached, for : things like pageination etc. My question right now is if it is possible to : re-search such a cached Hits sets. That would be great for features like : live-learch and so on. Does Lucene support that?
You can hang on to a Hits object as long as you want -- provided you don't close the search that created it -- but i really doubt caching it in something like memcached is going to work the way you expect, Hits instances keep a refrence to the IndexSearcher that created them so they can fetch additional documents as needed ... you will most likely encounter strange errors if you do this. it's typically "fast enough" to just reissue the search, and if it's not then you need a better data structure to put in yourcache then Hits -- one that you very explicitly populate with however much data you expect to need. (think of Hits like an Iterator that pre-fetches and internally caches some of the items it needs, but if you exhaust those first few items, the Iterator needs to keep getting the rest) -Hoss --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]