feat(daemon): snapshot ticker + writer wiring + stopped-attach reads disk + cleanup on close
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -61,6 +61,9 @@ async fn run_daemon() -> Result<()> {
|
||||
let events_path = lifecycle::spacesh_dir()?.join("events.json");
|
||||
let event_store: std::sync::Arc<dyn event_store::EventStore> =
|
||||
std::sync::Arc::new(event_store::JsonEventStore::new(events_path));
|
||||
let snapshots_dir = lifecycle::spacesh_dir()?.join("snapshots");
|
||||
let snapshot_store: std::sync::Arc<dyn snapshot_store::SnapshotStore> =
|
||||
std::sync::Arc::new(snapshot_store::JsonSnapshotStore::new(snapshots_dir));
|
||||
eprintln!("spaceshd listening on {}", sock.display());
|
||||
server::serve(&sock, store, event_store).await
|
||||
server::serve(&sock, store, event_store, snapshot_store).await
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user