You are viewing a plain text version of this content. The canonical link for it is here.
Posted to solr-user@lucene.apache.org by Li Li <fa...@gmail.com> on 2010/07/27 04:48:55 UTC

Is there a cache for a query?

I want a cache to cache all result of a query(all steps including
collapse, highlight and facet).  I read
http://wiki.apache.org/solr/SolrCaching, but can't find a global
cache. Maybe I can use external cache to store key-value. Is there any
one in solr?

Re: Is there a cache for a query?

Posted by Moazzam Khan <mo...@gmail.com>.
As far as I know all searches get cache at least for some time. I am
not sure about field collapse results being cached.

- Moazzam
http://moazzam-khan.com



On Mon, Jul 26, 2010 at 9:48 PM, Li Li <fa...@gmail.com> wrote:
> I want a cache to cache all result of a query(all steps including
> collapse, highlight and facet).  I read
> http://wiki.apache.org/solr/SolrCaching, but can't find a global
> cache. Maybe I can use external cache to store key-value. Is there any
> one in solr?
>

Re: Is there a cache for a query?

Posted by Chris Hostetter <ho...@fucit.org>.
: I want a cache to cache all result of a query(all steps including
: collapse, highlight and facet).  I read
: http://wiki.apache.org/solr/SolrCaching, but can't find a global
: cache. Maybe I can use external cache to store key-value. Is there any
: one in solr?

One of SOlr's design principles is that it only bothers to cache things 
internally if those things are going to be useful for multiple requests -- 
because those are things that can *only* be cached internally.  ie: the 
filterCache caches filters thta might be used in other requests 
with different queries, the queryResultsCache caches query results that 
might be used in other requests with different rows/fl params, the 
documentCache caches documents that might be used in other requests with 
differnet ... anything.  In all of those cases, Solr does the caching 
because there is no way something external to Solr could do it.

Solr isn't likely to ever have a cache that caches the entire result 
for a request.  At that point the only time that result is going 
to be useful is for an identical request, and an external system -- 
specificly an HTTP Cache like Squid or Varnish (or if you are using 
Embedded Solr, some other cache) is in an even better position to deal 
with it.




-Hoss