Bird
0
0

Which of the following is the correct syntax to trigger a pipeline only for Service A in a CI/CD system?

easy📝 Conceptual Q3 of 15
Microservices - CI/CD for Microservices
Which of the following is the correct syntax to trigger a pipeline only for Service A in a CI/CD system?
Atrigger: branches: - 'main' - 'develop'
Btrigger: all: true
Ctrigger: exclude: - 'serviceA/**'
Dtrigger: paths: - 'serviceA/**'
Step-by-Step Solution
Solution:
  1. Step 1: Understand pipeline triggers

    Triggering pipelines based on file paths limits runs to changes in specific service folders.
  2. Step 2: Analyze options

    trigger: paths: - 'serviceA/**' triggers only when files in 'serviceA' change; others trigger on all changes or exclude serviceA.
  3. Final Answer:

    trigger: paths: - 'serviceA/**' -> Option D
  4. Quick Check:

    Path-based trigger = service-specific pipeline [OK]
Quick Trick: Use path triggers to isolate service pipelines [OK]
Common Mistakes:
  • Triggering on all branches ignores service specificity
  • Excluding service paths triggers unrelated services
  • Not using path filters causes unnecessary builds

Want More Practice?

15+ quiz questions · All difficulty levels · Free

Free Signup - Practice All Questions
More Microservices Quizzes