Interface MonitoredFuture<T>

Type Parameters:
T - the type of result.
All Superinterfaces:
Future<T>

public interface MonitoredFuture<T> extends Future<T>
Extension of Future that allows the client to query for the partial status. In the same way that Future is an execution handle to a Callable, a MonitoredFuture is an execution handle to a MonitoredCallable or to a DistributedCallable. In the case where it is a DistributedCallable, the result returned by the future will be the result of calling DistributedCallable.merge(java.util.List) on each of the partition results.
See Also:
  • Method Summary

    Modifier and Type
    Method
    Description
    Returns the partial status of the MonitoredCallable or the final result if the command has completed successfully.

    Methods inherited from interface java.util.concurrent.Future

    cancel, get, get, isCancelled, isDone
  • Method Details

    • getStatus

      Returns the partial status of the MonitoredCallable or the final result if the command has completed successfully. In the event that the command fails, this will return a status of the command following the exception. In the case where it is a DistributedCallable, the result returned by the future will be the result of calling DistributedCallable.merge(java.util.List) on the status's or final results.
      Returns:
      the partial status
      Throws:
      ExecutionException - if there was an (I/O) error fetching the status.
      InterruptedException - if interrupted while waiting for the status. Note that getStatus does not block in the end-to-end sense, but does block waiting for network IO so it can potentially throw InterruptedException