Skip to content

Commit dad3632

Browse files
author
Michal Tichák
committed
[docs] add summary of virtual states into the operation_order.md
1 parent fd5d7a5 commit dad3632

File tree

1 file changed

+16
-0
lines changed

1 file changed

+16
-0
lines changed

docs/handbook/operation_order.md

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -102,3 +102,19 @@ This is the order of actions happening at a healthy end of run.
102102
- `after_STOP_ACTIVITY` hooks with positive weights (incl. 0) are executed:
103103
- `ccdb.RunStop()` at `0`
104104
- `bookkeeping.UpdateRunStop()`, `bookkeeping.UpdateEnv()` at `+100`
105+
106+
## Virtual (manager-driven) states and transitions
107+
108+
State **PENDING** and transitions **TEARDOWN**, and **DESTROY** lie outside the core FSM in `environment.go` and are driven by the Manager. See [core/environment/manager.go](https://github.com/AliceO2Group/Control/blob/master/core/environment/manager.go) for details.
109+
110+
### State PENDING
111+
112+
Before the FSM enters `STANDBY`, the Manager drives the initial creation steps by emitting `Ev_EnvironmentEvent` messages (`Transition: CREATE`) for both `before_CREATE` (running hooks) and `CREATE` (loading workflow).
113+
114+
### Transition TEARDOWN
115+
116+
When the FSM is in `RUNNING`, the Manager records both `run_end_time_ms` and `run_end_completion_time_ms` and emits message `Ev_RunEvent` with content (`Transition: TEARDOWN`, `OpStatus_STARTED`) for each of timestamps.
117+
118+
### Transition DESTROY
119+
120+
The Manager’s `TeardownEnvironment(...)` drives a four‑step `Ev_EnvironmentEvent` sequence (`before_DESTROY`, `leave_<state>`, `DESTROY`, `after_DESTROY`) on `topic.Environment` to release tasks, run hooks, and finalize teardown.

0 commit comments

Comments
 (0)