TaskFailedException Class
- java.
lang. Object - java.
lang. Throwable - java.
lang. Exception - java.
lang. RuntimeException - com.
microsoft. durabletask. TaskFailedException
- com.
- java.
- java.
- java.
public class TaskFailedException
extends java.lang.RuntimeException
Exception that gets thrown when awaiting a Task<V> for an activity or sub-orchestration that fails with an unhandled exception.
Detailed information associated with a particular task failure can be retrieved using the getErrorDetails() method.
Method Summary
| Modifier and Type | Method and Description |
|---|---|
|
Failure |
getErrorDetails()
Gets the details of the task failure, including exception information. |
| int |
getTaskId()
Gets the ID of the failed task. |
| java.lang.String |
getTaskName()
Gets the name of the failed task. |
Methods inherited from java.lang.Object
Methods inherited from java.lang.Throwable
Method Details
getErrorDetails
public FailureDetails getErrorDetails()
Gets the details of the task failure, including exception information.
Returns:
getTaskId
public int getTaskId()
Gets the ID of the failed task.
Each durable task (activities, timers, sub-orchestrations, etc.) scheduled by a task orchestrator has an auto-incrementing ID associated with it. This ID is used to distinguish tasks from one another, even if, for example, they are tasks that call the same activity. This ID can therefore be used to more easily correlate a specific task failure to a specific task.
Returns:
getTaskName
public String getTaskName()
Gets the name of the failed task.
Returns: