org.apache.ignite.compute

## Interface ComputeTaskFuture<R>

- Type Parameters:
    `R` - Type of the task result returning from `ComputeTask.reduce(List)` method.
  All Superinterfaces:
    IgniteFuture<R>

      public interface ComputeTaskFuture<R>
      extends IgniteFuture<R>

  This class defines a handler for asynchronous task execution. It's similar in design to standard JDK `Future` interface but has improved and easier to use exception hierarchy.

- - ### Method Summary

    All Methods Instance Methods Abstract Methods
    Modifier and Type | Method and Description
    --- | ---
    `R` | `get()` Synchronously waits for completion of the computation and returns computation result.
    `R` | `get(long timeout, TimeUnit unit)` Synchronously waits for completion of the computation for up to the timeout specified and returns computation result.
    `ComputeTaskSession` | `getTaskSession()` Gets task session of execution grid task.

    - ### Methods inherited from interface org.apache.ignite.lang.IgniteFuture

      `cancel, chain, chainAsync, get, isCancelled, isDone, listen, listenAsync`

- - ### Method Detail

    - #### get

          R get()

      Synchronously waits for completion of the computation and returns computation result.
      Specified by:
        `get` in interface `IgniteFuture<R>`
      Returns:
        Computation result.
      Throws:
        `ComputeTaskTimeoutException` - If task execution timed out.

    - #### get

          R get(long timeout,
                TimeUnit unit)

      Synchronously waits for completion of the computation for up to the timeout specified and returns computation result.
      Specified by:
        `get` in interface `IgniteFuture<R>`
      Parameters:
        `timeout` - The maximum time to wait.
        `unit` - The time unit of the `timeout` argument.
      Returns:
        Computation result.
      Throws:
        `ComputeTaskTimeoutException` - If task execution timed out.

    - #### getTaskSession

          ComputeTaskSession getTaskSession()

      Gets task session of execution grid task.
      Returns:
        Task session.

2021 Copyright © Apache Software Foundation
| Follow @ApacheIgnite
Ignite Database and Caching Platform | : ver. 2.10.0
Release Date | : March 10 2021