Practice Free AZ-400 Exam Online Questions
You have an Azure DevOps project named Project1 and an Azure subscription named Sub1.
You need to prevent releases from being deployed unless the releases comply with the Azure Policy rules assigned to Sub1.
What should you do in the release pipeline of Project1?
- A . Create a pipeline variable.
- B . Add a deployment gate.
- C . Configure a deployment trigger.
- D . Modify the Deployment queue settings.
B
Explanation:
You can check policy compliance with gates.
You can extend the approval process for the release by adding a gate. Gates allow you to configure automated calls to external services, where the results are used to approve or reject a deployment. You can use gates to ensure that the release meets a wide range or criteria, without requiring user intervention.
Reference: https://docs.microsoft.com/en-us/azure/devops/pipelines/release/deploy-using-approvals
Note: This question is part of a series of questions that present the same scenario. Each question in the series contains a unique solution that might meet the stated goals. Some question sets might have more than one correct solution, while others might not have a correct solution.
After you answer a question in this section, you will NOT be able to return to it. As a result, these questions will not appear in the review screen.
The lead developer at your company reports that adding new application features takes longer than expected due to a large accumulated technical debt.
You need to recommend changes to reduce the accumulated technical debt.
Solution: You recommend reducing the code coupling and the dependency cycles?
Does this meet the goal?
- A . Yes
- B . No
B
Explanation:
Instead reduce the code complexity.
Note: Technical debt is the accumulation of sub-optimal technical decisions made over the lifetime of an application. Eventually, it gets harder and harder to change things: it’s the ‘sand in the gears’that sees IT initiatives grind to a halt.
Reference: https://dzone.com/articles/fight-through-the-pain-how-to-deal-with-technical
https://www.devopsgroup.com/blog/five-ways-devops-helps-with-technical-debt/
HOTSPOT
Your company uses GitHub for source control. GitHub repositories store source code and store process documentation. The process documentation is saved as Microsoft Word documents that contain simple flow charts stored as .bmp files.
You need to optimize the integration and versioning of the process documentation and the flow charts.
The solution must meet the following requirements:
• Store documents as plain text.
• Minimize the number of files that must be maintained.
• Simplify the modification, merging, and reuse of flow charts.
• Simplify the modification, merging, and reuse of documents.
What should you include in the solution? To answer, select the appropriate options in the answer area. NOTE: Each correct selection is worth one point.

Explanation:
Box 1: Markdown (.md)
GitHub understands several text formats, including .txt and .md. .md stands for a file written in Markdown.
Box 2: Mermaid diagrams
Mermaid lets you create diagrams and visualizations using text and code.
It is a JavaScript based diagramming and charting tool that renders Markdown-inspired text definitions to create and modify diagrams dynamically.
Reference: https://ourcodingclub.github.io/tutorials/git/
https://mermaid-js.github.io/mermaid/#/
HOTSPOT
Your company uses GitHub for source control. GitHub repositories store source code and store process documentation. The process documentation is saved as Microsoft Word documents that contain simple flow charts stored as .bmp files.
You need to optimize the integration and versioning of the process documentation and the flow charts.
The solution must meet the following requirements:
• Store documents as plain text.
• Minimize the number of files that must be maintained.
• Simplify the modification, merging, and reuse of flow charts.
• Simplify the modification, merging, and reuse of documents.
What should you include in the solution? To answer, select the appropriate options in the answer area. NOTE: Each correct selection is worth one point.

Explanation:
Box 1: Markdown (.md)
GitHub understands several text formats, including .txt and .md. .md stands for a file written in Markdown.
Box 2: Mermaid diagrams
Mermaid lets you create diagrams and visualizations using text and code.
It is a JavaScript based diagramming and charting tool that renders Markdown-inspired text definitions to create and modify diagrams dynamically.
Reference: https://ourcodingclub.github.io/tutorials/git/
https://mermaid-js.github.io/mermaid/#/
DRAG DROP
You are configuring the settings of a new Git repository in Azure Repos.
You need to ensure that pull requests in a branch meet the following criteria before they are merged:
✑ Committed code must compile successfully.
✑ Pull requests must have a Quality Gate status of Passed in SonarCloud.
Which policy type should you configure for each requirement? To answer, drag the appropriate policy types to the correct requirements. Each policy type may be used once, more than once, or not at all. You may need to drag the split bar between panes or scroll to view content. NOTE: Each correct selection is worth one point.

Explanation:
Box 1: A check-in policy
Administrators of Team Foundation version control can add check-in policy requirements. These check-in policies require the user to take actions when they conduct a check-in to source control. By default, the following check-in policy types are available: Builds Requires that the last build was successful before a check-in.
Code Analysis Requires that code analysis is run before check-in.
Work Items Requires that one or more work items be associated with the check-in.
Box 2: Build policy
Reference:
https://docs.microsoft.com/en-us/azure/devops/repos/tfvc/add-check-policies
https://azuredevopslabs.com/labs/vstsextend/sonarcloud/
Note: This question is part of a series of questions that present the same scenario. Each question in the series contains a unique solution that might meet the stated goals. Some question sets might have more than one correct solution, while others might not have a correct solution.
After you answer a question in this section, you will NOT be able to return to it. As a result, these questions will not appear in the review screen.
You manage a project in Azure DevOps.
You need to prevent the configuration of the project from changing over time.
Solution: Perform a Subscription Health scan when packages are created.
Does this meet the goal?
- A . Yes
- B . No
B
Explanation:
Instead implement Continuous Assurance for the project.
Note: The Subscription Security health check features in AzSK contains aset of scripts that examines a subscription and flags off security issues, misconfigurations or obsolete artifacts/settings which can put your subscription at higher risk.
Reference: https://azsk.azurewebsites.net/04-Continous-Assurance/Readme.html
To resolve the current technical issue, what should you do to theRegister-AzureRmAutomationDscNodecommand?
- A . Change the value of theConfigurationModeparameter.
- B . Replace theRegister-AzureRmAutomationDscNodecmdlet withRegister-AzureRmAutomationScheduledRunbook
- C . Add theAllowModuleOverwriteparameter.
- D . Add theDefaultProfileparameter.
A
Explanation:
Change the ConfigurationMode parameter from ApplyOnly to ApplyAndAutocorrect.
The Register-AzureRmAutomationDscNode cmdlet registers an Azure virtual machine as an APS Desired State Configuration (DSC) node in an Azure Automation account.
Scenario: Current Technical Issue
The test servers are configured correctly when first deployed, but they experience configuration drift over time. Azure AutomationState Configuration fails to correct the configurations.
Azure Automation State Configuration nodes are registered by using the following command.

Reference: https://docs.microsoft.com/en-us/powershell/module/azurerm.automation/register-azurermautomationdscnode?view=azurermps-6.13.0
Your company is building a new solution in Java.
The company currently uses a SonarQube server to analyze the code of .NET solutions.
You need to analyze and monitor the code quality of the Java solution.
Which task types should you add to the build pipeline?
- A . Octopus
- B . Chef
- C . Maven
- D . Grunt
You have a Microsoft ASP.NET Core web app in Azure that is accessed worldwide.
You need to run a URL ping test once every five minutes and create an alert when the web app is unavailable from specific Azure regions. The solution must minimize development time.
What should you do?
- A . Create an Azure Monitor Availability metric and alert.
- B . Create an Azure Application Insights availability test and alert.
- C . Write an Azure function and deploy the function to the specific regions.
- D . Create an Azure Service Health alert for the specific regions.
B
Explanation:
There are three types of Application Insights availability tests:
URL ping test: a simple test that you can create in the Azure portal.
Multi-step web test
Custom Track Availability Tests
Note: After you’ve deployed your web app/website, you can set up recurring tests to monitor availability and responsiveness. Azure Application Insights sends web requests to your application at regular intervals from points around the world. It can alert you if your application isn’t responding, or if it responds too slowly.
You can set up availability tests for any HTTP or HTTPS endpoint that is accessible from the public internet. You don’t have to make any changes to the website you’re testing. In fact, it doesn’t even have to be a site you own. You can test the availability of a REST API that your service depends on.
Reference: https://docs.microsoft.com/en-us/azure/azure-monitor/app/monitor-web-app-availability#create-a-url-ping-test
Note: This question is part of a series of questions that present the same scenario. Each question in the series contains a unique solution that might meet the stated goals. Some question sets might have more than one correct solution, while others might not have a correct solution.
After you answer a question in this section, you will NOT be able to return to it. As a result, these questions will not appear in the review screen.
You plan to update the Azure DevOps strategy of your company.
You need to identify the following issues as they occur during the company’s development process:
✑ Licensing violations
✑ Prohibited libraries
Solution: You implement continuous deployment.
Does this meet the goal?
- A . Yes
- B . No
B
Explanation:
Instead implement continuous integration.
Note: WhiteSource is the leader in continuous open source software security and compliance management. WhiteSource integrates into your build process, irrespective of your programming languages, build tools, or development environments. It works automatically, continuously, and silently in the background, checking the security, licensing, and quality of your open source components against WhiteSource constantly-updated definitive database of open source repositories.
Reference: https://azuredevopslabs.com/labs/vstsextend/whitesource/
