Skip to content

Commit

Permalink
docs: add status state diagram (#742)
Browse files Browse the repository at this point in the history
  • Loading branch information
ngruelaneo committed Sep 17, 2024
2 parents 850e4f1 + 2bd4002 commit fd5af23
Showing 1 changed file with 30 additions and 0 deletions.
30 changes: 30 additions & 0 deletions .docs/content/1.concepts/2.tasks.md
Original file line number Diff line number Diff line change
Expand Up @@ -28,3 +28,33 @@ graph TD
- creation of Task Duplicate (with link for monitoring and number of retry) and transfer output creation responsibility
- Task resubmission
- copy of task metadata with new id

## Status state diagram

```mermaid
stateDiagram-v2
[*] --> Creating: Task is created in the db
Creating --> Pending: Dependencies are not available<br/>Creation rpc succeeds
Pending --> Submitted: Dependencies are available<br/>Task is inserted into the queue<br/>Session is running
Submitted --> Paused: Session is paused
Paused --> Submitted: Session is resumed
Pending --> Paused: Dependencies are available<br/>Session is paused
Submitted --> Dispatched: Task is acquired
Dispatched --> Processing: Task is sent to the worker
Dispatched --> Submitted: Task acquisition timeout
Processing --> Completed: Task succeeds
Processing --> Error: Task fails, no retry
Processing --> Retried: Task fails, recovery possible<br/>A new task is created
Processing --> Timeout: Task exceeds MaxDuration
Creating --> Cancelled: Task is marked as cancelled
Submitted --> Cancelled: Task is marked as cancelled
Dispatched --> Cancelled: Task is marked as cancelled
Processing --> Cancelled: Task is hardly cancelled
Paused --> Cancelled: Task is marked as cancelled
Dispatched --> Paused: Session is paused
Cancelled --> [*]
Timeout --> [*]
Completed --> [*]
Retried --> [*]
Error --> [*]
```

0 comments on commit fd5af23

Please sign in to comment.