On 10/10/22 01:57, Satya Nand wrote:
*"Do not add the shards parameter to the standard request handler; doing so
may cause search queries may enter an infinite loop. Instead, define a new
request handler that uses the shards parameter, and pass distributed search
requests to that handler."*
so, How can we use shards parameters in solr config to limit the shards? I
think one alternative will be to pass the shards parameter in URL instead
of solrconfig.
But we would want to use the solrconfig to limit the changes in config only.
The standard request handler is usually the one named "/select". You may
want to add a new handler for this purpose.
Your message subject says you are in cloud mode. If that is true, I
think you are going to want to specify shards by name, not URL. If you
are in standalone mode (no zookeeper) then the way I handled that was to
build a special core with an empty index that had a predefined list of
shard URLs in the /select handler. When I did that, I was using the
"defaults" parameter config. I think if I did it again I would use
"invariants" so the user would not be able to override the list.
Thanks,
Shawn