Database
/Database
Database
Open LangGraph Server supports multiple database backends for persisting graph state, checkpoints, thread metadata, and message queues. Choose the right database solution based on your application's needs for performance, reliability, and scalability.
Quick Reference
| Database | Performance | Persistence | Scalability | Use Case |
|---|---|---|---|---|
⚡ Highest | ❌ None | 🧵 Single | Development/Testing | |
🚀 Fast | 💾 File-based | 🖥️ Single-server | Small apps | |
🏢 Enterprise | 💾 ACID | 🌐 Distributed | Production | |
⚡ Sub-millisecond | 💾 TTL-based | 🔄 Distributed | High-performance |
Storage Architecture
Open LangGraph Server uses a layered storage approach where different components can use different storage backends:
Each layer can be configured independently based on your performance and reliability requirements.
Configuration Priority
Open LangGraph Server automatically selects storage backends based on environment variables with this priority:
- Redis (if
REDIS_URLset andCHECKPOINT_TYPEmatches) - PostgreSQL (if
DATABASE_URLset) - SQLite (if
SQLITE_DATABASE_URIset) - Memory (fallback default)
Choosing the Right Storage
For Development & Testing
- Memory Storage: Fastest setup, no persistence needed
- SQLite: File-based persistence for local development
For Production Applications
- PostgreSQL: Enterprise-grade reliability and concurrent access
- Redis: High-performance caching with TTL management
For High-Performance Use Cases
- Redis: Sub-millisecond response times, distributed caching
- PostgreSQL + Redis: Combine durability with performance
Built with
Show your support! Star us on GitHub ⭐️