Microsoft DevOps Engineer Expert AZ-400 Practice Question

You need to define a branching and deployment strategy for a GitHub repository that hosts an enterprise-wide Node.js microservice. The requirements are:

  • The 'main' branch must always contain code that is ready to be promoted to production.
  • New work should be isolated without blocking other teams.
  • Code reviews and automated tests must run before the code is merged.
  • The repository's history should stay linear and easy to trace. Which approach satisfies these requirements and follows GitHub Flow principles?
  • Commit directly to 'main', tag a semantic version when ready, and trigger the release pipeline from the tag without using pull requests or CI checks.

  • Create environment branches named 'dev', 'stage', and 'prod'; merge pull requests sequentially between them to promote releases while allowing direct pushes to 'dev' for urgent fixes.

  • Create short-lived topic branches from 'main', open a pull request that requires at least one approving review and a passing CI workflow, then squash and merge the pull request back into 'main', triggering an automated deployment pipeline.

  • Maintain a persistent 'development' branch where all features are merged. Once a sprint ends, create a pull request from 'development' to 'main' and deploy after manual testing.

Microsoft DevOps Engineer Expert AZ-400
Design and implement processes and communications
Your Score:
Settings & Objectives
Random Mixed
Questions are selected randomly from all chosen topics, with a preference for those you haven’t seen before. You may see several questions from the same objective or domain in a row.
Rotate by Objective
Questions cycle through each objective or domain in turn, helping you avoid long streaks of questions from the same area. You may see some repeat questions, but the distribution will be more balanced across topics.

Check or uncheck an objective to set which questions you will receive.

Bash, the Crucial Exams Chat Bot
AI Bot