brooklyn.management.Task Maven / Gradle / Ivy
package brooklyn.management;
import java.util.Set;
import java.util.concurrent.Callable;
import java.util.concurrent.ExecutionException;
import java.util.concurrent.Future;
import java.util.concurrent.TimeoutException;
import com.google.common.util.concurrent.ListenableFuture;
import brooklyn.util.time.Duration;
/**
* Represents a unit of work for execution.
*
* When used with an {@link ExecutionManager} or {@link ExecutionContext} it will record submission time,
* execution start time, end time, and any result. A task can be submitted to the ExecutionManager or
* ExecutionContext, in which case it will be returned, or it may be created by submission
* of a {@link Runnable} or {@link Callable} and thereafter it can be treated just like a {@link Future}.
*/
public interface Task extends ListenableFuture, TaskAdaptable {
public String getId();
public Set
© 2015 - 2025 Weber Informatics LLC | Privacy Policy