|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.netflix.astyanax.connectionpool.impl.AbstractTopology<CL>
public class AbstractTopology<CL>
| Constructor Summary | |
|---|---|
AbstractTopology(LatencyScoreStrategy strategy)
|
|
| Method Summary | |
|---|---|
void |
addPool(HostConnectionPool<CL> pool)
Add a pool without knowing its token. |
TokenHostConnectionPoolPartition<CL> |
getAllPools()
Return a partition that represents all hosts in the ring |
TokenHostConnectionPoolPartition<CL> |
getPartition(java.nio.ByteBuffer rowkey)
Get the partition best suited to handle a row key |
TokenHostConnectionPoolPartition<CL> |
getPartition(java.lang.String token)
Return the partition for a specific token |
int |
getPartitionCount()
|
java.util.List<java.lang.String> |
getPartitionNames()
|
java.util.Map<java.lang.String,TokenHostConnectionPoolPartition<CL>> |
getPartitions()
|
void |
refresh()
Refresh the internal state and apply the latency score strategy |
void |
removePool(HostConnectionPool<CL> pool)
Remove this pool from all partitions |
void |
resumePool(HostConnectionPool<CL> pool)
Resume a host that was previously down |
boolean |
setPools(java.util.Collection<HostConnectionPool<CL>> ring)
Refresh the internal topology structure |
void |
suspendPool(HostConnectionPool<CL> pool)
Suspend a host that is down |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public AbstractTopology(LatencyScoreStrategy strategy)
| Method Detail |
|---|
public boolean setPools(java.util.Collection<HostConnectionPool<CL>> ring)
Topology
setPools in interface Topology<CL>public void resumePool(HostConnectionPool<CL> pool)
Topology
resumePool in interface Topology<CL>public void suspendPool(HostConnectionPool<CL> pool)
Topology
suspendPool in interface Topology<CL>public void refresh()
Topology
refresh in interface Topology<CL>public TokenHostConnectionPoolPartition<CL> getPartition(java.nio.ByteBuffer rowkey)
Topology
getPartition in interface Topology<CL>public TokenHostConnectionPoolPartition<CL> getAllPools()
Topology
getAllPools in interface Topology<CL>public int getPartitionCount()
getPartitionCount in interface Topology<CL>public void removePool(HostConnectionPool<CL> pool)
Topology
removePool in interface Topology<CL>public void addPool(HostConnectionPool<CL> pool)
Topology
addPool in interface Topology<CL>public java.util.List<java.lang.String> getPartitionNames()
getPartitionNames in interface Topology<CL>public TokenHostConnectionPoolPartition<CL> getPartition(java.lang.String token)
Topology
getPartition in interface Topology<CL>public java.util.Map<java.lang.String,TokenHostConnectionPoolPartition<CL>> getPartitions()
getPartitions in interface Topology<CL>
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||