Microsoft AZ-400 (Designing and Implementing Microsoft DevOps Solutions) Practice Test 21

Question 200

A customer incident requires keeping one specific build's logs and artifacts longer than the project's normal cleanup schedule. What retention action helps?

  1. Diagnose self-hosted agent exhaustion
  2. Set artifact retention by compliance category
  3. Identify unreliable external service dependencies
  4. Pin important runs from automatic retention

Explanation

Correct Answer

D:

Retention leases or supported keep-forever controls can protect selected runs and their records from routine expiration.

Incorrect Answers

A:

Agent utilization and queue length reveal whether workload demand exceeds available qualified worker capacity; here exceptional run preservation is the target, not peak worker utilization shortage.

B:

Different retention requirements should be applied to short-lived build outputs and preserved release assets according to compliance needs; although that supports tiered artifact lifecycle, this scenario calls for exceptional run preservation.

C:

Failure categorization by task and external dependency distinguishes platform or network outages from code defects; exceptional run preservation cannot be inferred from external dependency build failures alone.

Question 201

Many approved build pipelines must read a shared Azure Pipelines variable group containing nonsecret build settings. Only release engineering may change its values. Which permission design preserves both requirements?

  1. Grant all pipeline authors Administrator rights on the variable group
  2. Authorize no pipeline to use the variable group
  3. Use a Git branch policy as the sole control over Library value changes
  4. Limit variable-group administration to release engineering while authorizing appropriate pipelines to consume it

Explanation

Correct Answer

D:

Azure Pipelines Library permissions distinguish administration of a variable group from its use by authorized pipelines. Restrict management rights to release engineering and approve consumption separately.

Incorrect Answers

A:

Administrator access permits management of the variable group, including configuration changes. Giving that role to every pipeline author defeats the requirement to limit editing.

B:

Removing all pipeline authorization protects the group from consumption but also prevents the explicitly approved builds from receiving their settings.

C:

Branch policies protect merges into repository branches; a Library variable group is a separate protected Azure DevOps resource. The branch rule cannot by itself restrict edits in the Library.

Question 202

A .NET API has no request timing, failure, or dependency telemetry and operators need application-level visibility. What instrumentation service should be enabled?

  1. Use sampling to control high-volume telemetry
  2. Inspect exception telemetry with stack context
  3. Instrument the application with Application Insights
  4. Use correlation IDs across services

Explanation

Correct Answer

C:

Application Insights collects application requests, failures, dependencies, traces, and usage signals through supported instrumentation.

Incorrect Answers

A:

Telemetry sampling reduces selected event volume while retaining enough context for supported analysis and correlated investigation; that acts on cost-aware telemetry volume control, whereas the requested outcome is code-level service performance observation.

B:

Exception telemetry captures application error details, potentially including stack information and related operation context; application exception root-cause evidence concerns a different control point than code-level service performance observation.

D:

Propagating trace context or correlation identifiers associates related telemetry across service boundaries; although that supports shared operation identity, this scenario calls for code-level service performance observation.

Question 203

A third-party scanner only needs source reading and status reporting, but its integration currently has repository administration rights. Which redesign reduces risk?

  1. Scan open-source license obligations
  2. Run CodeQL analysis inside a controlled container
  3. Connect GitHub Advanced Security findings to Defender for Cloud
  4. Use least-privilege tokens for security scanners

Explanation

Correct Answer

D:

Grant only the API permissions necessary to retrieve code and publish assessment results, keeping repository administration separate.

Incorrect Answers

A:

Software composition analysis with license rules identifies component license metadata and can enforce organizational usage policies; its effect is dependency legal compliance, not narrow automation scanner identity.

B:

Running the supported CodeQL analysis workflow in a managed container isolates scanner tooling and makes its runtime dependencies repeatable across builds; that changes isolated static-analysis execution environment without delivering narrow automation scanner identity.

C:

Supported integration of GitHub Advanced Security with Defender for Cloud can bring repository security signals into cloud-focused posture views; unified repository vulnerability posture cannot substitute for narrow automation scanner identity.

Question 204

Operators need to understand how a service degrades when traffic exceeds safe operating thresholds and whether it recovers afterward. Which performance test fits?

  1. Run integration tests against dependent services
  2. Run stress tests beyond expected capacity
  3. Separate flaky tests from product regressions
  4. Collect failing test logs and artifacts

Explanation

Correct Answer

B:

Stress tests deliberately exceed normal capacity to identify breaking points, failure modes, and recovery behavior.

Incorrect Answers

A:

Integration tests exercise interactions between actual components or representative dependencies and detect contract and configuration mismatches; it handles real component interaction verification but cannot by itself deliver overload failure characterization.

C:

Identify and quarantine or stabilize nondeterministic tests while recording their outcomes, rather than hiding instability with unlimited retries; that acts on nondeterministic-test root cause management, whereas the requested outcome is overload failure characterization.

D:

Publishing diagnostic logs and test-result artifacts preserves failure evidence independently of the agent workspace lifecycle; durable failed-run diagnostics concerns a different control point than overload failure characterization.

Question 205

A new engineer needs supported Repos and Pipelines capabilities that are not included in a limited stakeholder experience. Which access level is normally required?

  1. Protect variable groups containing secrets
  2. Use project-scoped groups rather than organization-wide admins
  3. Separate access level from security permissions
  4. Use Basic access for typical development features

Explanation

Correct Answer

D:

Basic access supports core Azure DevOps development features subject to the project's security permissions. Access levels determine feature entitlement; repository and project permissions still govern what the engineer can actually change.

Incorrect Answers

A:

Variable-group permissions and approved pipeline access restrict exposure of protected variables to authorized consumers; the distinction is pipeline-bounded shared secret access versus full everyday developer feature access.

B:

Project-level group membership limits administrative reach compared with organization or collection-wide administrative roles; full everyday developer feature access cannot be delivered through scoped Azure DevOps project administration.

C:

Access level controls feature entitlements while repository and branch permissions govern actions on specific project resources; its effect is distinction between entitlement and permission, not full everyday developer feature access.

Question 206

A new pipeline accidentally checks out a similarly named repository from another owner, creating wrong build artifacts. What binding should be corrected?

  1. Configure GitHub status checks for Azure Pipeline validation
  2. Select the correct GitHub repository in an Azure Pipeline
  3. Use pipeline checkout credentials only for required operations
  4. Use the repository commit for PR validation

Explanation

Correct Answer

B:

The pipeline's repository configuration and authorized GitHub connection determine which source repository and branch are used.

Incorrect Answers

A:

The pipeline reports status, while GitHub branch rules must explicitly require the relevant status check before merge; this solves mandatory consumption of external CI status, leaving exact source repository selection unresolved.

C:

The job must use an authorized identity with repository write rights and deliberately expose credentials where a push operation is necessary; it handles controlled writeback from pipeline execution but cannot by itself deliver exact source repository selection.

D:

The pipeline run's source version identifies the precise commit or merge revision that the validation operated on; exact source repository selection remains outside the responsibility of immutable PR validation revision.

Question 207

Any pipeline in the project can fetch a production signing file, although only a dedicated release definition should use it. Which authorization needs tightening?

  1. Restrict permissions to download signing secure files
  2. Keep secrets out of generated artifacts
  3. Use an Azure Pipelines Key Vault-linked variable group
  4. Use GitHub encrypted secrets for a third-party API token

Explanation

Correct Answer

A:

Secure-file pipeline permissions limit which definitions may download protected file assets during runs. Authorize only the release pipeline to use this secure file; merely storing it securely does not restrict all consumers.

Incorrect Answers

B:

Artifact content inspection and secret scanning can detect sensitive files included in release payloads before distribution; signing file consumer allowlist cannot be inferred from avoiding credentials in distributed binaries alone.

C:

A Key Vault-linked variable group maps selected vault secrets into authorized pipelines at runtime; the distinction is reusable protected vault references versus signing file consumer allowlist.

D:

GitHub Actions encrypted secrets supply protected values to authorized workflows at execution time; signing file consumer allowlist cannot be delivered through encrypted workflow credential injection.

Question 208

A repository needs Linux lint and test jobs that do not require private network access or custom licensed software. Which runner choice simplifies operations?

  1. Use environments with required reviewers in GitHub
  2. Upload workflow artifacts for later jobs
  3. Use a self-hosted GitHub runner for specialist hardware
  4. Use a GitHub-hosted runner for disposable jobs

Explanation

Correct Answer

D:

GitHub-hosted runners provide managed disposable execution environments with common tooling and no persistent team-managed agent.

Incorrect Answers

A:

GitHub environments can apply protection rules such as required reviewers before guarded deployment jobs proceed; managed workflow job execution falls outside the scope of protected GitHub deployment approval.

B:

Artifact upload stores files associated with a workflow run outside the temporary runner filesystem; it contributes to durable GitHub test attachments, with managed workflow job execution still requiring its own control.

C:

Self-hosted runners execute jobs on administrator-managed machines where specialized devices and licensed tools can be installed; this solves workflow access to custom hardware, leaving managed workflow job execution unresolved.

Question 209

A security-sensitive package must be managed in one Azure DevOps project with deliberate permissions for any other project that consumes it. Which scope is sensible?

  1. Separate feed publication from feed promotion
  2. Use project-scoped feeds for narrow ownership
  3. Use a package proxy strategy for build continuity
  4. Authenticate restore tasks to Azure Artifacts

Explanation

Correct Answer

B:

Project-scoped feeds align package access with project boundaries and can authorize external projects explicitly.

Incorrect Answers

A:

Publishing to the feed and independently promoting selected versions to a release view separates creation from trust decisions; package release authorization step concerns a different control point than project-bounded package administration.

C:

Caching packages through configured upstream sources can preserve availability of previously saved versions when their original source is disrupted; although that supports resilience to remote registry outages, this scenario calls for project-bounded package administration.

D:

Package authentication steps and feed permissions provide a job identity with the credentials needed to restore protected dependencies; project-bounded package administration cannot be inferred from pipeline identity for private package restore alone.

Question 210

A pipeline author attempts to insert a production credential using a compile-time expression in repository YAML. Which safer design should replace that?

  1. Create a jobs template for common verification jobs
  2. Avoid expanding secrets into compile-time templates
  3. Use task groups for legacy classic build tasks
  4. Use protected variable groups for secrets

Explanation

Correct Answer

B:

Runtime secret variables or Key Vault retrieval keep sensitive values out of source-controlled template expansion and minimize accidental disclosure.

Incorrect Answers

A:

A jobs template encapsulates job definitions so each caller obtains the same validated worker and task structure; that changes reusable complete job without delivering separating secrets from YAML compilation.

C:

Task groups wrap reusable task sequences for classic pipelines, distinct from YAML template composition; separating secrets from YAML compilation falls outside the scope of classic-pipeline task reuse.

D:

Variable groups can be authorized for specific pipelines and supplemented with approvals or checks where supported; it contributes to authorized shared-secret consumption, with separating secrets from YAML compilation still requiring its own control.

Designing and Implementing Microsoft DevOps Solutions (AZ-400) Practice Tests