public static class LoadBalancingStrategy.RoundRobin extends Object implements LoadBalancingStrategy
Cluster to send the
RequestMessage to.LoadBalancingStrategy.RoundRobin| Constructor and Description |
|---|
RoundRobin() |
| Modifier and Type | Method and Description |
|---|---|
void |
initialize(Cluster cluster,
Collection<Host> hosts)
Initialize the strategy with the
Cluster instance and the expected host list. |
void |
onAvailable(Host host) |
void |
onNew(Host host) |
void |
onRemove(Host host) |
void |
onUnavailable(Host host) |
Iterator<Host> |
select(org.apache.tinkerpop.gremlin.driver.message.RequestMessage msg)
Provide an ordered list of hosts to send the the given
RequestMessage to. |
public void initialize(Cluster cluster, Collection<Host> hosts)
LoadBalancingStrategyCluster instance and the expected host list.initialize in interface LoadBalancingStrategypublic Iterator<Host> select(org.apache.tinkerpop.gremlin.driver.message.RequestMessage msg)
LoadBalancingStrategyRequestMessage to.select in interface LoadBalancingStrategypublic void onAvailable(Host host)
onAvailable in interface Host.Listenerpublic void onUnavailable(Host host)
onUnavailable in interface Host.Listenerpublic void onNew(Host host)
onNew in interface Host.Listenerpublic void onRemove(Host host)
onRemove in interface Host.ListenerCopyright © 2013–2015 Apache Software Foundation. All rights reserved.