public final class ThreadUtilities extends Object
| Modifier and Type | Method and Description |
|---|---|
protected static Set |
getAllThreads() |
static int |
getNumberOfAvailableCores() |
static int |
getNumberOfThreadsFromExpression(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 Map |
getThreadCountMap() |
static String |
printThreadDump() |
static void |
printThreadDump(PrintStream out) |
protected static Set getAllThreads()
public static int getThreadCount()
public static Map getThreadCountMap()
public static void printThreadDump(PrintStream out)
public static String printThreadDump()
public static int getNumberOfThreadsFromExpression(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 © 2017 SAP SE. All Rights Reserved.