Question 350
A private key was accidentally committed and the repository was later shared. Which TWO remediation actions address both historical copies and ongoing credential risk? Choose TWO.
- Use git reset on unpublished local work
- Rotate exposed credentials immediately
- Use git stash for temporary unfinished edits
- Use git filter-repo to rewrite sensitive history
- Restore one tracked file from a previous commit
Explanation
Correct Answers
B:Credential revocation or rotation invalidates a secret that may already have been copied; history rewriting alone cannot restore secrecy; revoking leaked credentials is necessary even if the repository history is rewritten, because forks and caches can retain copies.
D:git filter-repo rewrites repository history to remove selected paths or blobs; credentials must also be revoked and old clones addressed.
Incorrect Answers
A:git reset can move the branch reference and optionally change the index and working tree; it should be used carefully on private history; this solves moving an unpublished branch pointer, leaving full-history sensitive blob removal unresolved.
C:git stash saves eligible uncommitted work for later reapplication, freeing the worktree for a different task; it handles temporary worktree shelving but cannot by itself deliver full-history sensitive blob removal.
E:git restore with a chosen source revision retrieves a file's content from the specified tree into the worktree or index; that acts on recovering selected file contents, whereas the requested outcome is full-history sensitive blob removal.
Question 351
Operators need memory, process, and dependency visibility across an Azure VM fleet, not only the default platform CPU metric. Which Azure Monitor solution fits?
- Use Azure Monitor network monitoring
- Use KQL project to limit output columns
- Use KQL summarize percentiles for latency
- Use Azure VM insights for guest performance
Explanation
Correct Answer
D:VM insights collects supported guest performance and dependency data from configured virtual machines through monitoring agents.
Incorrect Answers
A:Network monitoring capabilities integrate supported connectivity, flow, and performance signals for troubleshooting network paths; although that supports Azure network connection observability, this scenario calls for virtual machine guest-state observability.
B:project selects and can rename the columns returned by a KQL query, producing a focused investigation result; virtual machine guest-state observability cannot be inferred from KQL selected-column shaping alone.
C:Percentile aggregation exposes tail behavior that arithmetic averages can hide, making high-latency outliers visible; the distinction is tail-latency distribution analysis versus virtual machine guest-state observability.
Question 352
Hosted agents spend many minutes installing the same supported SDKs and compilers on every build. Which infrastructure choice can improve startup?
- Use selective test execution for monorepo changes
- Use retention policies to constrain storage cost
- Move repeated setup into a prebuilt image
- Reuse existing build output during classic-to-YAML migration
Explanation
Correct Answer
C:A maintained prebuilt worker or container image provides standard toolchains without repeating their installation in each job.
Incorrect Answers
A:Path-aware test selection can run affected verification suites while retaining full broader checks at appropriate release gates; preprovisioned build dependencies falls outside the scope of change-impact-based verification.
B:Targeted run and artifact retention policies delete disposable build data while preserving defined compliance evidence; it contributes to bounded nonrelease artifact storage, with preprovisioned build dependencies still requiring its own control.
D:Pipeline resources and artifact download steps let new YAML deployment stages consume an existing immutable build output; this option addresses migration without rebuilding the release rather than addressing preprovisioned build dependencies.
Question 353
An Azure Pipeline must build a GitHub repository with PR status and repository event integration; maintainers want an app-based authorization model. Which connection is appropriate?
- Reference a template from another repository
- Protect external repository resource triggers
- Connect GitHub via the Azure Pipelines GitHub App
- Configure GitHub status checks for Azure Pipeline validation
Explanation
Correct Answer
C:The Azure Pipelines GitHub App authorizes access to selected repositories and integrates pipeline checks with GitHub pull requests.
Incorrect Answers
A:An external template repository resource lets pipeline YAML import standardized templates from a separately versioned source; remote shared YAML composition concerns a different control point than app-scoped GitHub pipeline integration.
B:Repository resource triggers and release stage conditions should restrict which trusted source revisions may initiate sensitive downstream work; here app-scoped GitHub pipeline integration is the target, not trusted cross-repository activation.
D:The pipeline reports status, while GitHub branch rules must explicitly require the relevant status check before merge; app-scoped GitHub pipeline integration cannot be inferred from mandatory consumption of external CI status alone.
Question 354
A web service needs to stage a complete replacement environment, test it, and then shift production traffic with a fast rollback path. Which pattern fits?
- Use percentage-based feature targeting
- Use blue-green deployment to switch environments
- Use canary deployment for small initial exposure
- Use shadow traffic for compatibility testing
Explanation
Correct Answer
B:Blue-green deployment maintains two environment versions and switches routing between them after readiness checks.
Incorrect Answers
A:Percentage targeting can expose a flag to a configured user share using consistent targeting rules where supported; that changes stable fractional feature audience without delivering full-environment traffic cutover.
C:Canary deployment exposes a new version to a limited traffic subset before broadening it based on monitored results; full-environment traffic cutover falls outside the scope of low-percentage release exposure.
D:Shadow traffic duplicates requests to a candidate system while production responses continue coming from the existing system; it contributes to noncustomer-impacting candidate request replay, with full-environment traffic cutover still requiring its own control.
Question 355
A feature flag has been enabled for every customer for months. The old code path is no longer supported, and dormant conditional branches slow testing and confuse incident reviews. What should the team do?
- Remove the obsolete flag and old conditional code after confirming rollout is permanent
- Keep the flag and inactive implementation indefinitely to retain a theoretical rollback path
- Create a permanent feature branch containing the old implementation
- Stop instrumenting the feature because the rollout has completed
Explanation
Correct Answer
A:Removing a permanently enabled flag and its dead branch reduces code paths, test combinations, and maintenance risks. First verify that rollout is complete and that no supported consumer depends on the old behavior.
Incorrect Answers
B:A stale flag keeps obsolete branches live in the codebase, forcing future engineers to reason about behavior the product no longer supports. It increases the complexity the team is trying to remove.
C:A permanent branch would introduce another source of divergence and does not remove the redundant runtime conditional logic in the production mainline.
D:A successful rollout does not eliminate the need to observe errors and performance regressions. Disabling telemetry cannot simplify the leftover flag logic.
Question 356
Old and new application versions coexist during a gradual rollout, but a schema change would otherwise break the older code. Which database evolution pattern helps?
- Deploy an urgent hotfix through a controlled fast path
- Apply expand-and-contract database migration
- Plan a forward fix when rollback is unsafe
- Use readiness probes behind a load balancer
- Use idempotent deployment scripts
Explanation
Correct Answer
B:Expand-and-contract migrations introduce backward-compatible schema changes first, transition consumers, and remove old structures only after compatibility is no longer needed.
Incorrect Answers
A:A hotfix branch or targeted change can pass abbreviated risk-based checks and controlled promotion while preserving audit links and a merge-back plan; schema compatibility during version overlap cannot be delivered through expedited traceable emergency release.
C:Forward-compatible remediation or compensating migrations may be necessary when application rollback cannot safely reverse a data change; that changes recovery after irreversible schema transition without delivering schema compatibility during version overlap.
D:Readiness checks keep instances out of eligible traffic rotation until they can serve real requests; traffic admission after application readiness cannot substitute for schema compatibility during version overlap.
E:Idempotent operations reach the desired end state even when repeated, making safe retries possible after partial execution; schema compatibility during version overlap falls outside the scope of repeatable partial deployment recovery.
Question 357
One integration suite takes ninety minutes but individual test cases are independent and can run on multiple agents. Which optimization reduces its wall-clock time?
- Shard a long test suite across workers
- Cache compiler or package dependencies
- Use selective test execution for monorepo changes
- Constrain unnecessary parallelism
Explanation
Correct Answer
A:Test sharding partitions cases among concurrent workers and combines their reports, reducing the duration of an otherwise serial test job.
Incorrect Answers
B:Pipeline caching reuses eligible dependency or tool directories keyed by their inputs, reducing repeated setup without replacing artifact publication; it handles reducing repeatable job setup work but cannot by itself deliver distributed test-case execution.
C:Path-aware test selection can run affected verification suites while retaining full broader checks at appropriate release gates; distributed test-case execution remains outside the responsibility of change-impact-based verification.
D:Concurrency caps balance worker cost against the small marginal latency benefit of additional parallel execution; that acts on cost-aware job fanout, whereas the requested outcome is distributed test-case execution.
Question 358
A service runs twelve healthy replicas and must replace them gradually while keeping enough capacity online. Which strategy meets the goal?
- Use a kill switch for risky functionality
- Use progressive exposure with automatic health gates
- Use rolling deployment to update instances incrementally
- Separate rollout from rollback triggers
Explanation
Correct Answer
C:Rolling deployment updates bounded sets of instances and keeps unaffected replicas serving traffic during the transition.
Incorrect Answers
A:A remotely controlled feature flag can disable the affected path quickly while leaving the running binary unchanged; gradual replica replacement cannot be inferred from instant reversible feature disablement alone.
B:Progressive delivery couples staged exposure with monitored health metrics so advancement can stop or reverse on regression; the distinction is telemetry-gated exposure expansion versus gradual replica replacement.
D:Rollout gates should watch production health indicators and initiate rollback or halt when configured thresholds are violated; its effect is health-based rollout abort, not gradual replica replacement.
Question 359
A GitHub workflow changes a version file and pushes a commit, while other API powers should remain disabled. Which permission should be scoped carefully?
- Use a fine-grained personal access token when a PAT is unavoidable
- Use protected environments to gate secret access
- Require minimal contents write for automated version bumps
- Use GITHUB_TOKEN for same-repository workflow tasks
- Use outside collaborator access for a contractor
Explanation
Correct Answer
C:Assign the minimum repository contents write authority needed for the push and avoid granting unrelated token scopes.
Incorrect Answers
A:Fine-grained personal access tokens can narrow repository selection, permissions, and expiration compared with broad classic tokens; it contributes to limited user-backed integration access, with narrow workflow source modification rights still requiring its own control.
B:GitHub environment protection rules can gate job execution and access to environment-scoped secrets; this solves guarded production secret exposure, leaving narrow workflow source modification rights unresolved.
D:GITHUB_TOKEN is automatically created for the workflow job and can be scoped through the permissions key for repository operations; it handles ephemeral built-in workflow authorization but cannot by itself deliver narrow workflow source modification rights.
E:Outside collaborators receive targeted repository access without organization membership, under relevant organizational restrictions; narrow workflow source modification rights remains outside the responsibility of repository-only external participation.
Question 360
Reviewers live in Teams and want selected pull request and issue changes posted to a team channel automatically. Which integration should be enabled?
- Filter service-hook subscriptions by event
- Send deployment status via pipeline notifications
- Use Azure Boards team dashboards
- Subscribe a Teams channel to GitHub events
Explanation
Correct Answer
D:GitHub integration with Microsoft Teams surfaces repository activity in a selected channel based on subscription configuration.
Incorrect Answers
A:Event type and available subscription filters narrow Azure DevOps service-hook traffic before payload delivery; here GitHub-to-Teams collaboration events is the target, not event selection before webhook dispatch.
B:Notifications triggered on deployment-stage outcomes avoid confusing development activity with production release status; although that supports production failure event targeting, this scenario calls for GitHub-to-Teams collaboration events.
C:Team dashboards group widgets for an Azure DevOps team's work and delivery context, keeping operational views aligned to team scope; GitHub-to-Teams collaboration events cannot be inferred from team-specific delivery visibility alone.