rename crates/ to engrams/, bindings/ to receptors/

- crates/ → engrams/ (Rust engrams live here)
- bindings/ → receptors/ (cross-language access points into the graph)
- Cargo.toml workspace paths updated
This commit is contained in:
Will Anderson
2026-04-29 03:27:33 -05:00
parent 37c87da9a6
commit d1ec384b27
89 changed files with 2114 additions and 452 deletions
+19
View File
@@ -0,0 +1,19 @@
/// Shared application state for all request handlers.
use engram_core::EngramDb;
use engram_projection::registry::ProjectionRegistry;
use engram_sync::SyncEngine;
use engram_tx::TransactionEngine;
use std::sync::{Arc, Mutex};
pub struct AppState {
/// Local database — uses std::sync::Mutex (sync ops only, fast)
pub db: Arc<Mutex<EngramDb>>,
/// Sync engine — uses tokio::sync::Mutex so it can be held across .await
pub sync_engine: Arc<tokio::sync::Mutex<SyncEngine>>,
/// API key used to authenticate incoming sync requests
pub api_key: String,
/// Projection registry — named schema views over the activation surface
pub projection_registry: Arc<Mutex<ProjectionRegistry>>,
/// Transaction engine — append-only command log with rollback support
pub tx_engine: Arc<Mutex<TransactionEngine>>,
}