kee
kee

Reputation: 11629

How to stop certain results from being stored in FilterCache in Solr

I have been using some filters in multi-faceting queries in Solr. Right now the filters are using only value but now I have to expand it to multi-values and I think I have to use OR for that. I haven't done any performance checking but I am wondering if there is a way to stop my filter queries from being stored to FilterCache? I don't want to cache results from filter queries with more than two values. Ideally I guess I have to rely on caching algorithm doing a good job but I am just wondering.

Upvotes: 1

Views: 119

Answers (1)

favoretti
favoretti

Reputation: 30167

Taken from here.

To tell Solr not to cache a filter, we use the same powerful local params DSL that adds metadata to query parameters and is used to specify different types of query syntaxes and query parsers. For a normal query that does not have any localParam metadata, simply prepend a local param of cache=false.

Upvotes: 2

Related Questions