com.jolbox.bonecp
Interface StatisticsMBean

All Known Implementing Classes:
Statistics

public interface StatisticsMBean

MBean (JMX) contract.

Author:
Wallace

Method Summary
 double getCacheHitRatio()
          Returns the cache hit ratio calculated as hits/(hits+misses).
 long getCacheHits()
          Returns the cacheHits field.
 long getCacheMiss()
          Returns the cacheMiss field.
 long getConnectionsRequested()
          Returns the connectionsRequested field.
 double getConnectionWaitTimeAvg()
          Return the average time it takes for a getConnection request to be services (in ms).
 long getCumulativeConnectionWaitTime()
          Returns the total time that the application waited in order to obtain its connections (in ms).
 long getCumulativeStatementExecutionTime()
          Returns the time taken for the prepared statements to execute (in ms).
 long getCumulativeStatementPrepareTime()
          Returns the time taken to prepare statements (or obtain from cache) (in ms).
 double getStatementExecuteTimeAvg()
          Return the average execution time for prepared statements to execute (in ms).
 double getStatementPrepareTimeAvg()
          Return the statement prepare time average (in ms).
 long getStatementsCached()
          Returns the number of statements that have been cached.
 long getStatementsExecuted()
          Returns the number of statements that have been executed.
 long getStatementsPrepared()
          Returns the number of statements prepared.
 int getTotalCreatedConnections()
          Return total number of connections created in all partitions.
 int getTotalFree()
          Return the number of free connections available to an application right away (excluding connections that can be created dynamically)
 int getTotalLeased()
          Return total number of connections currently in use by an application
 void resetStats()
          Reset all statistics.
 

Method Detail

getConnectionWaitTimeAvg

double getConnectionWaitTimeAvg()
Return the average time it takes for a getConnection request to be services (in ms).

Returns:
Time in ms

getStatementExecuteTimeAvg

double getStatementExecuteTimeAvg()
Return the average execution time for prepared statements to execute (in ms).

Returns:
Time in ms

getStatementPrepareTimeAvg

double getStatementPrepareTimeAvg()
Return the statement prepare time average (in ms).

Returns:
Time in ms

getTotalLeased

int getTotalLeased()
Return total number of connections currently in use by an application

Returns:
no of leased connections

getTotalFree

int getTotalFree()
Return the number of free connections available to an application right away (excluding connections that can be created dynamically)

Returns:
number of free connections

getTotalCreatedConnections

int getTotalCreatedConnections()
Return total number of connections created in all partitions.

Returns:
number of created connections

getCacheHits

long getCacheHits()
Returns the cacheHits field.

Returns:
cacheHits

getCacheMiss

long getCacheMiss()
Returns the cacheMiss field.

Returns:
cacheMiss

getStatementsCached

long getStatementsCached()
Returns the number of statements that have been cached.

Returns:
statementsCached

getStatementsPrepared

long getStatementsPrepared()
Returns the number of statements prepared.

Returns:
statements prepared

getConnectionsRequested

long getConnectionsRequested()
Returns the connectionsRequested field.

Returns:
connectionsRequested

getCumulativeConnectionWaitTime

long getCumulativeConnectionWaitTime()
Returns the total time that the application waited in order to obtain its connections (in ms).

Returns:
connectionWaitTime

getCumulativeStatementExecutionTime

long getCumulativeStatementExecutionTime()
Returns the time taken for the prepared statements to execute (in ms).

Returns:
time in ms

getCumulativeStatementPrepareTime

long getCumulativeStatementPrepareTime()
Returns the time taken to prepare statements (or obtain from cache) (in ms).

Returns:
time in ms

resetStats

void resetStats()
Reset all statistics.


getCacheHitRatio

double getCacheHitRatio()
Returns the cache hit ratio calculated as hits/(hits+misses).

Returns:
hit ratio

getStatementsExecuted

long getStatementsExecuted()
Returns the number of statements that have been executed.

Returns:
number of statements.


Copyright © 2009-2011 JolBox. All Rights Reserved.