com.softwareag.tamino.db.api.connection
Class TConnectionPoolStatistics

java.lang.Object
  extended by com.softwareag.tamino.db.api.connection.TConnectionPoolStatistics

public class TConnectionPoolStatistics
extends java.lang.Object

TConnectionPoolStatistics describes statistical information for a connection pool.

Version:
$Revision: 1.2 $
Author:
Martin Meijsen

Constructor Summary
TConnectionPoolStatistics()
          Constructor to construct a TConnectionPoolStatistics with default settings.
 
Method Summary
 int getDeleteConnections()
          Gets the number of connections deleted from the pool.
 TConnectionPoolDescriptor getDescriptor()
          Gets the pool descriptor with the properties of the pool and its connections.
 int getFailedReconnects()
          Gets the number of failed reconnect attempts.
 int getGetConnections()
          Gets the number of getConnection() method invocations.
 int getMaxUsedConnections()
          Gets the maximum number of connections in the pool.
 java.lang.String getName()
          Gets the pool name.
 int getReconnects()
          Gets the number of reconnect attempts.
 int getWaits()
          Gets the number of times a client had to wait for a getConnection()
protected  void setDeleteConnects(int deleteConnections)
          Sets the number of deleted connects.
protected  void setDescriptor(TConnectionPoolDescriptor descriptor)
          Sets the descriptor.
protected  void setFailedReconnects(int failedReconnects)
          Sets the number of failed reconnects.
protected  void setGetConnects(int getConnections)
          Sets the number of getConnection invocations.
protected  void setMaxUsedConnects(int maxUsedConnections)
          Sets the maximum number of used connections.
protected  void setName(java.lang.String name)
          Method setName
protected  void setReconnects(int reconnects)
          Sets the number of reconnects.
protected  void setWaits(int waits)
          Sets the number of waits.
 java.lang.String toString()
          Delivers the statistical information as a String.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

TConnectionPoolStatistics

public TConnectionPoolStatistics()
Constructor to construct a TConnectionPoolStatistics with default settings.

Method Detail

getDeleteConnections

public int getDeleteConnections()
Gets the number of connections deleted from the pool. A connection only gets deleted from a pool if a comuunication error occured and the physical connection is no longer usable.

Returns:
the number of deleted connections as an int

getMaxUsedConnections

public int getMaxUsedConnections()
Gets the maximum number of connections in the pool.

Returns:
maximum number of connections in the pool as an int

getFailedReconnects

public int getFailedReconnects()
Gets the number of failed reconnect attempts. A reconnect normally only fails due to a communication problem with the Tamino server or if the Tamino server is no longer available or is out of resources.

Returns:
the number of failed reconnect attempts as an int

getReconnects

public int getReconnects()
Gets the number of reconnect attempts. A reconnect is attempted if a connection is assumed to be timed out and needs to be reconnected before it can be used again.

Returns:
the number of reconnect attempts as an int

getWaits

public int getWaits()
Gets the number of times a client had to wait for a getConnection()

Returns:
the number of times a client had to wait for a getConnection() as an int

getGetConnections

public int getGetConnections()
Gets the number of getConnection() method invocations.

Returns:
the number of getConnection() method invocations as an int

getName

public java.lang.String getName()
Gets the pool name.

Returns:
the pool name as a String

getDescriptor

public TConnectionPoolDescriptor getDescriptor()
Gets the pool descriptor with the properties of the pool and its connections.

Returns:
the TConnectionPoolDescriptor pool descriptor

setMaxUsedConnects

protected void setMaxUsedConnects(int maxUsedConnections)
Sets the maximum number of used connections. For internal use only.

Parameters:
maxUsedConnections - an int

setDeleteConnects

protected void setDeleteConnects(int deleteConnections)
Sets the number of deleted connects. For internal use only.

Parameters:
deleteConnections - an int

setGetConnects

protected void setGetConnects(int getConnections)
Sets the number of getConnection invocations. For internal use only.

Parameters:
connections - an int

setFailedReconnects

protected void setFailedReconnects(int failedReconnects)
Sets the number of failed reconnects. For internal use only.

Parameters:
failedReconnects - an int

setReconnects

protected void setReconnects(int reconnects)
Sets the number of reconnects. For internal use only.

Parameters:
reconnects - an int

setWaits

protected void setWaits(int waits)
Sets the number of waits. For internal use only.

Parameters:
waits - an int

setDescriptor

protected void setDescriptor(TConnectionPoolDescriptor descriptor)
Sets the descriptor. For internal use only.

Parameters:
descriptor - a TConnectionPoolDescriptor

toString

public java.lang.String toString()
Delivers the statistical information as a String.

Overrides:
toString in class java.lang.Object
Returns:
the statistical information of the pool as a String

setName

protected void setName(java.lang.String name)
Method setName

Parameters:
name - a String


Copyright (c) 2013 Software AG. All Rights Reserved.