org.logicalcobwebs.proxool.admin
类 Admin

java.lang.Object
  继承者 org.logicalcobwebs.proxool.admin.Admin

public class Admin
extends Object

Provides statistics about the performance of a pool.

从以下版本开始:
Proxool 0.7
版本:
$Revision: 1.9 $, $Date: 2006/01/18 14:39:57 $
作者:
bill, $Author: billhorsman $ (current maintainer)

构造方法摘要
Admin(ConnectionPoolDefinitionIF definition)
           
 
方法摘要
 void addStatisticsListener(StatisticsListenerIF statisticsListener)
           
 void cancelAll()
          Cancels the timer that outputs the stats
 void connectionRefused()
          Call this every time a connection is refused
 void connectionReturned(long activeTime)
          Call this every time an active connection is returned to the pool
static SnapshotIF getSnapshot(ConnectionPoolStatisticsIF cps, ConnectionPoolDefinitionIF cpd, Collection connectionInfos)
          Get a new snapshot
 StatisticsIF[] getStatistics()
           
 StatisticsIF getStatistics(String token)
          Returns the most recent sample that has completed its period
 
从类 java.lang.Object 继承的方法
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

构造方法详细信息

Admin

public Admin(ConnectionPoolDefinitionIF definition)
      throws ProxoolException
参数:
definition - gives access to pool definition
definition - see definition
抛出:
ProxoolException
方法详细信息

addStatisticsListener

public void addStatisticsListener(StatisticsListenerIF statisticsListener)

connectionReturned

public void connectionReturned(long activeTime)
Call this every time an active connection is returned to the pool

参数:
activeTime - how long the connection was active

connectionRefused

public void connectionRefused()
Call this every time a connection is refused


getStatistics

public StatisticsIF getStatistics(String token)
Returns the most recent sample that has completed its period

返回:
sample (or null if no statistics are complete yet)

cancelAll

public void cancelAll()
Cancels the timer that outputs the stats


getStatistics

public StatisticsIF[] getStatistics()

getSnapshot

public static SnapshotIF getSnapshot(ConnectionPoolStatisticsIF cps,
                                     ConnectionPoolDefinitionIF cpd,
                                     Collection connectionInfos)
Get a new snapshot

参数:
cps - used to help populate the snapshot
cpd - used to help populate the snapshot
返回:
snapshot


Copyright © 2014. All rights reserved.