-
-
Notifications
You must be signed in to change notification settings - Fork 7
Research on P2P Databases
Requirements: Looking for a DB which is P2P in nature (like torrent, OrbitDB, DefraDB) but also distributed (like Cassandra, mongo).
Research on P2P Database systems reveals interesting characteristics and limitations of current solutions in the decentralized database space.
OrbitDB operates as a serverless, peer-to-peer database built on IPFS infrastructure. Its key characteristics include:
- Each database instance is a single document or log with fixed write permissions.
- Uses IPFS for data storage and IPFS PubSub for synchronization.
- Implements CRDTs (Conflict-Free Replicated Data Types) for conflict resolution.
- Eventually consistent model requires
full dataset replication
. - Lacks true distribution capabilities.
DefraDB represents a newer approach to decentralized databases with enhanced features:
- NoSQL database with flexible storage options.
- Uses MerkleCRDTs and IPLD for content addressing.
- Supports GraphQL-compatible query language (DQL).
- Implements peer-to-peer networking capabilities.
- Multi-write-master architecture.
- User-centric design with privacy features.
- Document-level and field-level policy support.
- Horizontal scaling capabilities.
-
Query functionality limited to local data
.
Feature | OrbitDB | DefraDB |
---|---|---|
Distribution | Full replication | Selective subscription |
query search scope | local data | searches only in local data |
Both systems demonstrate the challenges of balancing true peer-to-peer architecture with distributed database capabilities. While OrbitDB focuses on pure P2P functionality, DefraDB attempts to bridge the gap between P2P and distributed systems, though neither fully achieves both objectives simultaneously.
Cassandra is extremely capable p2p distributed Database (kindly note: here p2p refers to master-master architecture not public p2p like web3, torrent, blockchain)
Approach is to use them as a stack and achieve our goals (WIP)