public class H2IdleConnectionCounter extends Object implements IdleConnectionCounter
Modifier and Type | Field and Description |
---|---|
static IdleConnectionCounter |
INSTANCE |
Constructor and Description |
---|
H2IdleConnectionCounter() |
Modifier and Type | Method and Description |
---|---|
boolean |
appliesTo(Class<? extends Dialect> dialect)
Specifies which Dialect the counter applies to.
|
int |
count(Connection connection)
Count the number of idle connections.
|
public static final IdleConnectionCounter INSTANCE
public boolean appliesTo(Class<? extends Dialect> dialect)
IdleConnectionCounter
appliesTo
in interface IdleConnectionCounter
dialect
- dialectpublic int count(Connection connection)
IdleConnectionCounter
count
in interface IdleConnectionCounter
connection
- current JDBC connection to be used for querying the number of idle connections.Copyright © 2001-2021 Red Hat, Inc. All Rights Reserved.