com.hazelcast.core

## Interface Offloadable

-     public interface Offloadable

  Allows off-loading the processing unit implementing this interface to the specified or default Executor. Currently supported in:
  - `IMap.executeOnKey(Object, EntryProcessor)`
  - `IMap.submitToKey(Object, EntryProcessor)`
  - `IMap.submitToKey(Object, EntryProcessor, ExecutionCallback)`

- - ### Field Summary

    Fields
    Modifier and Type | Field and Description
    --- | ---
    `static String` | `NO_OFFLOADING` Constant meaning that there will be no off-loading if returned from the `getExecutorName()` method.
    `static String` | `OFFLOADABLE_EXECUTOR` Constant meaning that processing will be off-loaded to the default OFFLOADABLE_EXECUTOR executor.

  - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method and Description
    --- | ---
    `String` | `getExecutorName()` Returns the name of the executor to which the processing unit will be off-loaded.

- - ### Field Detail

    - #### NO_OFFLOADING

          static final String NO_OFFLOADING

      Constant meaning that there will be no off-loading if returned from the `getExecutorName()` method.
      See Also:
        Constant Field Values

    - #### OFFLOADABLE_EXECUTOR

          static final String OFFLOADABLE_EXECUTOR

      Constant meaning that processing will be off-loaded to the default OFFLOADABLE_EXECUTOR executor. if returned from the `getExecutorName()` method.
      See Also:
        `ExecutionService.OFFLOADABLE_EXECUTOR`, Constant Field Values

  - ### Method Detail

    - #### 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 lookup 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:
        `ExecutorConfig`, `Config.addExecutorConfig(ExecutorConfig)`

Copyright © 2019. All rights reserved.