AZ-400 weights its five domains unevenly — build and release pipelines alone is 50–55% of the exam — so the questions below follow that same weighting: ten out of twenty on pipelines, and only two or three each on the smaller domains. That distribution mirrors the real exam more closely than a flat 4-per-domain split would.
Read the scenario, pick an answer, then click Reveal answer to check your reasoning against the explanation — not just the correct letter. A wrong answer is a signal to review that domain in the full AZ-400 practice exam rather than moving on.
Question distribution by domain
3
Process
3
Source Ctrl
10
Pipelines
2
Security
2
Instrument.
Processes & Communications
Q1–3 · 10–15% of examA team splits work between a GitHub repository and Azure Boards. Leadership wants every commit and pull request automatically linked to the Azure Boards work item it addresses, without developers manually pasting links.
What should you configure?
Reveal answer & explanationHide answer
Correct: A. Azure Boards-GitHub integration natively links commits, PRs, and branches to work items referenced by ID (e.g. "AB#123") — no manual pasting required. A Teams webhook only notifies; it doesn't create traceability links. A comment-required policy doesn't enforce linking. A wiki diagram documents intent but automates nothing.
Management asks for a dashboard showing how long, on average, it takes a change to go from the first commit to production deployment — not how many items the team completes per sprint.
Which metric should the dashboard be built around?
Reveal answer & explanationHide answer
Correct: A. Lead time measures the full span from work starting (first commit) to delivery — exactly what's being asked. Velocity measures throughput of completed story points per sprint, not elapsed time for a single change. Burndown tracks remaining work within a sprint. Open PR count is a snapshot, not a time-based flow metric.
A team wants a message posted to a specific Microsoft Teams channel every time a pipeline run fails, and no native Azure Pipelines-Teams connector covers the exact custom format they want.
What should you configure?
Reveal answer & explanationHide answer
Correct: A. A webhook is the general-purpose integration mechanism for pushing custom-formatted events to external systems like Teams when no built-in connector matches the required format. Conditional access governs sign-in behavior, unrelated to pipeline notifications. A work item automation rule operates on Boards items, not pipeline events. Branch protection rules gate merges, not notifications.
Source Control Strategy
Q4–6 · 10–15% of examA team already merges short-lived feature branches into main multiple times a day via pull request, with no long-lived parallel branches. They ask for a branch strategy recommendation that keeps this pattern without adding new branch types.
What should you recommend?
Reveal answer & explanationHide answer
Correct: A. Trunk-based development already describes what the team is doing — short-lived branches merged frequently into a single trunk — and needs no new structure. Gitflow adds permanent branch types the team explicitly doesn't need. A long-lived staging branch and permanent per-feature branches both reintroduce the long-lived-branch overhead trunk-based development is designed to avoid.
A game development team keeps committing multi-hundred-megabyte texture and audio files directly into their Git repository, causing clone times to balloon for every new team member.
What should you implement?
Reveal answer & explanationHide answer
Correct: A. Git LFS is purpose-built for large individual files — it replaces the file content in Git with a lightweight pointer, keeping repository size and clone time manageable. Scalar solves large-repository (many files, deep history) performance, not large individual files — a different scaling problem. A shallow clone policy isn't a real enforceable Git feature via branch protection. A release branch per asset version doesn't address the underlying large-file storage problem.
A developer accidentally committed an API key to a repository three commits ago. The commit has already been pushed and pulled by other team members. The key must be fully removed from the repository's history, not just the current file state.
What should you do?
Reveal answer & explanationHide answer
Correct: A. Removing data from source control history requires rewriting the commits that contain it (via a history-rewriting tool) and force-pushing, followed by every clone being reset — a new commit or .gitignore entry leaves the secret fully intact in prior commits' history. Rotating the key is a necessary follow-up but does not itself remove the secret from the repository, which the requirement explicitly calls for.
Over half the questions in this bank cover Build & Release Pipelines
Ten questions coming up — the domain that decides most AZ-400 outcomes.
Build & Release Pipelines
Q7–16 · 50–55% of exam — the largest domainA team publishes a shared internal library that other teams' applications depend on directly. Consumers need to know, from the version number alone, whether upgrading might break their code.
What versioning strategy should you adopt?
Reveal answer & explanationHide answer
Correct: A. SemVer's major.minor.patch structure explicitly communicates breaking vs. compatible changes to consumers, which is exactly the stated need. CalVer communicates release cadence, not compatibility. A bare incrementing build number and reusing the pipeline's build ID both carry no compatibility semantics at all — consumers would have no way to infer breaking-change risk.
A team wants developers to be able to publish packages freely to a working feed, but only packages that pass an automated quality gate should ever reach the feed that production applications actually consume from.
What should you configure in Azure Artifacts?
Reveal answer & explanationHide answer
Correct: A. Feed views let a package version be published freely to a local/working view while only promoting vetted versions to a release view that consumers point at — exactly the gate described. A naming convention is a manual, unenforced signal. Branch policies gate code merges, not which package versions reach a feed. A retention policy manages storage, not quality gating.
A pipeline currently runs unit tests, integration tests, and a linter sequentially in a single stage, taking 40 minutes. None of these three tasks depend on each other's output.
What should you change to reduce pipeline duration?
Reveal answer & explanationHide answer
Correct: A. Jobs with no dependency on each other's output can run in parallel across multiple agents within the same stage, directly cutting wall-clock time. Splitting into separate manually-triggered pipelines adds coordination overhead without automatic parallelism. Merging into a single script step forces sequential execution. Reducing run frequency doesn't address per-run duration and delays feedback.
Twelve different microservice repositories each define nearly identical build-and-test YAML steps, and a required security-scan step must now be added to all twelve without editing each pipeline file individually going forward.
What should you implement?
Reveal answer & explanationHide answer
Correct: A. A shared YAML template centralizes common steps so a single edit (adding the scan step) propagates to every referencing pipeline. Copy-pasting into twelve files reintroduces the exact duplication problem being solved. Merging into one monorepo pipeline is a disproportionate restructuring not required by the stated problem. A drift-detection task finds the problem after the fact rather than preventing it.
A pipeline must run its build stage on Microsoft-hosted agents but deploy to an on-premises server that has no direct internet-inbound connectivity and requires specific proprietary software installed on the deployment machine.
What should you configure?
Reveal answer & explanationHide answer
Correct: A. A hybrid pipeline mixes Microsoft-hosted agents (for stages with no special environment needs, like build) with a self-hosted agent placed where it can reach the on-prem, non-internet-facing target and has the required proprietary software installed. Microsoft-hosted agents alone cannot reach an isolated on-prem server regardless of VPN, since the hosted agent pool itself isn't deployed there. Using self-hosted for both stages is unnecessary when the build stage has no special requirement. Azure Deployment Environments provision on-demand Azure dev/test environments — not a way to virtualize an existing on-prem server.
A team wants any regression in a new release caught by monitoring a small percentage of live production traffic before the release reaches the rest of users, with the ability to scale up exposure gradually based on observed metrics.
Which deployment strategy fits best?
Reveal answer & explanationHide answer
Correct: A. Canary deployment is specifically designed to expose a new version to a small percentage of live traffic and scale exposure based on observed metrics — exactly the requirement. Blue-green swaps all traffic to the new environment at once, which doesn't provide graduated, percentage-based exposure. The other two options describe having no staged rollout mechanism at all, which is the opposite of what's being asked for.
A new feature has already been deployed to 100% of production servers as part of a scheduled release, but the team wants to enable it for only 2% of end users initially and turn it off instantly if problems arise, without a new deployment either way.
What should you use to control this?
Reveal answer & explanationHide answer
Correct: A. The code is already deployed everywhere — the requirement is purely about which users experience the feature, and toggling that instantly without a new deployment. A feature flag does exactly that: it gates a code path already present in the build. Deployment rings and canary releases both control which servers/infrastructure receive a build, not which end users see a feature within an already-deployed build. A blue-green swap would require redeploying to the previous environment, which contradicts "without a new deployment."
A critical production bug is discovered that must be fixed and deployed within hours, but the team's normal release pipeline includes a full regression suite that takes six hours to run and is required for standard releases.
What should the team's hotfix path plan include?
Reveal answer & explanationHide answer
Correct: A. A hotfix path plan is precisely an alternate, faster route through the pipeline — reduced scope testing focused on the affected area, still gated by review/approval — that balances urgency against risk. Disabling all gates removes necessary safeguards entirely. Waiting for the next full run defeats the "within hours" requirement. Bypassing the pipeline entirely removes traceability, testing, and approval altogether, which a hotfix path plan is specifically designed to avoid while still being fast.
A team wants their Azure infrastructure defined declaratively in source control, so that the actual deployed state can always be reconciled against a version-controlled definition, and changes go through the same pipeline and review process as application code.
What approach should they adopt?
Reveal answer & explanationHide answer
Correct: A. Bicep (or ARM) templates in source control, deployed via pipeline, are exactly what "declarative, version-controlled, pipeline-reviewed infrastructure" describes — the core of an infrastructure-as-code strategy. Manual portal configuration with wiki documentation isn't declarative or version-controlled and drifts easily. Ad hoc scripts run by whoever is on call lack the consistency and review process required. Azure Advisor gives recommendations; it does not define or enforce a desired state.
An organization still runs several release pipelines configured through the classic (UI-based) editor. Microsoft has signaled classic pipelines are being phased out, and the team wants version-controlled, code-reviewable pipeline definitions going forward.
What should the team do?
Reveal answer & explanationHide answer
Correct: A. Migrating classic pipelines to YAML gives version-controlled, diffable, code-reviewable pipeline definitions and gets ahead of the deprecation of the classic editor — exactly what "maintain pipelines" as an AZ-400 skill covers. Leaving them unchanged ignores both the stated deprecation risk and the version-control requirement. A PDF export documents but doesn't make the pipeline itself version-controlled or reviewable. Manual runbooks remove automation entirely, which is a regression, not a migration.
Security & Compliance
Q17–18 · 10–15% of examA GitHub Actions workflow currently authenticates to Azure using a service principal with a client secret stored as a GitHub secret. The security team wants to eliminate any long-lived credential the workflow depends on.
What should you implement?
Reveal answer & explanationHide answer
Correct: A. Workload identity federation lets GitHub Actions authenticate to Azure via a short-lived, federated token with no long-lived secret stored anywhere — the secretless option external CI/CD needs. A longer rotated secret is still a long-lived credential, just rotated. A personal access token ties automation to an individual's identity and is also a stored, long-lived credential. Moving the same client secret into Key Vault relocates it but doesn't eliminate the credential itself.
Security leadership wants one consolidated view showing exposed secrets, misconfigurations, and open-source vulnerability risk across both the organization's GitHub repositories and Azure DevOps projects, rather than checking each tool's own dashboard separately.
What should you configure?
Reveal answer & explanationHide answer
Correct: A. Defender for Cloud DevOps Security is the unified posture layer purpose-built to connect both GitHub and Azure DevOps into a single Defender for Cloud view covering secrets, misconfigurations, and open-source risk — exactly the consolidated view requested. Dependabot alone only covers dependency vulnerabilities on GitHub. CodeQL performs code scanning, not secrets/misconfiguration posture, and doesn't cover GitHub in this option. A manually aggregated spreadsheet is not a consolidated, automated view.
Instrumentation
Q19–20 · 5–10% of examAn application composed of three microservices is experiencing intermittent slow responses, but it's unclear which of the three services is responsible for the added latency in any given request.
What should you configure to diagnose this?
Reveal answer & explanationHide answer
Correct: A. Application Insights distributed tracing follows a single request as it flows across multiple services, pinpointing exactly which hop introduces latency — precisely what's needed here. A Log Analytics workspace with no telemetry configured to feed it has nothing to analyze. Build agent capacity is unrelated to runtime request latency. An NSG rule is a network security control, not a diagnostic tool for latency.
A team needs to quickly find every failed HTTP request logged to Azure Monitor Logs in the last hour for a specific application, to include in an incident report.
What should you use?
Reveal answer & explanationHide answer
Correct: A. A basic KQL query against the requests table, filtered by failure result code and a time window, is the direct way to interrogate logs stored in Azure Monitor Logs — exactly the AZ-400 "interrogate logs using basic KQL" skill. The Activity Log records management operations (like resource changes), not application request telemetry. A pipeline YAML variable is a build-time construct, unrelated to querying runtime logs. A branch policy prevents deployments; it doesn't retrieve log data for an incident report.
Want 480 More AZ-400 Questions?
Full coverage of all five domains, weighted the same way the real exam is, calibrated to the same design-decision difficulty. Start with 40 free — no card required.
Start Free AZ-400 Practice →