org.apache.synapse.commons.datasource

## Class DBPoolView

- java.lang.Object
- - org.apache.synapse.commons.datasource.DBPoolView

- All Implemented Interfaces:
    DBPoolViewMBean

      public class DBPoolView
      extends Object
      implements DBPoolViewMBean

  Data source connection pool stats collector implementation

- - ### Constructor Summary

    Constructors
    Constructor and Description
    `DBPoolView(String name)`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `Map` | `getConnectionUsage()` Connection information as a string
    `String` | `getName()` Data source name
    `int` | `getNumActive()` Number of active connections
    `int` | `getNumIdle()` Number of idle connections
    `void` | `reset()` reset statistics
    `void` | `setName(String name)`
    `void` | `setNumActive(int numActive)`
    `void` | `setNumIdle(int numIdle)`
    `void` | `updateConnectionUsage(String connectionID)`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Constructor Detail

    - #### DBPoolView

          public DBPoolView(String name)

  - ### Method Detail

    - #### getNumActive

          public int getNumActive()

      Description copied from interface: `DBPoolViewMBean`
      Number of active connections
      Specified by:
        `getNumActive` in interface `DBPoolViewMBean`
      Returns:
        `int` Number of active connections

    - #### setNumActive

          public void setNumActive(int numActive)

    - #### getNumIdle

          public int getNumIdle()

      Description copied from interface: `DBPoolViewMBean`
      Number of idle connections
      Specified by:
        `getNumIdle` in interface `DBPoolViewMBean`
      Returns:
        `int` Number of idle connections

    - #### setNumIdle

          public void setNumIdle(int numIdle)

    - #### getName

          public String getName()

      Description copied from interface: `DBPoolViewMBean`
      Data source name
      Specified by:
        `getName` in interface `DBPoolViewMBean`
      Returns:
        `String` data source name

    - #### setName

          public void setName(String name)

    - #### updateConnectionUsage

          public void updateConnectionUsage(String connectionID)

    - #### getConnectionUsage

          public Map getConnectionUsage()

      Description copied from interface: `DBPoolViewMBean`
      Connection information as a string
      Specified by:
        `getConnectionUsage` in interface `DBPoolViewMBean`
      Returns:
        `String` representing connection information

    - #### reset

          public void reset()

      Description copied from interface: `DBPoolViewMBean`
      reset statistics
      Specified by:
        `reset` in interface `DBPoolViewMBean`

Copyright © 2005–2019 Apache Software Foundation. All rights reserved.