Engineering guide
Amazon CloudFront · bounded runs

Evidence before a bounded CloudFront run

Staging readiness and traffic configuration answer different questions. Readiness shows that the named staging setup can be evaluated; traffic evidence shows exactly how requests may reach it. Both must be tied to the same run before an approval can be meaningful.

Provider execution is not demonstrated here.

This guide describes AWS-documented behavior and Streamwake's evidence safeguards. The current no-spend preparation harness records owner-submitted evidence and keeps provider action unexecuted. It does not inspect a live CloudFront distribution or prove a traffic shift, recovery, or promotion.

01 · CloudFront's documented sequence

A staging distribution is reached through the primary.

AWS describes a primary distribution that serves production traffic, a staging distribution copied from it, and a continuous-deployment policy whose traffic configuration is attached to the primary. CloudFront then routes requests according to that configuration while the staging setup is monitored.

  1. 1. Name the primary and staging pair
    Identify the existing primary distribution and the staging distribution created from it. Record both identifiers, the configuration revision under review, and the exact environment and path scope for this run.
  2. 2. Record the attached traffic policy
    Capture the continuous-deployment policy reference and revision on the primary, plus the routing mode and its exact settings. A configuration file or planned policy is not evidence that the policy is attached and active.
  3. 3. Monitor the changed staging configuration
    Compare the staged result with the recorded baseline over the approved window. Keep the routing scope, content version, cohort, and evidence timestamps aligned so the readout describes the same bounded scenario.
  4. 4. Treat promotion as a separate change
    AWS promotion copies the staging configuration to the primary, disables the continuous-deployment policy, and routes all traffic to the primary. Approval should name this transition and the recovery procedure for the resulting primary configuration.

CloudFront continuous deployment does not send viewers directly to a staging DNS name, IP address, or CNAME. Requests reach the primary first; the policy decides which are routed to staging. Header-based routing uses a configured header whose name must have the aws-cf-cd- prefix. Weight-based routing has a current AWS maximum of 15%. These service rules constrain what can be configured; they do not define Streamwake's approved blast radius.

Primary and staging distributions do not share a cache, so the staging cache starts empty. Include that condition in the evaluation design and do not treat initial cold-cache behavior as a steady-state comparison.

Source: AWS CloudFront continuous-deployment workflow, routing and staging behavior, and quotas and considerations.

02 · Staging-readiness evidence

Make “ready” specific to one run.

A readiness statement should be reviewable against source evidence, not just a green label. The record should identify what was checked, by whom, for which staging target, and during what window.

Bind readiness to the run
  • Primary and staging distribution identifiers, environment, and evidence reference.
  • Exact path scope, cohort, content identifier/version, and run version.
  • Configuration revision and the observation-window start and end.
  • Named recorder, organization, source, incident, and capture timestamp.
Show the staging checks
  • Evidence that the intended staging configuration is deployed and can be observed.
  • A stable comparison baseline and a complete, predeclared evaluation window.
  • Named data sources, their coverage, timestamps, and any missing or delayed samples.
  • A tested restoration plan and a cleanup check for the exact development scope.

Set thresholds before the run

The supplied research names stall rate, player errors, latency, decoded playback, and fresh-content matching as candidate pass criteria, but it does not establish approved numeric thresholds or a demonstrated CloudFront result. Record the owner-approved value, unit, measurement source, denominator, and full-window rule for each criterion. Keep any interim number visibly proposed until its owner and evidence source are approved.

CloudFront's documented distribution metrics include error rates by distribution; CacheHitRate and OriginLatency are additional metrics that must be enabled for each distribution. They describe distribution/origin behavior, not independent player playback or a per-PoP viewer-quality feed. Use separately identified player telemetry for decoded frames, fresh content, stalls, and player errors.

Source: AWS CloudFront metrics. A metric name in a plan is not proof that it is enabled, populated, or attributable to this run.

03 · Traffic-configuration evidence

Prove the route that is configured and the route that was observed.

The evidence packet should make it possible to reconstruct the effective routing rule and compare it with the bounded scope that was approved.

Configuration record
Policy identifier and revision; primary/staging pair; attached/enabled state; route mode; exact percentage or header rule; session-stickiness settings when used; and an immutable source reference with actor and timestamp.
Observed traffic
Provider-side evidence that the policy was deployed and requests followed the configured rule during the window. Include distribution-level counters or logs and separate player-side observations where the claim concerns playback.
Scope match
The saved policy snapshot must match the approved run version, target, paths, cohort, content/version, and observation window. Record any out-of-scope traffic or unexpected routing as a stop condition.
Stop and recovery
Define who may stop the run, how exposure is reduced or the policy disabled, what prior configuration must be retained, and how state is checked after restoration. Disabling the policy routes requests to the primary; after promotion, the primary already has the staged configuration, so a prior-state restore must be separately specified.

An AWS blog tutorial describes one optional CodePipeline/CloudFormation implementation. Its prerequisites include an existing CloudFront distribution, an AWS account and Region supporting the tutorial's CodePipeline, CodeCommit, and Lambda services, and familiarity with CloudFormation and CodeCommit. Those are prerequisites for that sample automation path, not prerequisites for CloudFront's native staging-policy workflow.

Source: AWS CI/CD tutorial prerequisites.

04 · Approval boundary

Evidence makes an approval reviewable; it does not grant provider access.

Readiness and traffic configuration are prerequisites to a decision, not substitutes for the decision itself. Approval must name the same run, version, target, path scope, and bounded observation window represented in the evidence.

Safeguard in the app
The preparation harness binds owner-recorded readiness and traffic records to a run and checks their attribution and scope before approval can pass its evidence gate. Missing, malformed, or mismatched records keep the gate blocked.
What the record proves
It proves that a user submitted a reference and summary associated with the named run. The no-spend workflow does not fetch CloudFront configuration or validate that a saved description matches provider state.
What still needs demonstration
A real provider receipt or control-plane read, observed traffic evidence, and independent playback measurements are separate evidence phases. A saved approval, synthetic fixture, healthy origin, or AWS request receipt alone is not proof of viewer recovery.

Keep source capability and product evidence separate.

The integration research page lists CloudFront capabilities and their current evidence boundaries. It does not report a live connection or bounded-run result.

CloudFront evidence boundaries

Sources

This guide describes documented service behavior and application safeguards. No live CloudFront scenario, provider execution, traffic shift, promotion, or viewer recovery is claimed as verified.