public final class ThreadUtilities
extends java.lang.Object
| Modifier and Type | Method and Description |
|---|---|
protected static java.util.Set |
getAllThreads() |
static int |
getNumberOfAvailableCores() |
static int |
getNumberOfThreadsFromExpression(java.lang.String expression,
int defaultValue)
Evaluates an expression and returns its value.
|
static int |
getThreadCount()
get the number of threads, not limited by thread group or activity
|
static java.util.Map |
getThreadCountMap() |
static java.lang.String |
printThreadDump() |
static void |
printThreadDump(java.io.PrintStream out) |
protected static java.util.Set getAllThreads()
public static int getThreadCount()
public static java.util.Map getThreadCountMap()
Class -> instance count Integerpublic static void printThreadDump(java.io.PrintStream out)
public static java.lang.String printThreadDump()
public static int getNumberOfThreadsFromExpression(java.lang.String expression,
int defaultValue)
#cores variable which holds number of cores. In case when expression
evaluates to value lower than 1 value 1 will be returned.
Examples of valid expressions:
7#cores#cores * 2#cores - 1expression - expression to evaluatedefaultValue - default value which must be greater than zeropublic static int getNumberOfAvailableCores()
Copyright © 2018 SAP SE. All Rights Reserved.