I just happened to be looking into this as well. I assume you've seen the
refguide documentation:
https://solr.apache.org/guide/8_11/query-settings-in-solrconfig.html#user-defined-caches

Normally one would not configure a user-defined cache except in support of
other custom plugins/components. e.g., if you have a custom
Query/QueryParser implementation that could internally benefit from
specialized caching strategies or something, in Query.createWeight(...) you
could cast the provided IndexSearcher to a SolrIndexSearcher (a safe cast
in most contexts), and use the SolrIndexSearcher to interact with your
custom cache by name.

Sorry if the response is a bit vague, I hope it's helpful nonetheless! If
you share more specifically what you're trying to do, this thread could
_become_ a discussion of a (theoretically) working example of user-defined
cache :-)

On Tue, Feb 15, 2022 at 2:42 PM rbs <rbs4...@gmail.com> wrote:

> Hi,
>
> I've looked and googled, but I have been unable to actually find a working
> example of User Defined Caches.
>
>
>
> I looking for something showing the basics how to define, implement and use
> as User Defined Cache.
>
>
>
> Is there one out there and I have just missed it??
>
>
>
> Thanks
>
>

Reply via email to