[
https://issues.apache.org/jira/browse/SOLR-4449?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15053711#comment-15053711
]
Jeff Wartes commented on SOLR-4449:
-----------------------------------
For what it's worth, if I were a solr committer, I probably wouldn't just merge
this issue as-is. BackupRequestLBHttpSolrClient still has a certain amount of
copy/paste code from the parent LBHttpSolrClient class that'd become extra
long-term maintenance load. (As it will be every time I update this issue for a
new solr version)
Instead, I'd do something like:
1. Pull the asynchronous ExecutorCompletionService-based query approach into
the LBHttpSolrClient itself. This would be interesting and useful functionality
in it's own right.
2. Add the concept of a shardTimeout. (Distinct from timeAllowed)
3. Add extendable support for how to handle a shardTimeout. If a strategy ends
up making a request to another server in the list, that request must be
submitted to the same ExecutorCompletionService so that in all cases,
LBHttpSolrClient would return the first response among the submitted requests.
4. The backup-request functionality could still then be a class extending
LBHttpSolrClient, but the only real code there would be defining the
shardTimeout for a given request, and how to handle a shardTimeout if there was
one.
I'd probably audit the access restrictions in LBHttpSolrClient while I was at
it though, since solrconfig.xml provides such an easy way to use alternate
implementations of that class. A lot of the existing code in
BackupRequestLBHttpSolrClient is only necessary due to not having sufficient
access to the parent class. (isTimeExceeded/getTimeAllowedInNanos seem
generally useful to have, for example, and I'm not sure why doRequest is
protected)
> Enable backup requests for the internal solr load balancer
> ----------------------------------------------------------
>
> Key: SOLR-4449
> URL: https://issues.apache.org/jira/browse/SOLR-4449
> Project: Solr
> Issue Type: New Feature
> Components: SolrCloud
> Reporter: philip hoy
> Priority: Minor
> Attachments: SOLR-4449.patch, SOLR-4449.patch, SOLR-4449.patch,
> patch-4449.txt, solr-back-request-lb-plugin.jar
>
>
> Add the ability to configure the built-in solr load balancer such that it
> submits a backup request to the next server in the list if the initial
> request takes too long. Employing such an algorithm could improve the latency
> of the 9xth percentile albeit at the expense of increasing overall load due
> to additional requests.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]