[
https://issues.apache.org/jira/browse/SOLR-2809?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13120193#comment-13120193
]
Yonik Seeley commented on SOLR-2809:
------------------------------------
Distributed search already ensures that different phases of the same request go
to the same replicas, so the remainder of this patch should be pretty easy.
We just need a SolrQueryRequest.getSearcher() that checks the request
parameters. If there is a reserve=1000 parameter, then the reference count is
incremented an additional time, and is added to a map / priority queue (or
whatever a separate timing thread looks at to decrement the ref after the lease
is up), or updated if it already exists. A unique id for the searcher is
returned in the request header.
If the request params have "searcher=1294929223" then getSearcher() retrieves
that version from the map if the lease hasn't expired (and applies a new lease
if there is also a reserve param).
This seems nice and isolated from the rest of the solr code... no need to
modify any of the guts of the complex SolrCore.getSearcher()
> searcher leases
> ---------------
>
> Key: SOLR-2809
> URL: https://issues.apache.org/jira/browse/SOLR-2809
> Project: Solr
> Issue Type: New Feature
> Reporter: Yonik Seeley
>
> Leases/reservations on searcher instances would give us the ability to use
> the same searcher across phases of a distributed search, or for clients to
> send multiple requests and have them hit a consistent/unchanging view of the
> index. The latter requires something extra to ensure that the load balancer
> contacts the same replicas as before.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators:
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]