Package com.hazelcast.core
Interface Offloadable
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
Allows off-loading the processing unit implementing this interface to the specified or default Executor.
Currently supported in:
-
Field Summary
Modifier and TypeFieldDescriptionstatic final String
Constant meaning that there will be no off-loading if returned from thegetExecutorName()
method.static final String
Constant meaning that processing will be off-loaded to the default OFFLOADABLE_EXECUTOR executor. -
Method Summary
Modifier and TypeMethodDescriptionReturns the name of the executor to which the processing unit will be off-loaded.
-
Field Details
-
NO_OFFLOADING
Constant meaning that there will be no off-loading if returned from thegetExecutorName()
method.- See Also:
-
OFFLOADABLE_EXECUTOR
Constant meaning that processing will be off-loaded to the default OFFLOADABLE_EXECUTOR executor. if returned from thegetExecutorName()
method.- See Also:
-
ExecutionService.OFFLOADABLE_EXECUTOR
- Constant Field Values
-
-
Method Details
-
getExecutorName
String getExecutorName()Returns the name of the executor to which the processing unit will be off-loaded.The return value equal to "hz:offloadable" indicates that the processing should off-loaded to the default
ExecutionService.OFFLOADABLE_EXECUTOR
.The return value equal to "no-offloading" indicates that the processing should not be off-loaded at all. The processing will be executed as if the processing-unit didn't implement the
Offloadable
interface.Other return values will look up the executor with the returned value which can be configured in the Hazelcast configuration.
- Returns:
- the name of the executor to which the processing should be off-loaded.
- See Also:
-