Skip to content

Commit 61abf91

Browse files
committed
Edits and updated diagrams
1 parent 1524c32 commit 61abf91

File tree

4 files changed

+6
-4
lines changed

4 files changed

+6
-4
lines changed

docs/component-status.md

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ The system defines six statuses, listed in the table below:
1212
| OK | The component is running without issue. |
1313
| RecoverableError | The component has experienced a transient error and may recover. |
1414
| PermanentError | The component has detected a condition at runtime that will need human intervention to fix. The collector will continue to run in a degraded mode. |
15+
| FatalError | A component has experienced a fatal error and the collecctor will shutdown. |
1516
| Stopping | The component is in the process of shutting down. |
1617
| Stopped | The component has completed shutdown. |
1718

@@ -26,6 +27,7 @@ Statuses can be categorized into two groups: lifecycle and runtime.
2627
- OK
2728
- RecoverableError
2829
- PermanentError
30+
- FatalError
2931

3032
### Transitioning Between Statuses
3133

@@ -34,17 +36,17 @@ There is a finite state machine underlying the status reporting API that governs
3436

3537
![State Diagram](img/component-status-state-diagram.png)
3638

37-
The finite state machine ensures that components progress through the lifecycle properly and it manages transitions through runtime states so that components do not need to track their state internally. Only changes in status result in new events being generated; repeat reports of the same status are ignored. PermanentError is a permanent runtime state. A component in this state can transition to Stopping, but not to OK or RecoverableError.
39+
The finite state machine ensures that components progress through the lifecycle properly and it manages transitions through runtime states so that components do not need to track their state internally. Only changes in status result in new events being generated; repeat reports of the same status are ignored. PermanentError and FatalError are permanent runtime states. A component in these states cannot make any further state transitions.
3840

3941
![Status Event Generation](img/component-status-event-generation.png)
4042

4143
### Automation
4244

43-
The collector is responsible for starting and stopping components. Since it knows when these events occur and their outcomes, it can automate status reporting of lifecycle events for components.
45+
The collector's service implementation is responsible for starting and stopping components. Since it knows when these events occur and their outcomes, it can automate status reporting of lifecycle events for components.
4446

4547
**Start**
4648

47-
The collector will report a Starting event when starting a component. If an error is returned from Start, the collector will report a PermanentError event. If start returns without an error and the collector hasn't reported status itself, the collector will report an OK event.
49+
The collector will report a Starting event when starting a component. If an error is returned from Start, the collector will report a PermanentError event. If start returns without an error and the component hasn't reported status itself, the collector will report an OK event.
4850

4951
**Shutdown**
5052

@@ -67,7 +69,7 @@ We intend to define guidelines to help component authors distinguish between rec
6769

6870
A component should never have to report explicit status during shutdown. Automated status reporting should handle all cases. To recap, the collector will report Stopping before Shutdown is called. If a component returns an error from shutdown the collector will report a PermanentError and it will report Stopped if Shutdown returns without an error.
6971

70-
### In the Weeds
72+
### Implmentation Details
7173

7274
There are a couple of implementation details that are worth discussing for those who work on or wish to understand the collector internals.
7375

-1.68 KB
Loading
13 KB
Loading
-17.3 KB
Loading

0 commit comments

Comments
 (0)