Microsoft AZ-204: Azure Functions and Serverless Computing — Study Guide

Part of the Microsoft Azure Developer Associate AZ-204 — Study Guide. Practice with verified answers in the Microsoft exam hub, or take timed practice tests on ExamRoll.io.

Overview

Azure Functions is a serverless compute service optimized for event-driven and short-lived workloads. It abstracts infrastructure so you focus on code that responds to events from HTTP endpoints, queues, blobs, data change feeds, and streaming services. You select a hosting plan that governs scaling, pricing, and cold-start behavior; bind your code to triggers and data sources with declarative bindings; and optionally compose long-running, reliable workflows using Durable Functions. Robust configuration, repeatable deployment, and deep observability with Application Insights round out the platform for production-grade systems.

Hosting Plans, Scaling, and Cold Starts

Selecting a hosting plan drives execution characteristics and cost.

Choose Consumption for cost-optimized sporadic workloads, Premium for low-latency and VNET needs, and Dedicated when consolidating with existing App Service capacity or requiring full control. For ultra-low latency, Premium with pre-warmed instances or Dedicated with Always On reduces cold starts. Minimize cold start impact further by trimming dependencies, using run-from-package, and initializing clients lazily.

Triggers and Bindings

Functions are activated by triggers and interact with data via bindings. Triggers define how and when a function runs. Bindings declaratively connect to external services for input/output without imperative SDK code.

Common triggers:

Bindings:

Design triggers and bindings for idempotency, backpressure, and failure isolation. For at-least-once delivery sources (queues, Event Hubs, Service Bus), write functions as idempotent and resilient to retries.

Durable Functions: Reliable Orchestration Patterns

Durable Functions extends Azure Functions with stateful, reliable orchestration for long-running workflows using a durable task framework.

Function types:

Patterns:

Durable Functions guarantee at-least-once execution of activities and exactly-once progression of orchestrator state. They persist state in storage (default is Azure Storage); ensure the storage account meets throughput and reliability needs. Use custom retry policies for transient failures and raise events for external interaction. For very long processes, durable orchestrations can run for days to months with built-in durability.

Configuration, Deployment, and Observability

Function app configuration is layered and environment-aware.

Deployment options:

Monitoring with Application Insights:

Operate functions with deployment automation (GitHub Actions/Azure Pipelines), health probes for HTTP endpoints, and autoscale-aware tuning. Keep packages lean, cache clients (e.g., HttpClient, Service Bus client) as static singletons, and validate that binding connection settings resolve at startup to prevent runtime failures.

Practical Problem Scenario

Contoso Retail launches a promotion service that applies discounts in real time when customers add items to their cart. The backend must respond to high-variance traffic with low latency, call a third-party pricing API, and update a Cosmos DB cart document. Operations wants zero-downtime deployments and deep visibility into failures.

  1. Choose the hosting plan and structure the app
  1. Implement Durable orchestration for reliability and parallelism
  1. Configure triggers and bindings for simplicity
  1. Optimize configuration and deployment
  1. Monitor and operate

Why these choices:


Azure App Service and Web Apps · All domains · Azure Storage and Blob Storage

Practice these questions → · Timed practice on ExamRoll.io →

Pass the whole exam — not just this question

You found this answer. Get every verified question and explanation in one place, and save hours of prep. Free to start.

Pass your exam →

Browse Microsoft →

Related guides

All-in-one access

One subscription. Every exam.

Every plan unlocks unlimited answer search, practice tests, AI explanations, and the full resource library — in 20+ languages.

Monthly
24.87
Just €0.83/day
Everything included:
  • Unlimited answer search
  • Unlimited practice tests
  • AI-powered explanations
  • Full resource library
  • 20+ languages
  • Weekly content updates
  • Rewards & referrals
  • Priority support
Start free trial

No credit card required*

Best value
12 months
179.87
Just €0.49/daySave 40%
Everything included:
  • Unlimited answer search
  • Unlimited practice tests
  • AI-powered explanations
  • Full resource library
  • 20+ languages
  • Weekly content updates
  • Rewards & referrals
  • Priority support
Start free trial

No credit card required*

✓ Free plan included · ✓ Cancel anytime · ✓ All plans unlock the full product