Scrivio Interview library
DesignAdvanced7 min read · updated 12 November 2026

Design a progressive delivery standard for 100 Java services, including automated canary analysis and rollback.

I would standardise on one deployment controller, such as Argo Rollouts or Flagger, that moves traffic to a new version in canary steps and checks standard metrics at each step: error rate, latency percentiles and saturation, compared against the stable version. When a metric breaches its threshold, the controller rolls back automatically. The standard also requires backward-compatible schema and API changes, ships as a default template in the golden path, and allows exceptions only through review.

Why this question is asked

With 100 services, every team inventing its own release process means 100 different ways to break production. Progressive delivery, releasing a new version to a growing share of traffic while automatically checking its health, turns each deployment into a small, measured experiment. Interviewers ask this design question to see whether we can build a standard that is safe by default, cheap for teams to adopt, and honest about its limits. In this answer, we will recap what progressive delivery is, choose the controller, define the analysis metrics and thresholds, automate rollback, cover the compatibility rules it depends on, and plan how the standard is rolled out to teams.

1A Quick Recap of Progressive Delivery

In a plain rolling deployment, Kubernetes replaces pods until all run the new version, and nobody checks whether the new version is healthy beyond its readiness probe. A canary release improves on that by sending a small share of traffic, say 5 percent, to the new version first. Progressive delivery automates the canary: a controller increases the share in steps, analyses metrics at each step, and either continues or rolls back without a human watching dashboards.

The key word is automated. People are bad at watching graphs for 40 minutes on the 30th deployment of the day, and with 100 services deploying several times a day, manual canaries would either slow everything down or be skipped.

2Choosing the Deployment Controller

Two controllers are common on Kubernetes. Argo Rollouts replaces the Deployment object with a Rollout resource that describes the steps and links to analysis templates. Flagger works alongside an existing Deployment and a service mesh or ingress controller, creating the canary resources itself. Both can split traffic precisely through a mesh or an ingress, and both can query Prometheus or other metric providers. I would pick one, based on what the clusters already run (for example, a team already on Argo CD often chooses Argo Rollouts), and support only that one, because a single controller means one set of templates, one set of dashboards and one runbook.

YAML
apiVersion: argoproj.io/v1alpha1
kind: Rollout
metadata: { name: orders }
spec:
replicas: 6
strategy:
canary:
analysis:
templates: [ { templateName: standard-java-service } ] # runs during the whole rollout
args: [ { name: service, value: orders } ]
startingStep: 1
steps:
- setWeight: 5
- pause: { duration: 5m }
- setWeight: 25
- pause: { duration: 10m }
- setWeight: 50
- pause: { duration: 10m }
# then 100 percent

Notice that the steps live in the template, not in each team's head. A team with special needs can change durations, but the shape is the same everywhere.

3Defining the Standard Metrics

The analysis is only as good as its metrics. Since every service in the golden path exposes the same Micrometer metrics, the standard can query the same names everywhere. I would use three groups. Error rate: the share of requests returning 5xx, for the canary only. Latency percentiles: p95 and p99 of http.server.requests, because averages hide the slow tail. Saturation: CPU, heap after GC, and connection pool pending threads, because a new version can be correct but much more expensive.

Each metric needs a threshold. Fixed limits are simple, for example an error rate below 1 percent. Comparing the canary with the stable version is often better, for example canary p99 no more than 20 percent above stable p99, because it adapts to the time of day and the service's normal level.

YAML
apiVersion: argoproj.io/v1alpha1
kind: AnalysisTemplate
metadata: { name: standard-java-service }
spec:
args: [ { name: service } ]
metrics:
- name: error-rate
interval: 1m
failureLimit: 2 # two bad readings -> rollback
successCondition: result[0] < 0.01 # under 1 percent 5xx
provider:
prometheus:
address: http://prometheus.monitoring:9090
query: |
sum(rate(http_server_requests_seconds_count{service="{{args.service}}",role="canary",status=~"5.."}[2m]))
/ sum(rate(http_server_requests_seconds_count{service="{{args.service}}",role="canary"}[2m]))

The label names in the query depend on how the platform tags canary pods, so they belong in the shared template, written once by the platform team and tested.

4Automating the Rollback

When analysis fails, the controller sets the canary weight back to zero and scales the new version down, so all traffic returns to the stable version within seconds. It also marks the rollout as aborted and the pipeline sends a notification with the failed metric and its value, so the team knows why. No one has to be awake for a bad deployment to be reversed.

Two details make this reliable. The canary must get enough traffic for the statistics to mean something: a service with 10 requests per minute at 5 percent produces one request every two minutes, so for low-traffic services the template uses longer pauses, a larger first step, or synthetic traffic. And metrics that need minutes to react, such as heap growth, need steps long enough to show the problem.

Step throughOne automated canary
  1. Deploy new version at 5 percentStable version keeps 95 percent
  2. Analyse error rate, p99, saturationCanary compared with stable
  3. Metrics within thresholds?
    YesIncrease weight: 25, 50, 100NoSet weight to 0 and roll back
  4. Reached 100 percent?
    YesPromote, scale down old versionNoAnalyse the next step
  5. Notify the teamResult, failed metric and value

5 steps in order. Play them, or step through them one at a time.

The controller decides at every step; people only hear about the result.

5What Progressive Delivery Cannot Protect Against

A canary assumes that rolling back is harmless. That is only true if the new version did not make changes the old version cannot handle. So the standard requires backward-compatible changes: database migrations use expand and contract, so both versions work with the schema; API changes add fields rather than removing or renaming them; and message formats stay readable by consumers on the old version. These rules go into the code review checklist and, where possible, automated checks such as contract tests and migration linting.

It also cannot catch problems that only show up in metrics we do not measure, such as wrong prices that return HTTP 200. For critical flows, teams can add business metrics to their analysis, for example the checkout success rate.

6Rolling Out the Standard to 100 Teams

The standard succeeds only if it is the easy path. I would ship it as a default template in the golden path: new services get a Rollout, the standard analysis and dashboards automatically, and existing services migrate with a small change and help from the platform team, starting with the most critical ones. Exceptions are allowed, for example a batch job or a service that cannot split traffic, but they go through a short review and are recorded, so we know where the gaps are.

Finally, I would measure the result: change failure rate, the share of bad deployments caught automatically before reaching all users, and time to restore. Those numbers show teams and leaders that the standard is paying off.

7Follow-up questions

How do you handle services with very little traffic?

The statistics get weak, so the template for them uses longer analysis windows, fewer and larger steps, or synthetic requests that exercise the main endpoints. For very low traffic, a blue-green style with smoke tests before the switch can be more meaningful than a percentage canary.

What if a canary fails because of noise, not a real problem?

Then the thresholds are too tight or the analysis window too short. failureLimit, which allows a number of bad readings before failing, and comparing against the stable version rather than fixed values reduce noise. We track false rollbacks as a metric, because teams stop trusting a system that rolls back good releases.

Should every deployment use the full set of canary steps?

Not necessarily. Configuration-only changes or low-risk services can use shorter steps, while critical services such as payments might add more steps and longer pauses. The template offers a few profiles so teams choose a level rather than writing their own.

8Conclusion

In this answer, we designed a progressive delivery standard for 100 Java services: one controller such as Argo Rollouts or Flagger, canary steps defined in a shared template, standard analysis on error rate, latency percentiles and saturation, and automatic rollback when thresholds are breached. It depends on backward-compatible schema and API changes, ships as the default in the golden path with reviewed exceptions, and is judged by change failure rate and time to restore.

What to say in the interviewAbout 90 seconds aloud

Open with

I would pick one deployment controller for all clusters, Argo Rollouts or Flagger depending on what we already run, and package it as a default template in the golden path.

Then, if they want more

The template defines canary steps, for example 5, 25, 50 and then 100 percent with pauses of five to ten minutes. At each step the controller runs a standard analysis against Prometheus using the metrics every service already exposes through Micrometer: 5xx error rate, p95 and p99 latency, and saturation like CPU, heap after GC and connection pool pending threads.

I prefer comparing the canary with the stable version, for example canary p99 no more than 20 percent worse, plus a few absolute limits, with a failure limit so one noisy reading does not abort. If a metric breaches, the controller sets the canary weight to zero, scales it down and notifies the team with the failed metric.

For low-traffic services the template uses longer windows or synthetic traffic so the statistics mean something. Automatic rollback only works if rollback is safe, so the standard also requires backward-compatible changes: expand and contract migrations, additive API changes and readable message formats, enforced through review and contract tests. Teams can request exceptions, which are reviewed and recorded.

And I would track change failure rate, time to restore and the share of bad releases caught by the canary to show it works.

About this answer

Last updated
12 November 2026
Checked
Its structure and format are checked automatically. Use it as a carefully prepared study note: where a detail matters, confirm it against the documentation below. What the checks cover
Where the question comes from
Written by Scrivio for practice. It is not taken from an interview.
Report an issue with this answer

Copy the line below and send it to the author with what you found. It carries the address of this page.

Issue with "Design a progressive delivery standard for 100 Java services, including automated canary...": https://scrivio-interview-library.netlify.app/spring-boot/production-operations/fe05f59487/