Clean up
This commit is contained in:
@@ -260,17 +260,22 @@ Recommended direction:
|
||||
|
||||
### 7. Persistence should be more asynchronous and debounced
|
||||
|
||||
`SavePersistentState()` is still called directly from many update paths.
|
||||
Status: addressed by Phase 6.
|
||||
|
||||
Relevant code:
|
||||
|
||||
- `RuntimeHost.cpp`
|
||||
- `RuntimeCoordinator.cpp`
|
||||
- `RuntimeUpdateController.cpp`
|
||||
- `RuntimeStore.cpp`
|
||||
- `PersistenceWriter.cpp`
|
||||
|
||||
Recent OSC work already reduced this problem for live automation, but the broader architecture would still benefit from:
|
||||
Runtime-state persistence now flows from accepted coordinator mutations to typed persistence events, then into a debounced background writer. The store still owns serialization and preset IO, while the writer owns temp-file replacement, coalescing, result reporting, and shutdown flushing.
|
||||
|
||||
- a debounced persistence queue
|
||||
- atomic write-behind snapshots
|
||||
- clear separation between state mutation and disk flush
|
||||
The remaining architecture concern is broader persistence policy, not direct mutation-path disk writes:
|
||||
|
||||
- whether preset saves should stay synchronous
|
||||
- whether runtime config writes should share the persistence writer
|
||||
- whether failed writes should retry automatically or wait for the next request
|
||||
|
||||
This improves both resilience and timing safety.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user