Interface ITrackableTask
This component lets you keep track of the progress of the task and its status as the task is executed. And lets you fetch the output of the task and enumerate it.
Note:MapReduceCallback() and GetResult() cannot be executed together because GetResult is a blocking call and this combination will throw an exception.
Namespace:
Assembly: Alachisoft.NCache.Runtime.dll
Syntax
public interface ITrackableTask
Properties
Name | Description |
---|---|
TaskId | Unique GUID identification of MapReduce task. |
TaskStatus | Gets the task’s status and contains following values: Waiting, InProgress, Completed, Cancelled, Failed. |
Methods
Name | Description |
---|---|
CancelTask() | Cancels the already running task. |
GetResult() | This is a blocking call that waits for the callback from the server about the task’s completion, failure or cancellation in the form of an ITaskResult. |
GetResult(Int32) | If no result is obtained within the provided timeout, OperationFailedException will be thrown. |
Events
Name | Description |
---|---|
OnMapReduceComplete | Users can register a callback on the MapReduce task that is called when task execution is completed, failed or cancelled with a parameter response that encapsulates status of the task and result (if completed). |