AZ-305 ยท Relational data design
Scaling relational databases up, out and for reads
Vertical scaling, read scale-out replicas, Hyperscale named and HA replicas, horizontal sharding with elastic database tools, scaling flexible servers.
Key points
- Scale up: change vCores.
- Read scale-out: Premium, Business Critical, Hyperscale; ApplicationIntent=ReadOnly; replicas lag; not General Purpose (use a geo-replica).
- Hyperscale: HA replicas (0-4, same name and size), named replicas (up to 30, own name, size, logins, same-region server).
- Sharding: Elastic Database client library, split-merge, elastic jobs.
- PostgreSQL flexible server: up to 5 read replicas, not on Burstable.
Source: https://learn.microsoft.com/en-us/azure/azure-sql/database/elastic-scale-introduction
Practice questions
A Business Critical database has read scale-out enabled. Which connection string setting sends a reporting tool to the read-only replica?
- ApplicationIntent=ReadOnly
- ApplicationIntent=ReadWrite
- MultiSubnetFailover=True
- Encrypt=True
Show answer
Answer: A. ApplicationIntent=ReadOnly
ApplicationIntent=ReadOnly routes the session to a read-only replica; ReadWrite (the default, also used when the keyword is missing) goes to the primary. MultiSubnetFailover and Encrypt control failover behaviour and TLS, not replica routing.
In Azure SQL Database, which service tiers support read scale-out?
- Premium
- General Purpose
- Business Critical
- Standard
- Hyperscale (with at least one secondary replica)
Show answer
Answer: A. Premium, C. Business Critical, E. Hyperscale (with at least one secondary replica)
Premium and Business Critical include read-only replicas as part of their HA design, and Hyperscale supports read scale-out once it has at least one secondary replica. Basic, Standard and General Purpose have no replicas, so read scale-out cannot be enabled there; a geo-replica is the workaround.
A row written on the primary replica is guaranteed to be visible immediately to a session reading from a read-only replica.
Show answer
Answer: False
False. Reads on read-only replicas are asynchronous to the primary. Propagation usually takes from tens of milliseconds to a few seconds, with no fixed upper bound. Code that must read its own writes straight away should query the primary.
Practice 8 questions on this topic in Bitzu
Short lessons, instant explanations and spaced review of what you get wrong. Free on iOS and Android.
