Class Overview
Connection pool which puts all connections in a single queue. The load
balancing is essentially random here.
Summary
[Expand]
Inherited Methods |
From class
com.netflix.astyanax.connectionpool.impl.AbstractHostPartitionConnectionPool
final
boolean
|
addHost(Host host, boolean refresh)
Add a host to the connection pool.
|
<R>
OperationResult<R>
|
executeWithFailover(Operation<CL, R> op, RetryPolicy retry)
Execute an operation with failover within the context of the connection
pool.
|
List<HostConnectionPool<CL>>
|
getActivePools()
Return list of active hosts on which connections can be created
|
HostConnectionPool<CL>
|
getHostPool(Host host)
Return an immutable connection pool for this host
|
boolean
|
hasHost(Host host)
Return true if host is contained within the connection pool
|
boolean
|
isHostUp(Host host)
Return true if the host is up
|
abstract
<R>
ExecuteWithFailover<CL, R>
|
newExecuteWithFailover(Operation<CL, R> op)
Return a new failover context.
|
HostConnectionPool<CL>
|
newHostConnectionPool(Host host, ConnectionFactory<CL> factory, ConnectionPoolConfiguration config)
|
void
|
onHostDown(HostConnectionPool<CL> pool)
|
void
|
onHostUp(HostConnectionPool<CL> pool)
|
void
|
rebuildPartitions()
Called every time a host is added, removed or is marked as down
|
boolean
|
removeHost(Host host, boolean refresh)
Remove a host from the connection pool.
|
synchronized
void
|
setHosts(Map<BigInteger, List<Host>> ring)
Sets the complete set of hosts keyed by token.
|
void
|
shutdown()
Shut down the connection pool and terminate all existing connections
|
void
|
start()
Setup the connection pool and start any maintenance threads
|
|
From class
java.lang.Object
Object
|
clone()
|
boolean
|
equals(Object arg0)
|
void
|
finalize()
|
final
Class<?>
|
getClass()
|
int
|
hashCode()
|
final
void
|
notify()
|
final
void
|
notifyAll()
|
String
|
toString()
|
final
void
|
wait()
|
final
void
|
wait(long arg0, int arg1)
|
final
void
|
wait(long arg0)
|
|
From interface
com.netflix.astyanax.connectionpool.ConnectionPool
|
From interface
com.netflix.astyanax.connectionpool.impl.SimpleHostConnectionPool.Listener
|
Public Constructors
Public Methods
Return a new failover context. The context captures the connection pool
state and implements the necessary failover logic.@return
Protected Methods
protected
boolean
returnConnection
(Connection<CL> connection)