AzureAZ-204

AZ-204 Azure Developer Associate: Building and Deploying Azure Applications

AZ-204 is Microsoft's developer certification for Azure. It validates that you can design, build, test, and maintain cloud applications and services on Azure. The exam is hands-on — questions present real development scenarios and require selecting the correct SDK call, configuration option, or service integration. If you write code that runs on Azure, AZ-204 is the credential that proves you understand the platform as a developer, not just as an administrator.

12 min
5 sections · 10 exam key points

Azure Compute: App Service, Functions, and Containers

App Service is the AZ-204 compute workhorse. App Service Plan (ASP) defines the underlying VM — all apps in the same ASP share compute. ASP tiers: Free/Shared (no SLA, shared infrastructure), Basic (dedicated VMs, manual scale), Standard (auto-scale, deployment slots, custom domains, SSL), Premium (more power, VNet integration, no cold start), Isolated (dedicated environment in your VNet — highest isolation, App Service Environment). Deployment slots: staging slot lets you deploy and warm up before swapping to production — swap routes all traffic instantly with rollback capability. Azure Functions: consumption plan (scale to zero, pay per execution, 5-minute default timeout), Premium plan (pre-warmed instances, no cold start, VNet integration, unlimited timeout), Dedicated plan (run on an ASP — manual scaling). Durable Functions extend Functions with stateful workflows: orchestrator functions (fan-out/fan-in, async HTTP, monitor pattern), entity functions (stateful actors). Containers: Azure Container Registry (private Docker registry), Azure Container Instances (single container, quick start, no orchestration), Container Apps (serverless Kubernetes — KEDA scaling, Dapr integration).

Azure Storage and Cosmos DB for Developers

Storage SDK patterns for AZ-204: Blob Storage (block blobs for files, append blobs for logs, page blobs for VHDs), SAS tokens (Shared Access Signatures — grant time-limited access to specific resources without exposing account key — service SAS for one service, account SAS for multiple services, user delegation SAS using Entra ID credentials — most secure), stored access policies (server-side policy that a SAS references — allows revocation by changing the policy). Azure Table Storage: NoSQL key-value store — partition key and row key form the composite primary key, queries within a partition are fastest. Queue Storage: simple message queue — 64 KB message size, 7-day TTL, dequeue count tracking for poison message detection. Cosmos DB SDK: choose consistency level per operation (strong, bounded staleness, session, consistent prefix, eventual), change feed (real-time stream of all inserts and updates — triggers downstream processing), TTL (time-to-live on containers or items for automatic expiry).

Azure Security for Developers

AZ-204 security is developer-focused. Managed Identity: system-assigned (tied to a single resource, deleted with resource) or user-assigned (independent resource, reusable across multiple services) — both eliminate credential management by obtaining tokens from Entra ID automatically. MSAL (Microsoft Authentication Library): the current SDK for acquiring tokens (replaces ADAL). OAuth 2.0 flows for different client types: auth code flow (web apps — server holds secret), auth code flow with PKCE (SPAs and mobile apps — no secret), client credentials flow (service-to-service — daemon apps). Microsoft Graph API: unified REST API for Microsoft 365, Teams, Entra ID, and OneDrive data — AZ-204 expects you to call Graph to read user profiles, send Teams messages, and query directory data. Key Vault SDK: retrieve secrets, keys, and certificates in application code using the DefaultAzureCredential (tries multiple auth methods in order — managed identity, CLI, VS Code, environment variables).

API Management and Event-Based Solutions

Azure API Management (APIM) is a gateway, developer portal, and management plane for APIs. Policies: transform requests and responses using XML-based policy expressions — rate limiting (rate-limit-by-key policy), IP filtering (ip-filter policy), JWT validation (validate-jwt policy), request/response transformation (set-header, rewrite-uri, find-replace). Policy scopes: global, product, API, operation — more specific scope overrides less specific. Inbound and outbound processing pipelines. Event Grid: event routing for discrete events — publishers (Azure services, custom topics), event subscriptions (filter by event type, route to subscribers: Functions, Logic Apps, Event Hubs, Service Bus). Event Grid schema vs CloudEvents schema (CloudEvents is the CNCF standard — preferred for cross-cloud compatibility). Service Bus: enterprise messaging — queues (point-to-point, FIFO, dead-letter), topics and subscriptions (pub/sub with filter rules). Service Bus sessions: message grouping for ordered processing (session-aware receivers process messages from one session sequentially). Event Hubs: high-throughput streaming (millions of events/second), partitioned consumer model (partition count = max parallelism), consumer groups (separate logical stream for each downstream consumer), Kafka protocol support.

Azure Caching, CDN, and Monitoring

Performance optimisation in AZ-204: Azure Cache for Redis (in-memory key-value store for session state, response caching, real-time data — tiers: Basic, Standard, Premium (geo-replication, VNet integration, clustering), Enterprise (Redis modules — Search, JSON, Bloom Filter)), cache patterns (cache-aside, read-through, write-through, write-behind), Redis data structures (strings, hashes, lists, sets, sorted sets — sorted sets for leaderboards). Azure CDN: cache static content at edge locations globally — profiles from Microsoft, Verizon, Akamai. CDN rules engine: redirect, rewrite, cache override, header manipulation. Azure Monitor for developers: Application Insights (APM — automatic dependency tracking, custom events and metrics via TrackEvent/TrackMetric, distributed tracing with operation ID, Live Metrics for real-time monitoring), Log Analytics workspace (store and query telemetry with KQL), Availability tests (web test from multiple locations — detect regional outages).

Key exam facts — AZ-204

  • App Service deployment slots: deploy to staging, warm up, swap to production — zero-downtime deployment
  • Durable Functions orchestrator: fan-out/fan-in, async HTTP polling, monitor pattern
  • User delegation SAS uses Entra ID credentials — most secure SAS token type
  • Managed Identity: system-assigned (per resource) vs user-assigned (reusable across resources)
  • MSAL replaces ADAL — use auth code + PKCE for SPAs and mobile, client credentials for daemons
  • Service Bus sessions enable ordered message processing within a group
  • Event Grid routes discrete events; Event Hubs streams high-throughput data (millions/sec)
  • DefaultAzureCredential tries multiple auth methods automatically — managed identity first
  • Cosmos DB change feed captures all inserts and updates in order — use for event-driven architectures
  • Application Insights TrackEvent and TrackMetric instrument custom telemetry in application code

Common exam traps

Azure Functions Consumption plan is always the cheapest option

Consumption plan charges per execution and scales to zero. For always-on high-volume workloads, Premium or Dedicated plans may be cheaper because the per-execution cost accumulates faster than a fixed ASP cost.

Service Bus and Event Grid are interchangeable message services

Event Grid is for discrete events (thing happened, react to it — lightweight, push model). Service Bus is for enterprise messaging workflows with ordering, dead-lettering, sessions, and exactly-once delivery guarantees. Event Hubs is for high-throughput streaming data ingestion.

SAS tokens are the most secure way to grant storage access

User delegation SAS (backed by Entra ID) is the most secure SAS. Better still, grant the calling identity an RBAC role on the storage account — no credentials to manage at all. Managed Identity + RBAC is the most secure approach for Azure workloads.

Practice this topic

Test yourself on Azure Developer (AZ-204)

JT Exams routes you to questions in your exact weak areas — automatically, after every session.

No credit card · Cancel anytime

Related certification topics