Class FixedThreadPoolBulkhead.BulkheadMetrics
java.lang.Object
io.github.resilience4j.bulkhead.internal.FixedThreadPoolBulkhead.BulkheadMetrics
- All Implemented Interfaces:
ThreadPoolBulkhead.Metrics
- Enclosing class:
FixedThreadPoolBulkhead
private final class FixedThreadPoolBulkhead.BulkheadMetrics
extends Object
implements ThreadPoolBulkhead.Metrics
the thread pool bulk head metrics
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintReturns the number of actively executing tasks.intReturns the maximum number of available threads.intReturns the core number of threads.intReturns the maximum allowed number of threads.intReturns the queue capacity.intReturns the number of tasks in the queue.intReturns the remaining queue capacity.intReturns the current number of threads in the pool.
-
Constructor Details
-
BulkheadMetrics
private BulkheadMetrics()
-
-
Method Details
-
getCoreThreadPoolSize
public int getCoreThreadPoolSize()Description copied from interface:ThreadPoolBulkhead.MetricsReturns the core number of threads.- Specified by:
getCoreThreadPoolSizein interfaceThreadPoolBulkhead.Metrics- Returns:
- the core number of threads
-
getThreadPoolSize
public int getThreadPoolSize()Description copied from interface:ThreadPoolBulkhead.MetricsReturns the current number of threads in the pool.- Specified by:
getThreadPoolSizein interfaceThreadPoolBulkhead.Metrics- Returns:
- the current number of threads
-
getMaximumThreadPoolSize
public int getMaximumThreadPoolSize()Description copied from interface:ThreadPoolBulkhead.MetricsReturns the maximum allowed number of threads.- Specified by:
getMaximumThreadPoolSizein interfaceThreadPoolBulkhead.Metrics- Returns:
- the maximum allowed number of threads
-
getQueueDepth
public int getQueueDepth()Description copied from interface:ThreadPoolBulkhead.MetricsReturns the number of tasks in the queue.- Specified by:
getQueueDepthin interfaceThreadPoolBulkhead.Metrics- Returns:
- the number of tasks in the queue
-
getRemainingQueueCapacity
public int getRemainingQueueCapacity()Description copied from interface:ThreadPoolBulkhead.MetricsReturns the remaining queue capacity.- Specified by:
getRemainingQueueCapacityin interfaceThreadPoolBulkhead.Metrics- Returns:
- the remaining queue capacity
-
getQueueCapacity
public int getQueueCapacity()Description copied from interface:ThreadPoolBulkhead.MetricsReturns the queue capacity.- Specified by:
getQueueCapacityin interfaceThreadPoolBulkhead.Metrics- Returns:
- the queue capacity
-
getActiveThreadCount
public int getActiveThreadCount()Description copied from interface:ThreadPoolBulkhead.MetricsReturns the number of actively executing tasks.- Specified by:
getActiveThreadCountin interfaceThreadPoolBulkhead.Metrics- Returns:
- the number of executing tasks
-
getAvailableThreadCount
public int getAvailableThreadCount()Description copied from interface:ThreadPoolBulkhead.MetricsReturns the maximum number of available threads. Equivalent togetMaximumThreadPoolSize() - getActiveThreadCount()- Specified by:
getAvailableThreadCountin interfaceThreadPoolBulkhead.Metrics- Returns:
- the number of executing tasks
-