Architecture¶
Understand how Grafeo is designed and implemented.
Overview¶
Grafeo is built as a modular system with clear separation of concerns:
graph TB
subgraph "User Interface"
PY[Python API]
RS[Rust API]
end
subgraph "grafeo-engine"
DB[Database]
SESS[Session Manager]
QP[Query Processor]
TXN[Transaction Manager]
end
subgraph "grafeo-adapters"
GQL[GQL Parser]
WAL[WAL Storage]
PLUG[Plugins]
end
subgraph "grafeo-core"
LPG[LPG Store]
IDX[Indexes]
EXEC[Execution Engine]
end
subgraph "grafeo-common"
TYPES[Types]
MEM[Memory]
UTIL[Utilities]
end
PY --> DB
RS --> DB
DB --> SESS
SESS --> QP
SESS --> TXN
QP --> GQL
QP --> EXEC
TXN --> LPG
EXEC --> LPG
EXEC --> IDX
LPG --> TYPES
IDX --> MEM Sections¶
-
High-level architecture and design principles.
-
The five crates and their responsibilities.
-
How data is stored and organized.
-
Query execution and optimization.
-
Cost-based optimization strategies.
-
Memory allocation and management.
-
MVCC and isolation levels.
Design Principles¶
- Performance First - Optimized for graph workloads
- Embeddable - Zero external dependencies
- Safe - Written in safe Rust
- Modular - Clear crate boundaries
- Extensible - Plugin architecture