Package org.hibernate.testing.jdbc.leak
Class PostgreSQLIdleConnectionCounter
java.lang.Object
org.hibernate.testing.jdbc.leak.PostgreSQLIdleConnectionCounter
- All Implemented Interfaces:
IdleConnectionCounter
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionboolean
Specifies which Dialect the counter applies to.int
count
(Connection connection) Count the number of idle connections.
-
Field Details
-
INSTANCE
-
-
Constructor Details
-
PostgreSQLIdleConnectionCounter
public PostgreSQLIdleConnectionCounter()
-
-
Method Details
-
appliesTo
Description copied from interface:IdleConnectionCounter
Specifies which Dialect the counter applies to.- Specified by:
appliesTo
in interfaceIdleConnectionCounter
- Parameters:
dialect
- dialect- Returns:
- applicability.
-
count
Description copied from interface:IdleConnectionCounter
Count the number of idle connections.- Specified by:
count
in interfaceIdleConnectionCounter
- Parameters:
connection
- current JDBC connection to be used for querying the number of idle connections.- Returns:
- idle connection count.
-