AnalysisTemplate and AnalysisRun: CAPA practice questions
Analysis is how Argo Rollouts decides, from metrics, whether a release may continue. It uses three related resources. An AnalysisTemplate is a reusable, namespaced specification of what to measure: one or more metrics, how often to take each measurement and which results count as success or failure.
By Ibrahim Yesilay · Published · Updated
Independent community practice, not affiliated with or endorsed by CNCF or The Linux Foundation.
What AnalysisTemplate and AnalysisRun covers in CAPA
Analysis is how Argo Rollouts decides, from metrics, whether a release may continue. It uses three related resources. An AnalysisTemplate is a reusable, namespaced specification of what to measure: one or more metrics, how often to take each measurement and which results count as success or failure. A ClusterAnalysisTemplate is the same thing at cluster scope, available to any Rollout, and is referenced with clusterScope: true. An AnalysisRun is an instantiation of a template for one Rollout revision; like a Job, it eventually completes.
Each metric names a provider and its query. Built-in providers include Prometheus, Datadog, New Relic, CloudWatch, Wavefront, Graphite, InfluxDB, Kayenta and SkyWalking, a web provider calls an HTTP endpoint, a job provider runs a Kubernetes Job and judges it by success or failure, and new integrations are added as plugins. successCondition and failureCondition are expressions over the result, for example result[0] >= 0.95. interval sets the time between measurements and count the number of measurements; a metric without an interval takes a single measurement, and one with an interval but no count keeps measuring until the Rollout stops it. failureLimit sets how many failed measurements are tolerated, consecutiveErrorLimit how many errors in a row are tolerated, four by default, and inconclusiveLimit how many inconclusive results are allowed. initialDelay waits before the first measurement.
An AnalysisRun ends Successful, Failed or Inconclusive, and the Rollout continues, aborts or pauses accordingly. A run is inconclusive when a metric has no conditions at all, or when a value meets neither condition, and it then needs a person to resume or abort the Rollout.
Templates are parameterised with args. The template declares arguments and uses them as {{args.name}} in queries, and the Rollout passes values, either literally or from the Pod template hash and other fields with valueFrom. Templates can also be combined: a Rollout can list several, and the controller merges their metrics and arguments into one run. In a canary, background analysis starts with the update, optionally from a startingStep, and runs alongside the steps, while an inline analysis step blocks progress until its run completes. A blue-green Rollout uses prePromotionAnalysis and postPromotionAnalysis instead. dryRun evaluates a metric without letting it affect the Rollout, which helps when introducing a new query.
Key points
- An AnalysisTemplate defines the metrics; an AnalysisRun is its instantiation for one revision.
- Successful, Failed and Inconclusive runs make the Rollout continue, abort or pause.
- A metric with no success or failure condition produces an inconclusive result.
- ClusterAnalysisTemplates are shared cluster-wide and referenced with clusterScope: true.
Three sample questions
12 CAPA questions on AnalysisTemplate and AnalysisRun, 12 with explanations. How practice works
Question 1
- A.A
pausestep with aduration, which promotes the canary once the time is up - B.Analysis templates
- C.Anti-affinity injected into the new ReplicaSet so its pods avoid nodes running the old version
- D.Promotion rules
Correct answer: B
pause step with a duration, which promotes the cana...": a timed pause only waits for the duration and then moves on; it looks at no metric. "Anti-affinity injected into the new ReplicaSet so its po...": anti-affinity only controls pod placement on nodes and has nothing to do with promotion. "Promotion rules": the Rollouts docs have no feature by that name; metric-driven promotion is done with analysis.Sources: Argo Rollouts docs: Analysis & Progressive Delivery, Argo Rollouts docs: Canary, Argo Rollouts docs: Anti Affinity
Question 2
- A.To analyze deployment logs and surface error patterns found in the container output
- B.To define metric queries and thresholds
- C.To analyze resource usage such as CPU and memory consumed by the new ReplicaSet
- D.To monitor service health
Correct answer: B
Sources: Argo Rollouts docs: Analysis & Progressive Delivery
Question 3
- A.The rollout is paused for manual intervention
- B.The analysis is ignored and only recorded as an event, so the canary weight stays unchanged
- C.The rollout is automatically aborted and rolled back
- D.The rollout continues automatically to the next canary step, treating the failed metrics as advisory only
Correct answer: C
Sources: Argo Rollouts docs: Analysis
Practice this topic
Focus mode keeps every question on AnalysisTemplate and AnalysisRun until you leave it. 10 free guest answers, then a free account; no credit card.
Or open CAPA practice across all topics.
Sources
The explanation above was checked against these official documents.
- Argo Rollouts docs: Analysis and progressive delivery (checked 2026-10-28)
- Argo Rollouts docs: Architecture (checked 2026-10-28)
- Argo Rollouts docs: FAQ (checked 2026-10-28)
- Argo Rollouts docs: Canary deployment strategy (checked 2026-10-28)