Azure Container Apps Scale to Zero with KEDA Queue Trigger
A containerized booking backend deployed to Azure Container Apps must scale to zero when idle and scale out based on queue length. What should the developer configure?
Quick Answer
The correct answer is a KEDA-based scale rule for the queue trigger. This is because Azure Container Apps natively integrates with KEDA (Kubernetes Event-Driven Autoscaling) to enable event-driven scaling, allowing a containerized booking backend to scale to zero replicas when the Azure Queue Storage is empty and scale out dynamically as queue length grows. On the AZ-204 exam, this scenario tests your understanding of how to configure custom scale rules beyond the default HTTP-based scaling, often appearing in questions about cost optimization and idle resource management. A common trap is confusing KEDA with standard Azure Autoscale, which cannot scale to zero; remember that KEDA is the only native solution for zero-replica scaling in Container Apps. Memory tip: KEDA = "Kill Empty, Deploy Active" — it kills idle pods and deploys more when the queue demands action.
⚠ Common exam trap
Many exam-takers confuse Azure Front Door health probes (used for traffic routing) with scaling triggers, or assume manual replica counts or Availability Sets are relevant to container scaling, when in fact KEDA is the specific technology for event-driven scaling in Azure Container Apps.
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
✓
A KEDA-based scale rule for the queue trigger
KEDA (Kubernetes Event-Driven Autoscaling) is natively integrated with Azure Container Apps to enable event-driven scaling. By configuring a KEDA-based scale rule with an Azure Queue Storage trigger, the container app can scale to zero replicas when the queue is empty and scale out based on the queue length, meeting the requirement for idle scaling and queue-driven scaling.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
A manual replica count only
Why it's wrong here
A fixed manual replica count never reacts to queue length and cannot scale to zero, so idle periods still incur replicas. It is tempting because manual scaling gives predictable capacity for steady workloads, and would be right when traffic is constant and cost predictability outweighs elasticity.
- ✗
An Availability Set
Why it's wrong here
Availability Sets spread virtual machines across fault and update domains for resilience; they have no bearing on replica counts or queue-based triggers. It is tempting because Availability Sets do address high availability, which would be correct for IaaS virtual machines, but Container Apps handles availability through its managed platform.
- ✗
An Azure Front Door health probe
Why it's wrong here
Front Door health probes only monitor endpoint availability and route traffic; they cannot trigger replica scaling. It is tempting because Front Door does provide health-based failover, which would be the right choice for distributing and load-balancing inbound HTTP traffic across regions, not for queue-driven scale.
- ✓
A KEDA-based scale rule for the queue trigger
Why this is correct
KEDA's queue-length scaler polls the storage queue and drives replica count directly, including scaling to zero when the queue empties. This satisfies both constraints: idle-to-zero behaviour and queue-depth-driven scale-out, which Container Apps' default HTTP rules cannot provide.
Go deeper
Related to this question
About these practice questions
Courseiva writes every AZ-204 question from scratch — 883 in total, each with an explanation and a wrong-answer breakdown. None are copied from real exams or dumps. Learn why practice questions differ from exam dumps →
Same concept, more angles
1 more way this is tested on AZ-204
These questions test the same concept from different angles. Work through them to make sure you can recognise it however the exam phrases it.
Variation 1. A containerized checkout API deployed to Azure Container Apps must scale to zero when idle and scale out based on queue length. What should the developer configure?
hard- ✓ A.A KEDA-based scale rule for the queue trigger
- B.A manual replica count only
- C.An Availability Set
- D.An Azure Front Door health probe
Why A: Azure Container Apps supports KEDA (Kubernetes Event-Driven Autoscaling) for scaling based on external metrics. A KEDA-based scale rule configured with an Azure Queue Storage trigger allows the containerized checkout API to scale to zero when no messages are in the queue and scale out dynamically as queue length increases, meeting the requirement precisely.
JA
Written by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
This AZ-204 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-204 exam.