- LPU MCA Semester 1
- CAP570
- Unit 6
CAP570 · Unit 6: Advanced databases
Cloud databases and NewSQL
10 practice questions · in the ETE syllabus
Key points
- DBaaS: the provider manages infrastructure; the customer owns data and access
- Cloud databases are elastic and pay-as-you-go
- NewSQL = SQL + ACID + horizontal scale
- Sharding distributes rows across nodes
A cloud database runs on a cloud platform and is offered as Database as a Service (DBaaS). The provider handles hardware, power, patching and backups, while the customer designs the schema and controls access to the data. Typical benefits are elastic scalability (capacity grows or shrinks on demand), pay-as-you-go pricing and easy replication. Examples include Amazon RDS, Google Cloud SQL and Azure SQL Database.
NewSQL databases aim to combine the scalability of NoSQL with the SQL language and ACID transactions of traditional relational systems. They distribute data across many nodes (horizontal partitioning, or sharding) while keeping strong consistency. Examples include Google Spanner, CockroachDB and VoltDB.
| Family | Scaling | Transactions | Query language |
|---|---|---|---|
| Traditional RDBMS | Mostly vertical | ACID | SQL |
| NoSQL | Horizontal | Often relaxed | Varies |
| NewSQL | Horizontal | ACID | SQL |
Sharding places rows on nodes by a rule such as id % 3, so ids 1, 4, 7 go to one node and 2, 5 to another.
Exam trap: NewSQL is not NoSQL. It keeps SQL and ACID, and it is the scale-out relational option.
Try two questions
A start-up expects traffic that may jump suddenly. Which cloud database property helps most?
- Fixed capacity, so the number of servers never changes
- Local installation, so each user keeps their own copy of the data
- Elastic scalability, so capacity can grow quickly and shrink when demand falls
- Manual hardware upgrades, so growth waits for new machines
Show the answer
C. Elasticity lets a cloud database follow demand and costs only what is used.
Why not A: Fixed capacity cannot absorb sudden growth.
Why not B: Local copies are not shared and do not scale a service.
Why not D: Manual upgrades are slow.
Which pair of properties do traditional relational databases offer but many NoSQL systems relax?
- Horizontal scaling and flexible schemas
- Key-value access and eventual consistency
- Strong consistency and ACID transactions
- Replication and partition tolerance
Show the answer
C. NoSQL often trades strict consistency for scale and availability.
Why not A: Those are strengths often associated with NoSQL.
Why not B: Eventual consistency is a NoSQL trait, not a relational guarantee.
Why not D: NoSQL systems provide both.