public enum PauserMode extends Enum<PauserMode> implements Supplier<Pauser>
Pauser is not an enum, and implementations are not Marshallable, this makes Pausers more yaml friendly
Here is a list of the different Pauser Mode features| Enum Constant and Description |
|---|
balanced
Returns Suppliers providing pausers performing busy waiting (spin-wait at 100% CPU) for short
periods and then backs off when idle for longer periods, if there are sufficient available processors.
|
busy
Returns Suppliers providing pausers performing busy waiting (spin-wait at 100% CPU)
if there are sufficient available processors.
|
milli
Returns Suppliers providing pausers that sleeps for one millisecond when backing off.
|
sleepy
Returns Suppliers providing pausers hat backs off when idle.
|
timedBusy
Returns Suppliers similar to
busy but that provides pausers that supports
timed pauser. |
yielding
Returns Suppliers providing pausers that is very briefly busy waiting (spin-wait at 100% CPU) and
then yields execution, if there are sufficient available processors.
|
| Modifier and Type | Method and Description |
|---|---|
boolean |
isolcpus()
Returns if provided Pausers supports CPU isolation.
|
boolean |
monitor()
Returns if provided Pausers can be monitored.
|
static PauserMode |
valueOf(String name)
Returns the enum constant of this type with the specified name.
|
static PauserMode[] |
values()
Returns an array containing the constants of this enum type, in
the order they are declared.
|
public static final PauserMode balanced
sleepy depending on the system property "pauser.minProcessors".
Balanced pausers is trying to balance latency and required CPU resources.
The various Pauser modes and their properties can be seen here: Pauser Mode features
Runtime.availableProcessors()public static final PauserMode busy
balanced or even sleepy depending on the system property "pauser.minProcessors".
Busy pausers have the lowest latency times but requires the most CPU resources.
The various Pauser modes and their properties can be seen here: Pauser Mode features
Runtime.availableProcessors()public static final PauserMode milli
Milli pausers have long latency times but but requires minimum CPU resources.
The various Pauser modes and their properties can be seen here: Pauser Mode features
Runtime.availableProcessors()public static final PauserMode sleepy
Sleepy pausers have fair latency and requires limited CPU resources.
The various Pauser modes and their properties can be seen here: Pauser Mode features
Runtime.availableProcessors()public static final PauserMode timedBusy
busy but that provides pausers that supports
timed pauser.busypublic static final PauserMode yielding
balanced or even sleepy depending on the system property "pauser.minProcessors".
Yelding pausers have low latency times but may require significant CPU resources.
The various Pauser modes and their properties can be seen here: Pauser Mode features
Runtime.availableProcessors()public static PauserMode[] values()
for (PauserMode c : PauserMode.values()) System.out.println(c);
public static PauserMode valueOf(String name)
name - the name of the enum constant to be returned.IllegalArgumentException - if this enum type has no constant with the specified nameNullPointerException - if the argument is nullpublic boolean isolcpus()
public boolean monitor()
Copyright © 2021. All rights reserved.