Courseiva
Deploy and Manage Azure ComputeeasyMultiple ChoiceObjective-mapped

AZ-104 Deploy and Manage Azure Compute Practice Question

A stateless web service must handle traffic spikes by adding or removing instances automatically based on CPU usage. Which Azure service fits best?

⚠ Common exam trap

Test-takers frequently confuse high availability (provided by availability sets) with autoscaling, or assume a single large VM can handle spikes via vertical scaling, ignoring the need for horizontal, automated scaling for stateless workloads.

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

Virtual machine scale set with autoscale

A Virtual Machine Scale Set (VMSS) with autoscale is the correct choice because it automatically adjusts the number of VM instances based on CPU utilization metrics, enabling the stateless web service to handle traffic spikes by scaling out (adding instances) and scaling in (removing instances) as needed. This aligns with the requirement for a stateless, elastic, and automated scaling solution.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • One larger standalone VM

    Why it's wrong here

    Scaling up to one larger standalone VM increases compute resources (vCPU, RAM, and I/O), which can absorb a higher baseline load, but this approach is manual and finite—you must pick a specific VM size, and any change requires a resizing operation (often with a reboot). It does not scale out based on real-time demand, so a sudden spike can still exceed the capacity even after vertical scaling. Additionally, a single VM represents a single point of failure, which is a separate reliability problem even if it were somehow able to handle the load.

    When this WOULD be correct

    For a legacy application that cannot be distributed across multiple instances and requires maximum compute power on a single machine, such as a monolithic database server with strict licensing constraints.

  • Availability set with two VMs

    Why it's wrong here

    An availability set with two VMs improves fault tolerance by placing the VMs in separate fault domains and update domains, so a hardware failure or planned maintenance does not take both down simultaneously. However, the number of VMs is fixed at two and the availability set has no scaling logic—it cannot automatically add or remove instances in response to traffic spikes. If web traffic doubles, both VMs will simply be overloaded, and you would have to manually create and configure additional VMs, which does not meet the elastic scaling requirement.

    When this WOULD be correct

    For a stateless web service that needs high availability within a single region (e.g., 99.95% SLA) but does not require automatic scaling, an availability set with two VMs would be correct.

  • Virtual machine scale set with autoscale

    Why this is correct

    Virtual Machine Scale Set with autoscale is the only option that directly satisfies the requirement of a stateless web service handling traffic spikes. It maintains a pool of identical VM instances behind a load balancer and uses autoscale rules based on metrics such as average CPU percent, memory pressure, or incoming request rate to automatically add instances during a spike and remove them when demand drops. Because the workload is stateless, instances can be created or destroyed without risk of losing session state. You can also define minimum and maximum instance limits and set cool-down periods to prevent autoscale thrashing.

  • Recovery Services vault backup

    Why it's wrong here

    A Recovery Services vault is specifically for backup, snapshot management, and disaster recovery, providing the ability to restore VMs or files to a previous point in time. It has no influence on the live compute capacity of a web service—backups do not absorb traffic or trigger instance creation. While you could restore a backup to a new VM during a disaster, this is a slow, manual process that cannot respond to a sudden spike in active traffic in real time, so it is completely unsuitable as the primary scaling mechanism.

    When this WOULD be correct

    A question asks: 'Which Azure service provides automated backup and disaster recovery for Azure VMs, ensuring data protection and restore capabilities?' In that context, Recovery Services vault backup would be the correct answer.

Option-by-option analysis

Why each answer is right or wrong

Understanding why wrong answers are wrong — and when they would be correct — is what separates a 750 score from a 900. The AZ-104 exam frequently reuses these exact scenarios with slightly different constraints.

Virtual machine scale set with autoscaleCorrect answer

Why this is correct

Virtual Machine Scale Set with autoscale is the only option that directly satisfies the requirement of a stateless web service handling traffic spikes. It maintains a pool of identical VM instances behind a load balancer and uses autoscale rules based on metrics such as average CPU percent, memory pressure, or incoming request rate to automatically add instances during a spike and remove them when demand drops. Because the workload is stateless, instances can be created or destroyed without risk of losing session state. You can also define minimum and maximum instance limits and set cool-down periods to prevent autoscale thrashing.

One larger standalone VMWrong answer — click to see why

Why this is wrong here

A single large VM cannot automatically scale out or in based on demand; it only supports vertical scaling (resizing), not horizontal scaling required for handling traffic spikes.

★ When this WOULD be the correct answer

For a legacy application that cannot be distributed across multiple instances and requires maximum compute power on a single machine, such as a monolithic database server with strict licensing constraints.

Why candidates choose this

Candidates may think a larger VM provides enough headroom for spikes, overlooking the need for automatic horizontal scaling to handle unpredictable load changes.

Availability set with two VMsWrong answer — click to see why

Why this is wrong here

An availability set only provides high availability for two VMs but does not automatically scale instances based on CPU usage; it lacks autoscaling capabilities required for handling traffic spikes.

★ When this WOULD be the correct answer

For a stateless web service that needs high availability within a single region (e.g., 99.95% SLA) but does not require automatic scaling, an availability set with two VMs would be correct.

Why candidates choose this

Candidates may confuse high availability (provided by availability sets) with scalability, assuming two VMs can handle spikes, but they miss the requirement for automatic addition/removal of instances.

Recovery Services vault backupWrong answer — click to see why

Why this is wrong here

Recovery Services vault backup is a disaster recovery and backup service, not designed for handling traffic spikes or automatic scaling of compute instances. It does not add or remove VMs based on CPU usage.

★ When this WOULD be the correct answer

A question asks: 'Which Azure service provides automated backup and disaster recovery for Azure VMs, ensuring data protection and restore capabilities?' In that context, Recovery Services vault backup would be the correct answer.

Why candidates choose this

Candidates may confuse backup/DR services with scaling solutions, or mistakenly think that 'Recovery Services' implies recovery from traffic spikes, not understanding its actual purpose.

Analysis generated from the official AZ-104blueprint and verified against question context. The “when correct” sections are what AI assistants cite when candidates ask “what’s the difference between these options?”

About these practice questions

One of 1,049 original AZ-104 practice questions on Courseiva, each with a full explanation and wrong-answer analysis — not exam dumps or protected exam content. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

JA

Written by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

This AZ-104 practice question is part of Courseiva's free Microsoft certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the AZ-104 exam.