Free AZ-400 Exam Braindumps
Designing and Implementing Microsoft DevOps Solutions Questions 146–150 (page: 31)

Updated On: 10-Mar-2026

You have an Azure subscription that uses Azure Boards and Azure Repos.

You have GitHub repositories.

You need to ensure that all activity in the repositories is traced by using Azure Boards. The solution must minimize development effort.

What should you use?

  1. work item linking
  2. Application Insights in Azure Monitor
  3. a project backlog
  4. Delivery Plans

Answer(s): A

Explanation:

Azure Boards, Link work items to objects
Work item links are associations between two work items or a work item and another object. Links describe the relationship between objects. You can use work item links to track dependencies and related work for traceability, share information, manage complex projects that involve multiple teams or products, track code changes, tests, and more.
Types of links
The following types of links help you manage the various relationships between work items and other objects.
* GitHub
Connects a work item to a GitHub repository branch, commit, issue, or pull request.
* Etc.


Reference:

https://learn.microsoft.com/en-us/azure/devops/boards/backlogs/add-link



HOTSPOT (Drag and Drop is not supported)

You use Git for source control.

You need to optimize the performance of a repository. The solution must meet the following requirements:

Permanently remove all items referenced only in the reflog.

Remove history that is NOT in any current branch.

How should you complete the command? To answer, select the appropriate options in the answer area.

Note: Each correct selection is worth one point.

Hot Area:

  1. See Explanation section for answer.

Answer(s): A

Explanation:




Box 1: reflog
Permanently remove all items referenced only in the reflog.

You need, specifically, the --expire-unreachable option:

git reflog expire --expire=90.days.ago --expire-unreachable=now --all

Box 2: gc
Remove history that is NOT in any current branch.

In most cases, users will not need to call git prune directly, but should instead call git gc, which handles pruning along with many other housekeeping tasks.

git-gc - Cleanup unnecessary files and optimize the local repository

SYNOPSIS
git gc [--aggressive] [--auto] [--quiet] [--prune=<date> | --no-prune] [--force] [--keep-largest-pack]

Options include:
--prune=<date>
Prune loose objects older than date (default is 2 weeks ago, overridable by the config variable gc.pruneExpire). --prune=now prunes loose objects regardless of their age and increases the risk of corruption if another process is writing to the repository concurrently; see "NOTES" below. --prune is on by default.

Box 3: now


Reference:

https://stackoverflow.com/questions/49067898/git-remove-old-reflog-entries https://git-scm.com/docs/git-prune https://git-scm.com/docs/git-gc



You have a 1-TB Azure Repos repository named repo1.

You need to clone repo1. The solution must meet the following requirements:

You must be able to search the commit history of the /src directory.

The amount of time it takes to clone the repository must be minimized.

Which command should you run?

  1. git clone --filter=blob:none git@ssh.dev.azure.com:v3/org/Project1/repo1
  2. git clone --depth=1 git@ssh.dev.azure.com:v3/org/Project1/repo1
  3. git clone --filter=tree:0 git@ssh.dev.azure.com:v3/org/Project1/repo1
  4. git clone git@ssh.dev.azure.com:v3/org/Project1/repo1

Answer(s): A

Explanation:

Partial clone
As Git repositories grow in size, they can become cumbersome to work with because of:
The large amount of history that must be downloaded.
The large amount of disk space they require.
Partial clone is a performance optimization that "allows Git to function without having a complete copy of the repository. The goal of this work is to allow Git better handle extremely large repositories." Git 2.22.0 or later is required
Filter by object type
Introduced in GitLab 12.10.
For repositories with millions of files and a long history, you can exclude all files and use git sparse-checkout to reduce the size of your working copy.
# Clone the repo excluding all files
$ git clone --filter=blob:none --sparse git@gitlab.com:gitlab-com/www-gitlab-com.git Incorrect:
Not B:

git clone -depth-1
git@ssh.dev.azure.com:v3/org/Project1/repo1
"Clone depth" is a feature of git to reduce server load: Instead of cloning the complete repository (as usually done with git), using clone depth just clones the last clone-depth-number revisions of your repository.
In literature this is also called "shallow clone"
Git shallow clone lets you pull down just the latest commits, not the entire repo history. So if your project has years of history, or history from thousands of commits, you can select a particular depth to pull.


Reference:

https://docs.gitlab.com/ee/topics/git/partial_clone.html https://www.perforce.com/blog/vcs/git-beyond-basics-using-shallow-clones



You are using GitHub as a source code repository.

You create a client-side Git hook on the commit-msg event. The hook requires that each commit message contain a custom work item tag.

You need to make a commit that does not have a work item tag.

Which git commit parameter should you use.

  1. --message ''
  2. --no-verify
  3. --squash
  4. --no-post-rewrite

Answer(s): B

Explanation:

The commit-msg hook is invoked by git-commit and git-merge, and can be bypassed with the --no-verify option.


Reference:

https://git-scm.com/docs/githooks



You manage code by using GitHub.

You plan to ensure that all GitHub Actions are validated by a security team.

You create a branch protection rule requiring that code changes be reviewed by code owners.

You need to create the CODEOWNERS file.

Where should you create the file?

  1. .github/
  2. .git/
  3. .github/actions/
  4. .github/workflows/

Answer(s): B

Explanation:

In the situation you want consume the results directly from a file you can read ./codeowner-information.json from the root of the repository.
Incorrect:
Not A: Custom path
If your CODEOWNERS file isn't in the root of your repository, but for instead in the .github directory, you can change the path by using the path parameter:
- id: codeowner uses: SvanBoxel/codeowners-action@v1
with:
path: './.github/CODEOWNERS'


Reference:

https://github.com/marketplace/actions/codeowners-action



Viewing page 31 of 72
Viewing questions 151 - 155 out of 398 questions


Post your Comments and Discuss Microsoft AZ-400 exam prep with other Community members:

AI Tutor AI Tutor 👋 I’m here to help!