Microsoft AZ-400 Practice Test 31
Question 300
Before changing the pipeline or service, engineers find: A post-deployment verification job runs even when staging tests fail because its condition overrides the default dependency check. Which evidence should the engineer inspect FIRST?
- Inspect GitHub App installation, service connection, YAML PR settings and branch policy.
- Review stage condition expressions, dependency status and test results.
- Inspect task group inputs, variable classifications, log output and service permissions.
- Inspect supported OS/runtime targets, build matrix and test coverage.
Explanation
Correct Answer
B:Review stage condition expressions, dependency status and test results. This directly checks the uncertain behavior or control before changing production. Custom YAML conditions must retain required success prerequisites. The resulting targeted action is: Include explicit succeeded dependencies in the custom promotion condition.
Incorrect Answers
A:Inspect GitHub App installation, service connection, YAML PR settings and branch policy. This would address a different situation, such as: An Azure DevOps pipeline uses a GitHub repository but cannot run pull-request validation because its repository connection is misconfigured. In the present case, the most directly relevant evidence is: Review stage condition expressions, dependency status and test results. The crucial distinction is: Custom YAML conditions must retain required success prerequisites.
C:Inspect task group inputs, variable classifications, log output and service permissions. This would address a different situation, such as: An Azure Pipelines task group exposes a deployment secret as a plain variable and prints it during release. In the present case, the most directly relevant evidence is: Review stage condition expressions, dependency status and test results. The crucial distinction is: Custom YAML conditions must retain required success prerequisites.
D:Inspect supported OS/runtime targets, build matrix and test coverage. This would address a different situation, such as: A cross-platform CLI is built only on Windows and fails later when customers run it on Linux. In the present case, the most directly relevant evidence is: Review stage condition expressions, dependency status and test results. The crucial distinction is: Custom YAML conditions must retain required success prerequisites.
Question 301
An engineering design review identifies: A company combines experimental internal tools and regulated payment services into one deployment-frequency ranking. Which shortcut should the team MOST specifically avoid for this case?
- Reward teams only for maximum deployment count independent of failure rate.
- Backdate item start dates until the dashboard meets a management target.
- Present a handful of favorable comments as representative of every engineering team.
- Use calendar days since project kickoff as lead time for every deployed change.
Explanation
Correct Answer
A:Reward teams only for maximum deployment count independent of failure rate. This shortcut directly undermines the stated control or workflow. A safer action is: Build service-segmented queries and complementary stability metrics. Explanation: Operational metrics must be interpreted by service context and business risk.
Incorrect Answers
B:Backdate item start dates until the dashboard meets a management target. This would address a different situation, such as: Azure Boards reports near-zero cycle time because teams move stories to Active only when coding is almost finished. In the present case, the most directly relevant unsafe shortcut is: Reward teams only for maximum deployment count independent of failure rate. The crucial distinction is: Operational metrics must be interpreted by service context and business risk.
C:Present a handful of favorable comments as representative of every engineering team. This would address a different situation, such as: A team reports excellent developer experience based only on responses from its three most active maintainers. In the present case, the most directly relevant unsafe shortcut is: Reward teams only for maximum deployment count independent of failure rate. The crucial distinction is: Operational metrics must be interpreted by service context and business risk.
D:Use calendar days since project kickoff as lead time for every deployed change. This would address a different situation, such as: A dashboard measures deployment frequency but calculates lead time from the first commit in an unrelated repository. In the present case, the most directly relevant unsafe shortcut is: Reward teams only for maximum deployment count independent of failure rate. The crucial distinction is: Operational metrics must be interpreted by service context and business risk.
Question 302
An Azure DevOps engineering team evaluates this condition: A build must reach private package infrastructure inaccessible from Microsoft-hosted agents. Which DevOps principle BEST explains the underlying weakness?
- Pipeline parallelism should match resource quotas and job critical paths.
- Matrix job strategies can validate supported platforms from one pipeline definition.
- Agent placement should satisfy network access and security constraints without overprivilege.
- Concurrent deployments require serialization or controlled exclusive access to shared environments.
Explanation
Correct Answer
C:Agent placement should satisfy network access and security constraints without overprivilege. This principle identifies the risk or delivery weakness in the case. Relevant evidence: Inspect firewall paths, private DNS, hosted-agent restrictions and required build tools. An appropriate controlled response is: Deploy a governed self-hosted Azure Pipelines agent with controlled network connectivity.
Incorrect Answers
A:Pipeline parallelism should match resource quotas and job critical paths. This would address a different situation, such as: A large repository launches 100 independent test jobs though the organization owns only 10 paid parallel agent slots. In the present case, the most directly relevant principle is: Agent placement should satisfy network access and security constraints without overprivilege. The crucial distinction is: Agent placement should satisfy network access and security constraints without overprivilege.
B:Matrix job strategies can validate supported platforms from one pipeline definition. This would address a different situation, such as: A cross-platform CLI is built only on Windows and fails later when customers run it on Linux. In the present case, the most directly relevant principle is: Agent placement should satisfy network access and security constraints without overprivilege. The crucial distinction is: Agent placement should satisfy network access and security constraints without overprivilege.
D:Concurrent deployments require serialization or controlled exclusive access to shared environments. This would address a different situation, such as: Two production deployments target the same App Service slot simultaneously and the earlier one overwrites the newer release. In the present case, the most directly relevant principle is: Agent placement should satisfy network access and security constraints without overprivilege. The crucial distinction is: Agent placement should satisfy network access and security constraints without overprivilege.
Question 303
An Azure DevOps engineering team evaluates this condition: A self-hosted agent fails after months because workspace and Docker layer caches exhaust disk space. Which DevOps principle BEST explains the underlying weakness?
- Pipeline monitoring must detect credential disclosure while retaining useful logs.
- Moving deployment logic to versioned YAML can improve consistency and review.
- Pipeline cost optimization should remove redundant executions without weakening required checks.
- Self-hosted agent maintenance requires bounded workspace cleanup and cache retention.
Explanation
Correct Answer
D:Self-hosted agent maintenance requires bounded workspace cleanup and cache retention. This principle identifies the risk or delivery weakness in the case. Relevant evidence: Inspect free disk, workspace lifecycle, container images and failure records. An appropriate controlled response is: Implement safe workspace cleanup and monitored cache eviction consistent with rollback needs.
Incorrect Answers
A:Pipeline monitoring must detect credential disclosure while retaining useful logs. This would address a different situation, such as: Verbose diagnostic logging starts printing deployment tokens after a new task version update. In the present case, the most directly relevant principle is: Self-hosted agent maintenance requires bounded workspace cleanup and cache retention. The crucial distinction is: Self-hosted agent maintenance requires bounded workspace cleanup and cache retention.
B:Moving deployment logic to versioned YAML can improve consistency and review. This would address a different situation, such as: A legacy classic Azure Release pipeline hides deployment steps in the UI and new teams cannot peer-review changes. In the present case, the most directly relevant principle is: Self-hosted agent maintenance requires bounded workspace cleanup and cache retention. The crucial distinction is: Self-hosted agent maintenance requires bounded workspace cleanup and cache retention.
C:Pipeline cost optimization should remove redundant executions without weakening required checks. This would address a different situation, such as: Hundreds of nightly builds run when source code is unchanged, consuming expensive hosted parallel minutes. In the present case, the most directly relevant principle is: Self-hosted agent maintenance requires bounded workspace cleanup and cache retention. The crucial distinction is: Self-hosted agent maintenance requires bounded workspace cleanup and cache retention.
Question 304
Before changing the pipeline or service, engineers find: A deployment receives approval even when a required penetration-test issue remains unresolved and unaccepted. Which evidence should the engineer inspect FIRST?
- Inspect service connections, resource IDs, variables and test cleanup scripts.
- Inspect producer schemas, consumer tests, artifact versions and failure logs.
- Inspect connection policy, test-stage service connections, database logs and environment settings.
- Inspect issue severity, gate criteria, exception owners and evidence attachments.
Explanation
Correct Answer
D:Inspect issue severity, gate criteria, exception owners and evidence attachments. This directly checks the uncertain behavior or control before changing production. Release gates must evaluate approved risk exceptions and mandatory security criteria. The resulting targeted action is: Require accountable acceptance or closure of critical security blockers before promotion.
Incorrect Answers
A:Inspect service connections, resource IDs, variables and test cleanup scripts. This would address a different situation, such as: A test pipeline reuses a production storage account and occasionally deletes customer fixtures. In the present case, the most directly relevant evidence is: Inspect issue severity, gate criteria, exception owners and evidence attachments. The crucial distinction is: Release gates must evaluate approved risk exceptions and mandatory security criteria.
B:Inspect producer schemas, consumer tests, artifact versions and failure logs. This would address a different situation, such as: A microservice changes a JSON field name while a downstream consumer still relies on the old name. In the present case, the most directly relevant evidence is: Inspect issue severity, gate criteria, exception owners and evidence attachments. The crucial distinction is: Release gates must evaluate approved risk exceptions and mandatory security criteria.
C:Inspect connection policy, test-stage service connections, database logs and environment settings. This would address a different situation, such as: Service unit tests pass but integration fails because Azure SQL connectivity differs between staging and production. In the present case, the most directly relevant evidence is: Inspect issue severity, gate criteria, exception owners and evidence attachments. The crucial distinction is: Release gates must evaluate approved risk exceptions and mandatory security criteria.
Question 305
The DevOps team must resolve this situation: Teams use dozens of release branches with ambiguous names, and automation often deploys the wrong branch. Which engineering action is MOST appropriate?
- Use fork-and-pull-request contributions with least-privilege branch access.
- Define clear branch purposes and deploy from approved immutable tagged or hashed revisions.
- Apply equivalent required reviews and test gates to all protected release branches.
- Maintain controlled support branches with signed or protected release tags and planned retirement.
Explanation
Correct Answer
B:Define clear branch purposes and deploy from approved immutable tagged or hashed revisions. This action addresses the specific failure or requirement and preserves delivery controls. Validation criterion: A release process selects the exact approved commit instead of a similarly named branch. Branch conventions and immutable release references should uniquely identify deployable versions.
Incorrect Answers
A:Use fork-and-pull-request contributions with least-privilege branch access. This would address a different situation, such as: External contributors can directly edit protected organization branches rather than submitting reviewed fork-based changes. In the present case, the most directly relevant engineering action is: Define clear branch purposes and deploy from approved immutable tagged or hashed revisions. The crucial distinction is: Branch conventions and immutable release references should uniquely identify deployable versions.
C:Apply equivalent required reviews and test gates to all protected release branches. This would address a different situation, such as: A company protects main but permits unrestricted direct commits to an unprotected release branch deployed to production. In the present case, the most directly relevant engineering action is: Define clear branch purposes and deploy from approved immutable tagged or hashed revisions. The crucial distinction is: Branch conventions and immutable release references should uniquely identify deployable versions.
D:Maintain controlled support branches with signed or protected release tags and planned retirement. This would address a different situation, such as: Old supported product versions receive urgent fixes but the team deletes prior release references after every mainline update. In the present case, the most directly relevant engineering action is: Define clear branch purposes and deploy from approved immutable tagged or hashed revisions. The crucial distinction is: Branch conventions and immutable release references should uniquely identify deployable versions.
Question 306
The DevOps team must resolve this situation: An AKS update removes every API pod simultaneously because maxUnavailable equals the full replica count. Which engineering action is MOST appropriate?
- Use chart lint/templates, guarded upgrade behavior and supported rollback to a tested revision.
- Use governed secret reference/rotation patterns with staged compatibility testing.
- Set appropriate maxUnavailable/maxSurge and validate readiness during rollout.
- Use slot-sticky settings and suppress staging triggers until explicitly authorized.
Explanation
Correct Answer
C:Set appropriate maxUnavailable/maxSurge and validate readiness during rollout. This action addresses the specific failure or requirement and preserves delivery controls. Validation criterion: A sample rollout maintains required ready endpoints with no response interruption. Rolling update policies should preserve minimum ready capacity during replacement.
Incorrect Answers
A:Use chart lint/templates, guarded upgrade behavior and supported rollback to a tested revision. This would address a different situation, such as: An AKS Helm upgrade fails after rendering a misconfigured resource, leaving pods partially updated. In the present case, the most directly relevant engineering action is: Set appropriate maxUnavailable/maxSurge and validate readiness during rollout. The crucial distinction is: Rolling update policies should preserve minimum ready capacity during replacement.
B:Use governed secret reference/rotation patterns with staged compatibility testing. This would address a different situation, such as: A production release references an unversioned shared secret and breaks when a different team rotates it mid-deployment. In the present case, the most directly relevant engineering action is: Set appropriate maxUnavailable/maxSurge and validate readiness during rollout. The crucial distinction is: Rolling update policies should preserve minimum ready capacity during replacement.
D:Use slot-sticky settings and suppress staging triggers until explicitly authorized. This would address a different situation, such as: An Azure Functions staging slot unexpectedly processes production queue messages before its swap because a trigger configuration was not isolated. In the present case, the most directly relevant engineering action is: Set appropriate maxUnavailable/maxSurge and validate readiness during rollout. The crucial distinction is: Rolling update policies should preserve minimum ready capacity during replacement.
Question 307
An Azure DevOps engineering team evaluates this condition: A production release references an unversioned shared secret and breaks when a different team rotates it mid-deployment. Which DevOps principle BEST explains the underlying weakness?
- Rolling update policies should preserve minimum ready capacity during replacement.
- Canary deployments reduce blast radius by validating a small traffic share first.
- Database deployment scripts should be repeatable or safely versioned with migration state.
- Secret deployment should coordinate version lifecycle and client refresh behavior.
Explanation
Correct Answer
D:Secret deployment should coordinate version lifecycle and client refresh behavior. This principle identifies the risk or delivery weakness in the case. Relevant evidence: Inspect Key Vault references, version transitions, rotation timing and runtime caches. An appropriate controlled response is: Use governed secret reference/rotation patterns with staged compatibility testing.
Incorrect Answers
A:Rolling update policies should preserve minimum ready capacity during replacement. This would address a different situation, such as: An AKS update removes every API pod simultaneously because maxUnavailable equals the full replica count. In the present case, the most directly relevant principle is: Secret deployment should coordinate version lifecycle and client refresh behavior. The crucial distinction is: Secret deployment should coordinate version lifecycle and client refresh behavior.
B:Canary deployments reduce blast radius by validating a small traffic share first. This would address a different situation, such as: A new AKS container image may affect payments, but the team wants to limit customer exposure during rollout. In the present case, the most directly relevant principle is: Secret deployment should coordinate version lifecycle and client refresh behavior. The crucial distinction is: Secret deployment should coordinate version lifecycle and client refresh behavior.
C:Database deployment scripts should be repeatable or safely versioned with migration state. This would address a different situation, such as: A release database task retries after a timeout and creates duplicate schema objects, causing subsequent deployments to fail. In the present case, the most directly relevant principle is: Secret deployment should coordinate version lifecycle and client refresh behavior. The crucial distinction is: Secret deployment should coordinate version lifecycle and client refresh behavior.
Question 308
The DevOps team must resolve this situation: An organization merges changes only at the end of a six-week release branch, creating hundreds of conflicts. Which engineering action is MOST appropriate?
- Require fresh passing checks after updates to the protected pull request.
- Adopt short-lived feature branches with required tests and frequent mainline integration.
- Integrate incomplete code safely behind governed feature flags and short-lived branches.
- Enforce code owner approval for sensitive path changes in protected branches.
Explanation
Correct Answer
B:Adopt short-lived feature branches with required tests and frequent mainline integration. This action addresses the specific failure or requirement and preserves delivery controls. Validation criterion: A trial feature merges safely with a small diff and mandatory gates intact. Frequent integration into a protected trunk reduces accumulated merge risk.
Incorrect Answers
A:Require fresh passing checks after updates to the protected pull request. This would address a different situation, such as: A pull request passes security tests, then receives new commits but can merge without rerunning required checks. In the present case, the most directly relevant engineering action is: Adopt short-lived feature branches with required tests and frequent mainline integration. The crucial distinction is: Frequent integration into a protected trunk reduces accumulated merge risk.
C:Integrate incomplete code safely behind governed feature flags and short-lived branches. This would address a different situation, such as: A feature needs gradual rollout, but the team maintains a year-long divergent branch to hide unfinished functionality. In the present case, the most directly relevant engineering action is: Adopt short-lived feature branches with required tests and frequent mainline integration. The crucial distinction is: Frequent integration into a protected trunk reduces accumulated merge risk.
D:Enforce code owner approval for sensitive path changes in protected branches. This would address a different situation, such as: Payment processing files require security review, but code owner review is only advisory. In the present case, the most directly relevant engineering action is: Adopt short-lived feature branches with required tests and frequent mainline integration. The crucial distinction is: Frequent integration into a protected trunk reduces accumulated merge risk.
Question 309
Before changing the pipeline or service, engineers find: A legacy fleet uses Azure Automation State Configuration but receives no reliable reports of drift or node registration. Which evidence should the engineer inspect FIRST?
- Inspect DSC node enrollment, configuration compilations and reporting logs.
- Inspect backend settings, state access policy, encryption and concurrent writes.
- Inspect environment definitions, project catalog, role assignments and teardown process.
- Inspect policy assignment parameters, effect, scope and compliance states.
Explanation
Correct Answer
A:Inspect DSC node enrollment, configuration compilations and reporting logs. This directly checks the uncertain behavior or control before changing production. Desired state governance needs verified registration, pull frequency and compliance feedback. The resulting targeted action is: Review the legacy DSC setup and plan a supported configuration management transition or remediation.
Incorrect Answers
B:Inspect backend settings, state access policy, encryption and concurrent writes. This would address a different situation, such as: A Terraform workflow stores its state file in an unencrypted shared file share accessible to all developers. In the present case, the most directly relevant evidence is: Inspect DSC node enrollment, configuration compilations and reporting logs. The crucial distinction is: Desired state governance needs verified registration, pull frequency and compliance feedback.
C:Inspect environment definitions, project catalog, role assignments and teardown process. This would address a different situation, such as: Developers need consistent temporary test environments, but each manually provisions expensive subscriptions and forgets cleanup. In the present case, the most directly relevant evidence is: Inspect DSC node enrollment, configuration compilations and reporting logs. The crucial distinction is: Desired state governance needs verified registration, pull frequency and compliance feedback.
D:Inspect policy assignment parameters, effect, scope and compliance states. This would address a different situation, such as: A platform team thinks an Azure Policy Audit effect blocks deployment of unencrypted storage, but noncompliant accounts continue being created. In the present case, the most directly relevant evidence is: Inspect DSC node enrollment, configuration compilations and reporting logs. The crucial distinction is: Desired state governance needs verified registration, pull frequency and compliance feedback.
Question 310
An Azure DevOps engineering team evaluates this condition: A deployment pipeline uses complete mode unintentionally and deletes resources omitted from an updated ARM template. Which DevOps principle BEST explains the underlying weakness?
- Deployment mode and scope determine whether absent resources may be removed.
- Infrastructure and application delivery need traceable version handoff without mutable assumptions.
- Secrets should be supplied through protected identity and secret stores rather than committed IaC inputs.
- Guest desired-state policy should be measurable and enforceable across managed VMs.
Explanation
Correct Answer
A:Deployment mode and scope determine whether absent resources may be removed. This principle identifies the risk or delivery weakness in the case. Relevant evidence: Inspect template deployment mode, resource group contents, what-if output and retention requirements. An appropriate controlled response is: Use a safe scoped deployment strategy with reviewed change previews and deletion protections.
Incorrect Answers
B:Infrastructure and application delivery need traceable version handoff without mutable assumptions. This would address a different situation, such as: Application images are deployed manually after infra provisioning and the deployed image tag is not recorded in Bicep or the release pipeline. In the present case, the most directly relevant principle is: Deployment mode and scope determine whether absent resources may be removed. The crucial distinction is: Deployment mode and scope determine whether absent resources may be removed.
C:Secrets should be supplied through protected identity and secret stores rather than committed IaC inputs. This would address a different situation, such as: A Bicep parameter file stores database administrator passwords in plaintext committed to Git. In the present case, the most directly relevant principle is: Deployment mode and scope determine whether absent resources may be removed. The crucial distinction is: Deployment mode and scope determine whether absent resources may be removed.
D:Guest desired-state policy should be measurable and enforceable across managed VMs. This would address a different situation, such as: Production VMs are configured by manual shell changes and new replacement VMs lack required OS baselines. In the present case, the most directly relevant principle is: Deployment mode and scope determine whether absent resources may be removed. The crucial distinction is: Deployment mode and scope determine whether absent resources may be removed.