Home Exams Roadmap Resources Board Pricing
Home › Certifications › Azure certifications › AZ-204

Azure Developer AZ-204 Practice Test

Validates skills in developing and implementing AZURE cloud solutions. Covers App Service, Functions, and Storage.

Exam at a glance

Exam time
100 minutes
Exam questions
50
Passing score
700/1000
Valid for
1 years
Practice questions on CloudMasterIT
120

Exam domains and weighting

  • Develop Azure compute solutions — 30%

    Azure App Service, Azure Functions, Azure Container Apps, Azure Container Registry, Azure Kubernetes Service

  • Develop for Azure storage — 20%

    Azure Cosmos DB, Azure Blob Storage, Azure Table Storage, Azure Queue Storage, Azure Cache for Redis

  • Implement Azure security — 18%

    Microsoft Entra ID, Azure Key Vault, Managed Identity, SAS Tokens, MSAL

  • Monitor, troubleshoot, and optimize Azure solutions — 8%

    Application Insights, Azure Monitor, Azure CDN, Caching Strategies, Logging & Tracing

  • Connect to and consume Azure services and third-party services — 24%

    Azure API Management, Azure Event Grid, Azure Service Bus, Azure Event Hubs, Azure Logic Apps

Free AZ-204 sample questions

Try real exam-style questions from the free sample set. Each answer comes with a full explanation.

  1. A developer is configuring staging and production slots in Azure App Service and plans to perform a deployment slot swap. The staging slot has a test database connection string configured, and this value must remain in the staging slot even after the swap.

    What configuration must the developer apply to the app setting to meet this requirement?

    • A. Enable Deployment slot setting
    • B. Configure Azure Key Vault reference
    • C. Encrypt the Connection string
    • D. Integrate with App Configuration
    Show answer and explanation

    Answer: A. Enable Deployment slot setting

    The key condition in this problem is that the value must remain in the staging slot even after the swap. By default, Azure App Service deployment slot swaps exchange app settings and connection strings between slots, but enabling 'Deployment slot setting' pins that setting to the slot, excluding it from the swap. This ensures the test database connection string stays in the staging slot after the swap.

    Azure App Service deployment slots allow you to test code in an environment identical to production and achieve zero-downtime deployments through swaps. Both App Settings and Connection Strings have a 'Deployment slot setting' checkbox; enabling it makes the setting slot-specific. This lets the staging slot always point to the test database and the production slot always point to the production database—a pattern essential in enterprise environments where database isolation is critical.

    In the AZ-204 exam, deployment slot swap questions focus on distinguishing whether a setting 'moves with the swap' or 'stays fixed to the slot.' By default, most settings move during a swap; only settings with Deployment slot setting enabled are pinned. Key Vault references and App Configuration are for security and centralized management—separate from slot pinning. When you see 'setting must remain in a specific slot after swap,' always think Deployment slot setting.

  2. A developer operating an e-commerce platform built with a microservices architecture is analyzing response latency issues in the payment service.

    The payment service internally calls multiple dependent services including Redis cache, an external payment gateway API, and Azure SQL Database. The developer wants to visually understand the entire call flow to identify where the bottleneck occurs without modifying code.

    Which Application Insights feature BEST meets these requirements?

    • A. Application Map
    • B. Live Metrics Stream
    • C. Log Analytics Query
    • D. Availability Test
    Show answer and explanation

    Answer: A. Application Map

    The key clues in this question are 'without modifying code' and 'visually understand the entire call flow.' Application Map automatically visualizes service-to-service call relationships based on distributed tracing data, and works with Application Insights SDK or auto-instrumentation without requiring any code changes. It immediately reveals the bottleneck location by displaying response times and error rates for each dependent service as nodes and arrows.

    Application Map renders Azure's distributed tracing capability as a visual topology. In a microservices environment, each service component appears as a node and call relationships as edges (arrows), with each node showing average response time, request count, and failure rate. This lets you immediately see where latency is occurring among Redis, external APIs, and Azure SQL Database. The key point is that it can be enabled with App Service Auto-Instrumentation alone, without any code changes.

    For AZ-204 exam monitoring questions, you must clearly distinguish the purpose of each feature. Live Metrics Stream provides real-time performance monitoring but has no call flow visualization. Log Analytics analyzes logs with KQL queries but does not provide a graphical topology. Availability Test checks endpoint availability from external locations and is unrelated to internal dependency analysis. When 'visual call flow' and 'no code changes' are mentioned together, choose Application Map.

  3. A company wants to optimize storage costs for log files stored in Azure Blob Storage. Files should remain in the Hot tier for the first 30 days after creation (frequently accessed), move to the Cool tier for the next 90 days, transition to the Archive tier after 180 days, and be automatically deleted after 365 days.

    What is the MOST appropriate method to handle these requirements automatically without code or scripts?

    • A. Azure Functions Timer Trigger
    • B. Blob Storage lifecycle management policy
    • C. Azure Logic Apps schedule trigger
    • D. Azure Monitor alert + Runbook
    Show answer and explanation

    Answer: B. Blob Storage lifecycle management policy

    The key clues in this question are 'handle automatically without code or scripts' and specific day-based tier transition rules. Azure Blob Storage lifecycle management policies are a native feature that can precisely implement these requirements through JSON rules or the Azure Portal UI without code. Use daysAfterModificationGreaterThan or daysAfterCreationGreaterThan conditions to configure tier transitions and deletion separately.

    Azure Blob Storage Lifecycle Management is a policy-based feature that automatically transitions storage tiers or deletes blob data based on access patterns. It supports transitions between Hot, Cool, Cold, and Archive tiers as well as deletion, and applies to block blobs and append blobs. Policies can be applied as filters at the storage account level or container level, with conditions based on last modification time, last access time, or creation time. This feature runs automatically by Azure without separate code, schedulers, or serverless functions.

    On the exam, when 'automatic storage tier transitions,' 'day-based policies,' and 'automate without code' keywords appear together, Blob Storage lifecycle management policy is the answer. Azure Functions Timer Trigger requires writing code, violating the 'without code' condition. Logic Apps suits complex workflows but requires excessive configuration for simple storage tier management. Azure Monitor is a monitoring and alerting tool, not a dedicated solution for storage tier management.

  4. A developer is running an application that uses Azure Cosmos DB Change Feed Processor. When the application restarts after an abnormal shutdown, it must resume change feed processing from where it left off.

    What component does the Change Feed Processor use to store state information to guarantee this continuity?

    • A. Azure Blob Storage checkpoint
    • B. Cosmos DB Lease Container
    • C. Azure Table Storage offset
    • D. Event Hubs Checkpoint Store
    Show answer and explanation

    Answer: B. Cosmos DB Lease Container

    The key in this problem is the continuity requirement of "resuming from where it left off when restarting after an abnormal shutdown." Azure Cosmos DB's Change Feed Processor uses a Lease Container to store the processing progress state (continuation token) for each partition. When the application restarts, it reads the last processed position from the Lease Container and resumes change feed processing from that point.

    Cosmos DB Change Feed Processor is a library for distributed processing of the change feed, requiring two containers: the monitored container (the actual data container where changes occur) and the Lease Container. The Lease Container stores the continuation token representing the current processing position per partition and ownership information about which instance is processing which partition. This allows multiple instances to distribute partition processing, or for another instance to take over a partition when a failure occurs.

    On the AZ-204 exam, questions about Change Feed Processor frequently ask about the role of the Lease Container. The Lease Container and monitored container must be in the same Cosmos DB account. Azure Blob Storage checkpoints are for Event Hubs only, and Table Storage is not related to Change Feed Processor. When the keywords "storing processing state," "resuming after restart," and "checkpoint" appear in the context of Cosmos DB Change Feed, Lease Container is the answer.

  5. A data processing company wants to implement a large file conversion task using Azure Functions. A single file processing can take up to 20 minutes, and it must run reliably without cold starts during processing.

    Which Azure Functions hosting plan BEST meets these requirements?

    • A. Consumption Plan
    • B. Premium Plan
    • C. Flex Consumption Plan
    • D. App Service Free Tier
    Show answer and explanation

    Answer: B. Premium Plan

    The key clues in this problem are two requirements: 'up to 20-minute execution time' and 'no cold starts.' The Consumption Plan has a default timeout of 5 minutes and a maximum of 10 minutes, so 20-minute execution is impossible. The Premium Plan provides unlimited timeout (default 30 minutes, maximum unlimited) and maintains always-warm instances to guarantee reliable execution without cold starts.

    Azure Functions Premium Plan maintains the serverless model of the Consumption Plan while adding enterprise-grade features. It completely eliminates cold starts by always maintaining pre-warmed instances, and is suitable for long-running tasks with no timeout limits. It also supports VNET integration, more CPU/memory options, and unlimited execution duration. The Flex Consumption Plan supports demand-based scaling but cold starts can still occur.

    In the AZ-204 exam, Azure Functions hosting plan selection questions are frequently tested. Use the Consumption Plan for cost minimization and short-duration execution, Premium Plan for cold start elimination, long-duration execution, and VNET integration, and Dedicated (App Service) Plan when reusing an existing App Service Plan. When you see conditions like 'no cold starts' or 'execution exceeding 20 minutes,' you must choose Premium Plan. App Service Free Tier is not an Azure Functions-specific plan, making it incorrect.

Practice the full free sample set

Three ways to study

  • Practice modeSee the explanation right after each answer, so you learn as you go.
  • Study modeReview questions and explanations at your own pace, with no timer.
  • Exam modeA timed, randomized set that mirrors the real exam conditions.

Frequently asked questions

How many questions are on the AZ-204 exam?

The Microsoft Azure Developer Associate (AZ-204) exam consists of 50 questions with a 100-minute time limit.

What is the passing score for AZ-204?

The passing score for the AZ-204 exam is 700 out of 1000.

Is the AZ-204 practice test free?

The AZ-204 sample set (20 questions with full explanations) is free. The full bank of 120+ questions is available with a CloudMasterIT subscription.

How long is the AZ-204 certification valid?

The AZ-204 certification is valid for 1 years after passing. Recertification is required after that.

Study guides

  • Azure AZ-204 Guide: Retired July 2026, Succeeded by AI-200
  • Implementing App Service Web Apps
  • Implementing Azure Functions
  • Implementing Container Solutions
  • Developing Azure Cosmos DB Solutions
  • Developing Blob Storage Solutions
  • Official exam guide

Related certifications

  • AWS Developer Associate Practice Exam (DVA-C02)
  • AWS CloudOps Engineer Associate Practice Exam (SOA-C03)
  • Google Associate Cloud Engineer Practice Exam (ACE)
  • Google Cloud Digital Leader Practice Exam (CDL)
  • AWS Solutions Architect Professional Practice Exam (SAP-C02)
  • AWS DevOps Engineer Professional Practice Exam (DOP-C02)