Questo contenuto non è disponibile nella lingua selezionata.
16.2. DistributedCallable API
The
DistributedCallable interface is a subtype of the existing Callable from java.util.concurrent.package, and can be executed in a remote JVM and receive input from Red Hat JBoss Data Grid. The DistributedCallable interface is used to facilitate tasks that require access to JBoss Data Grid cache data.
When using the
DistributedCallable API to execute a task, the task's main algorithm remains unchanged, however the input source is changed.
Users who have already implemented the
Callable interface must extend DistributedCallable if access to the cache or the set of passed in keys is required.
Example 16.1. Using the DistributedCallable API