Package com.yahoo.search.dispatch
Class InvokerFactory
- java.lang.Object
-
- com.yahoo.search.dispatch.InvokerFactory
-
- Direct Known Subclasses:
RpcInvokerFactory
public abstract class InvokerFactory extends java.lang.Object
- Author:
- ollivir
-
-
Field Summary
Fields Modifier and Type Field Description protected SearchCluster
searchCluster
-
Constructor Summary
Constructors Constructor Description InvokerFactory(SearchCluster searchCluster)
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected static SearchInvoker
createCoverageErrorInvoker(java.util.List<Node> nodes, java.util.Set<java.lang.Integer> failed)
abstract FillInvoker
createFillInvoker(VespaBackEndSearcher searcher, Result result)
protected abstract java.util.Optional<SearchInvoker>
createNodeSearchInvoker(VespaBackEndSearcher searcher, Query query, int maxHits, Node node)
java.util.Optional<SearchInvoker>
createSearchInvoker(VespaBackEndSearcher searcher, Query query, java.util.OptionalInt groupId, java.util.List<Node> nodes, boolean acceptIncompleteCoverage, int maxHits)
Create aSearchInvoker
for a list of content nodes.void
release()
-
-
-
Field Detail
-
searchCluster
protected final SearchCluster searchCluster
-
-
Constructor Detail
-
InvokerFactory
public InvokerFactory(SearchCluster searchCluster)
-
-
Method Detail
-
createNodeSearchInvoker
protected abstract java.util.Optional<SearchInvoker> createNodeSearchInvoker(VespaBackEndSearcher searcher, Query query, int maxHits, Node node)
-
createFillInvoker
public abstract FillInvoker createFillInvoker(VespaBackEndSearcher searcher, Result result)
-
createSearchInvoker
public java.util.Optional<SearchInvoker> createSearchInvoker(VespaBackEndSearcher searcher, Query query, java.util.OptionalInt groupId, java.util.List<Node> nodes, boolean acceptIncompleteCoverage, int maxHits)
Create aSearchInvoker
for a list of content nodes.- Parameters:
searcher
- the searcher processing the queryquery
- the search query being processedgroupId
- the id of the node group to which the nodes belongnodes
- pre-selected list of content nodesacceptIncompleteCoverage
- if some of the nodes are unavailable and this parameter is false, verify that the remaining set of nodes has sufficient coverage- Returns:
- the invoker or empty if some node in the list is invalid and the remaining coverage is not sufficient
-
createCoverageErrorInvoker
protected static SearchInvoker createCoverageErrorInvoker(java.util.List<Node> nodes, java.util.Set<java.lang.Integer> failed)
-
release
public void release()
-
-