public class EmptyConnectionPoolMonitor extends java.lang.Object implements ConnectionPoolMonitor
| Modifier and Type | Method and Description |
|---|---|
long |
getBadRequestCount() |
long |
getConnectionBorrowedCount() |
long |
getConnectionClosedCount() |
long |
getConnectionCreatedCount() |
long |
getConnectionCreateFailedCount() |
long |
getConnectionReturnedCount() |
long |
getFailoverCount() |
long |
getHostActiveCount() |
long |
getHostAddedCount()
Return the number of times a host was added to the pool.
|
long |
getHostCount() |
long |
getHostDownCount() |
long |
getHostRemovedCount()
Return the number of times any host was removed to the pool.
|
java.util.Map<Host,HostStats> |
getHostStats() |
static EmptyConnectionPoolMonitor |
getInstance() |
long |
getInterruptedCount() |
long |
getNoHostCount() |
long |
getOperationFailureCount() |
long |
getOperationSuccessCount() |
long |
getOperationTimeoutCount()
Timeout waiting for a response from the cluster
|
long |
getPoolExhaustedTimeoutCount()
Timeout trying to get a connection from the pool
|
long |
getSocketTimeoutCount() |
long |
getTransportErrorCount() |
long |
getUnknownErrorCount() |
void |
incConnectionBorrowed(Host host,
long delay)
Incremented for each connection borrowed
|
void |
incConnectionClosed(Host host,
java.lang.Exception e)
Closed a connection
|
void |
incConnectionCreated(Host host)
Created a connection successfully
|
void |
incConnectionCreateFailed(Host host,
java.lang.Exception e)
Attempt to create a connection failed
|
void |
incConnectionReturned(Host host)
Incremented for each connection returned.
|
void |
incFailover(Host host,
java.lang.Exception e)
An operation failed but the connection pool will attempt to fail over to
another host/connection.
|
void |
incOperationFailure(Host host,
java.lang.Exception e)
Errors trying to execute an operation.
|
void |
incOperationSuccess(Host host,
long latency)
Succeeded in executing an operation
|
long |
notFoundCount() |
void |
onHostAdded(Host host,
HostConnectionPool<?> pool)
A host was added and given the associated pool.
|
void |
onHostDown(Host host,
java.lang.Exception reason)
A host was identified as downed.
|
void |
onHostReactivated(Host host,
HostConnectionPool<?> pool)
A host was reactivated after being marked down
|
void |
onHostRemoved(Host host)
A host was removed from the pool.
|
java.lang.String |
toString() |
public static EmptyConnectionPoolMonitor getInstance()
public java.lang.String toString()
toString in class java.lang.Objectpublic void incOperationSuccess(Host host, long latency)
ConnectionPoolMonitorincOperationSuccess in interface ConnectionPoolMonitorpublic void incConnectionBorrowed(Host host, long delay)
ConnectionPoolMonitorincConnectionBorrowed in interface ConnectionPoolMonitorhost - Host from which the connection was borroweddelay - Time spent in the connection pool borrowing the connectionpublic void incConnectionReturned(Host host)
ConnectionPoolMonitorincConnectionReturned in interface ConnectionPoolMonitorhost - Host to which connection is returnedpublic void onHostAdded(Host host, HostConnectionPool<?> pool)
ConnectionPoolMonitoronHostAdded in interface ConnectionPoolMonitorpublic void onHostRemoved(Host host)
ConnectionPoolMonitoronHostRemoved in interface ConnectionPoolMonitorpublic void onHostDown(Host host, java.lang.Exception reason)
ConnectionPoolMonitoronHostDown in interface ConnectionPoolMonitorreason - Exception that caused the host to be identified as downpublic void onHostReactivated(Host host, HostConnectionPool<?> pool)
ConnectionPoolMonitoronHostReactivated in interface ConnectionPoolMonitorpublic void incFailover(Host host, java.lang.Exception e)
ConnectionPoolMonitorincFailover in interface ConnectionPoolMonitorpublic void incConnectionCreated(Host host)
ConnectionPoolMonitorincConnectionCreated in interface ConnectionPoolMonitorpublic void incConnectionCreateFailed(Host host, java.lang.Exception e)
ConnectionPoolMonitorincConnectionCreateFailed in interface ConnectionPoolMonitorpublic void incOperationFailure(Host host, java.lang.Exception e)
ConnectionPoolMonitorincOperationFailure in interface ConnectionPoolMonitorpublic void incConnectionClosed(Host host, java.lang.Exception e)
ConnectionPoolMonitorincConnectionClosed in interface ConnectionPoolMonitore - TODO: Make the host available to thispublic java.util.Map<Host,HostStats> getHostStats()
getHostStats in interface ConnectionPoolMonitorpublic long getOperationFailureCount()
getOperationFailureCount in interface ConnectionPoolMonitorpublic long getOperationSuccessCount()
getOperationSuccessCount in interface ConnectionPoolMonitorpublic long getConnectionCreatedCount()
getConnectionCreatedCount in interface ConnectionPoolMonitorpublic long getConnectionClosedCount()
getConnectionClosedCount in interface ConnectionPoolMonitorpublic long getConnectionCreateFailedCount()
getConnectionCreateFailedCount in interface ConnectionPoolMonitorpublic long getConnectionBorrowedCount()
getConnectionBorrowedCount in interface ConnectionPoolMonitorpublic long getConnectionReturnedCount()
getConnectionReturnedCount in interface ConnectionPoolMonitorpublic long getPoolExhaustedTimeoutCount()
ConnectionPoolMonitorgetPoolExhaustedTimeoutCount in interface ConnectionPoolMonitorpublic long getOperationTimeoutCount()
ConnectionPoolMonitorgetOperationTimeoutCount in interface ConnectionPoolMonitorpublic long getFailoverCount()
getFailoverCount in interface ConnectionPoolMonitorpublic long getNoHostCount()
getNoHostCount in interface ConnectionPoolMonitorpublic long getSocketTimeoutCount()
getSocketTimeoutCount in interface ConnectionPoolMonitorpublic long getUnknownErrorCount()
getUnknownErrorCount in interface ConnectionPoolMonitorpublic long getBadRequestCount()
getBadRequestCount in interface ConnectionPoolMonitorpublic long notFoundCount()
notFoundCount in interface ConnectionPoolMonitorpublic long getInterruptedCount()
getInterruptedCount in interface ConnectionPoolMonitorpublic long getHostCount()
getHostCount in interface ConnectionPoolMonitorpublic long getHostAddedCount()
ConnectionPoolMonitorgetHostAddedCount in interface ConnectionPoolMonitorpublic long getHostRemovedCount()
ConnectionPoolMonitorgetHostRemovedCount in interface ConnectionPoolMonitorpublic long getHostDownCount()
getHostDownCount in interface ConnectionPoolMonitorpublic long getTransportErrorCount()
getTransportErrorCount in interface ConnectionPoolMonitorpublic long getHostActiveCount()
getHostActiveCount in interface ConnectionPoolMonitor