Lesson 2 of 4 Relational Data Solutions

Selecting Azure SQL Service and Compute Tiers

This lesson explains purchasing models, service tiers and compute tiers.

Learning outcomes

After completing this lesson, you will be able to:

  • Compare the DTU and vCore models.
  • Compare General Purpose, Business Critical and Hyperscale.
  • Distinguish provisioned from serverless compute.
  • Describe the SQL Managed Instance tiers.

Purchasing models

Azure SQL Database has two purchasing models. The DTU model sells a bundled measure of CPU, memory and I/O, in Basic, Standard and Premium tiers. It is simple and predictable, but compute and storage cannot be sized independently. The vCore model specifies the number of virtual cores, hardware and storage separately. Microsoft recommends the vCore model for most new work, as it gives flexibility, supports Azure Hybrid Benefit and reserved capacity, and provides the General Purpose, Business Critical and Hyperscale tiers.

A database can change between models. A useful rule of thumb when converting is that about 100 DTUs in Standard corresponds to one vCore in General Purpose, although actual sizing should be measured.

Fill in the value

DTU to vCore

Exam skills 2.1.2

Use the rule of thumb to convert DTU sizes into vCores.

Log in to try this activity Interactive activities are free with an account.

General Purpose

General Purpose is the budget-oriented tier for typical business workloads. It separates compute from storage: a stateless compute node runs the engine, with data held on remote Azure Blob Storage. If the compute node fails, the platform starts a new one, attaches the storage and carries on. The tier supports up to 4 TB of data. Input and output latency is higher than local storage, and there is no built-in readable replica.

This separation explains how the tier behaves. Failover involves a short interruption because a new compute process must start, with a cold cache. General Purpose suits most applications that tolerate that behaviour and do not need the fastest storage.

Business Critical

Business Critical is the tier for workloads that need low latency and high resilience. It uses an Always On availability group of replicas, with data on fast local SSD storage on each node. One replica is the primary, and the others can take over within seconds. One of the secondary replicas is available without extra charge for read-only queries, so reporting can be separated from transactions. In-memory OLTP is also available in this tier.

Business Critical is significantly more expensive than General Purpose, because several copies of the compute run constantly. It supports up to 4 TB and has a much higher I/O limit. With active geo-replication, it offers a guaranteed RPO of 5 seconds and RTO of 30 seconds, which makes it the tier for strict recovery objectives.

Hyperscale

Hyperscale uses a distinct architecture: compute is separated from a set of page servers and a log service, with long-term data on Azure Storage. This gives two main benefits. Storage can grow to 128 TB, and backups and restores rely on storage snapshots, so they are fast regardless of size. Scaling compute up is fast too, because the data does not need to be copied.

Hyperscale also has the richest replica options: up to four high-availability secondaries, up to 30 named replicas for read scale-out, and geo-replicas. It supports up to 192 vCores, with very high I/O limits, and serverless compute. Hyperscale elastic pools are available, with up to 100 TB of pool storage. It suits large or rapidly growing databases, and for many new workloads it is a reasonable default tier.

Comparing the tiers

The following comparison summarizes the vCore tiers of Azure SQL Database.

General Purpose
Maximum data size4 TB
Maximum vCores128
StorageRemote Blob Storage
Free readable replicaNone
Serverless computeYes
Zone redundancyYes
Choose when Typical business workloads
Business Critical
Maximum data size4 TB
Maximum vCores128
StorageLocal SSD on each replica
Free readable replicaOne
Serverless computeNo
Zone redundancyYes
Choose when Low latency and fast failover
Hyperscale
Maximum data size128 TB
Maximum vCores192
StoragePage servers with local SSD caching
Free readable replicaNone; secondaries are billed
Serverless computeYes
Zone redundancyYes
Choose when Large or fast-growing databases

The following diagram matches three workloads to an Azure SQL Database service tier.

Choosing Azure SQL Database tiers for three workloads. A 40 TB database growing 2 TB a month exceeds the 4 TB limit of General Purpose and Business Critical, so Hyperscale with named replicas for reports fits. A tool used about an hour each morning suits serverless compute. An 800 GB trading database needing the lowest latency and fast failover suits Business Critical.
The scenario is illustrative.
Scenario questions

Choosing a tier

Exam skills 2.1.2

Choose the Azure SQL Database tier for each workload.

Log in to try this activity Interactive activities are free with an account.

Provisioned and serverless compute

A compute tier decides how compute is allocated. Provisioned compute keeps a fixed number of vCores available, and the cost is fixed. It suits steady workloads and those that need the fastest response at all times. Serverless compute scales automatically between a minimum and a maximum number of vCores, with billing per second for what is used.

Serverless is available on standard-series hardware in the General Purpose and Hyperscale tiers, but not in Business Critical. In General Purpose, a serverless database can auto-pause after a period of inactivity, with a delay between 15 minutes and seven days, or auto-pause can be disabled. During a pause, compute is not billed, only storage, but the first connection afterwards experiences a delay while the database resumes. Serverless therefore suits intermittent, unpredictable use, such as a development database or a new application with little traffic, and it does not suit applications that cannot tolerate that delay.

Sort into groups

Provisioned or serverless?

Exam skills 2.1.2

Choose the compute tier for each workload.

Log in to try this activity Interactive activities are free with an account.

SQL Managed Instance tiers

SQL Managed Instance has a similar division. General Purpose offers up to 16 TB and 100 databases per instance. The Next-gen General Purpose upgrade uses Azure Elastic SAN for better performance and raises limits to 32 TB, 128 vCores and 500 databases. Business Critical offers up to 16 TB, with local storage, three high-availability replicas and one free read-scale replica.

Storage is reserved in units of 32 GB and charged at the maximum size configured, whether used or not. An instance can also be stopped and started in General Purpose to save compute cost during idle periods. Instance pools allow several smaller instances to share resources, which can help smaller workloads during migration.

True or false

Managed Instance limits

Exam skills 2.1.2

Check the Managed Instance service tier facts.

Log in to try this activity Interactive activities are free with an account.
Worked example

Selecting tier and compute

An analytics startup has a 40 TB operational database that grows by 2 TB each month, and read reports must not affect transactions. A separate internal tool is used for about one hour each morning. A third database, supporting a trading system, requires the lowest possible latency and a fast failover, but it is only 800 GB. Which tier suits each?

The 40 TB database exceeds the 4 TB limit of General Purpose and Business Critical, so Hyperscale is the only suitable option in Azure SQL Database, and named replicas can serve reports. The internal tool suits General Purpose serverless with auto-pause, as it is idle for most of the day, and a short resume delay is acceptable.

The trading database should be Business Critical with provisioned compute, because of its local SSD storage and fast failover. Serverless would be wrong for it, since Business Critical does not offer serverless compute, and a resume delay would be unacceptable.

Check yourself

Why is a General Purpose failover slower than a Business Critical failover?

Show answer

A new compute process must start and attach remote storage with a cold cache, whereas Business Critical promotes a replica that is already running.

Exam Tips

Remember for the exam

  • vCore is the recommended model: General Purpose, Business Critical or Hyperscale.
  • General Purpose and Business Critical reach 4 TB; Hyperscale reaches 128 TB.
  • Business Critical has local SSD and one free readable replica, but no serverless compute.
  • Serverless auto-pause is for intermittent use and tolerates a resume delay.
  • Managed Instance: General Purpose 16 TB, Next-gen General Purpose 32 TB, Business Critical 16 TB.