-- Bradley Holt <[EMAIL PROTECTED]> wrote (on Wednesday, 19 March 2008, 03:59 PM -0400): > I haven't done this but I don't see any reason why you couldn't simply > use Zend_Cache_Frontend_Class to cache the output of your Lucene > queries. I don't know if Zend_Search_Lucene has any built in caching, > though.
It doesn't. On the ZF site, I actually use Zend_Cache to cache search results, which comes in particularly handy for pagination (as subsequent requests don't require pulling a new resultset, but simply pulling from the cache). One note, however -- you can't cache the $hits returned directly. You need to pull out the data you need from each hit -- I store the data in an array of assoc arrays -- to cache it. If you try and cache the $hits directly, you'll get document not found exceptions on subsequent visits. > On Wed, Mar 19, 2008 at 3:30 PM, Eric Marden <[EMAIL PROTECTED]> > wrote: > > Can you cache Lucene Search Results? Is there another way to speed it up? -- Matthew Weier O'Phinney PHP Developer | [EMAIL PROTECTED] Zend - The PHP Company | http://www.zend.com/
