public enum ThreadSelection extends Enum<ThreadSelection>
|Enum Constant and Description|
Automatically select the thread to run operations on based on the return type and/or
I/O selection will run all operations regardless of return type and annotations on the I/O thread pool and will never schedule an operation on the server event loop thread.
Manual selection leaves it up to the user code to spawn threads to run any blocking I/O operations.
|Modifier and Type||Method and Description|
Returns the enum constant of this type with the specified name.
Returns an array containing the constants of this enum type, in the order they are declared.
clone, compareTo, equals, finalize, getDeclaringClass, hashCode, name, ordinal, toString, valueOf
public static final ThreadSelection AUTO
This is the default strategy in 1.x and will run operations on the I/O thread pool if the return type
of the method is not a reactive top and the method is not annotated with
If the return type is a reactive type and the method is not annotated with
Blocking then the server event loop thread will used to run the operation.
public static final ThreadSelection MANUAL
subscribeOn(..)or by using the
Asyncannotation or whatever mechanism the user chooses to spawn the additional thread.
public static final ThreadSelection IO
public static ThreadSelection values()
for (ThreadSelection c : ThreadSelection.values()) System.out.println(c);
public static ThreadSelection valueOf(String name)
name- the name of the enum constant to be returned.
IllegalArgumentException- if this enum type has no constant with the specified name
NullPointerException- if the argument is null