Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions src/main/java/com/zaxxer/hikari/HikariPoolMXBean.java
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,11 @@ public interface HikariPoolMXBean
*/
int getThreadsAwaitingConnection();

/**
* Returns whether the pool is currently suspended.
*/
boolean isSuspended();

/**
* Evict currently idle connections from the pool, and mark active (in-use) connections for eviction when they are
* returned to the pool.
Expand Down
7 changes: 7 additions & 0 deletions src/main/java/com/zaxxer/hikari/pool/HikariPool.java
Original file line number Diff line number Diff line change
Expand Up @@ -368,6 +368,13 @@ public int getThreadsAwaitingConnection()
return connectionBag.getWaitingThreadCount();
}

/** {@inheritDoc} */
@Override
public boolean isSuspended()
{
return poolState == POOL_SUSPENDED;
}

/** {@inheritDoc} */
@Override
public void softEvictConnections()
Expand Down