Package com.linkedin.venice.router.api
Class VeniceHostFinder
java.lang.Object
com.linkedin.venice.router.api.VeniceHostFinder
- All Implemented Interfaces:
HostFinder<Instance,
VeniceRole>
{code VeniceHostFinder} finds a set of hosts that can serve the given Venice resource partition.
-
Constructor Summary
ConstructorDescriptionVeniceHostFinder
(OnlineInstanceFinder onlineInstanceFinder, RouterStats<AggRouterHttpRequestStats> routerStats, HostHealthMonitor<Instance> instanceHealthMonitor) -
Method Summary
Modifier and TypeMethodDescriptionfindHosts
(String requestMethod, String resourceName, String storeName, int partitionNumber, HostHealthMonitor<Instance> hostHealthMonitor) findHosts
(String requestMethod, String resourceName, String partitionName, HostHealthMonitor<Instance> hostHealthMonitor, VeniceRole roles) This parameter list is based on the router API.Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface com.linkedin.alpini.router.api.HostFinder
getChangeFuture, getSnapshot
-
Constructor Details
-
VeniceHostFinder
public VeniceHostFinder(OnlineInstanceFinder onlineInstanceFinder, RouterStats<AggRouterHttpRequestStats> routerStats, HostHealthMonitor<Instance> instanceHealthMonitor)
-
-
Method Details
-
findHosts
public List<Instance> findHosts(String requestMethod, String resourceName, String partitionName, HostHealthMonitor<Instance> hostHealthMonitor, VeniceRole roles) This parameter list is based on the router API. The Venice router currently ignores all but the resourceName and partitionName- Specified by:
findHosts
in interfaceHostFinder<Instance,
VeniceRole> - Parameters:
requestMethod
- - used to identify the read request typeresourceName
- - requiredpartitionName
- - requiredhostHealthMonitor
- - ignored, this class will use its ownHostHealthMonitor
roles
- - ignored- Returns:
-
findHosts
-