GCP's database portfolio has two notable products: Firestore (NoSQL for mobile and web) and Spanner (global-scale SQL). Both solve different problems from classic databases.
01. Firestore: Real-time NoSQL
Firestore is a document-based NoSQL database. Its biggest feature: real-time synchronization. If a change happens in a mobile app, it reflects instantly to all clients watching the same data.
02. Firestore Use Cases
Where Firestore shines:
- Chat applications
- Mobile games
- Real-time dashboards
- Storing user profiles and preferences
03. Spanner: Global-Scale SQL
Spanner provides globally distributed scale while preserving SQL semantics. ACID transactions work consistently even with a node on the other side of the world.
04. Spanner Use Cases
Where Spanner is suitable:
- Global finance applications
- Global inventory management
- International e-commerce
- Airline booking systems
05. Alternative: Cloud SQL
At small-to-medium scale, if classic MySQL/PostgreSQL is enough, Cloud SQL is used. Spanner's power is usually not needed.