- Caching Before read load on db or service.
- Client side, server side.
- Database Replication Increase ready only instance
- Load Balancing Distribute read traffic across the resource.
- Data partitioning Sharding
- Parallel data retrieval and concurrency.
- Decrease latency
- Query Optimisation
- Indexing (query specific indexing)
- Frequently used query.
- Use procedure to execute multiple statement in single query. ( it uses precompiled query, that executes faster)
Database Optimisation Column database like. Cassandra
- Asynchronous Processing (use Buffer or Queue)
- Write Batching and buffering
- Data Patronising (chunking, and processing)
- CQRS (Command Query Responsibility Segregation)
- Event Sourcing
- Caching (Redis, and Memcached)
- Ram based storage
- (Redis)Single threaded,
- High throughput (1-10Gbit/s), sub-milliseconds fast
- PUB/SUB
- Caching
- Wide Column DB Cassandra
- No joins DB,
- Denormalised data,
- Decentralised
- Supports write heavy query
- Same as key value stores
- Scheme-less
-
Document DB/NoSql MongoDB, DynamoDB
- Read heavy System
- Collection based
-
Relational DB MySQl, Postgres, CockroachDB
- Relational Schema
- ACID compliant
Not every single NoSQL database is ACID-compliant, but many are. In fact, MongoDB is an ACID-compliant database
CockroachDB is distributed SQL database, which is highly scalable. that can be scale horizontal with it's builtin support.
-
Graph DB Neo4J
- Used for recommendation system, and social connections
- Connection is edge between nodes
-
Search DB Elastic Search, Algolia
- It uses precompiled indexing over tokens generated or data processed from datasource (database: Nosql, SQL. etc).
- Use case: Search engine, Typeahead feature.
-
Multi-modal GgraphQL
- ACID Compliant
- Flexible over query