Streaming Video Encoding & Packaging Pipeline  ·  View 12 of 22  ·  Data

Data Model

Eleven entities, and the one key the whole model turns on.

Editable source SVG draw.io All views
title title_id PK owner_id FK -> owner release_at demand_tier source_version source_id PK title_id FK -> title checksum UQ profile_json conformance_verdict accepted_at recipe recipe_digest PK source_id FK -> source_version encoder_build FK -> encoder_build ladder_json codec_set override_actor encoder_build encoder_build PK encoder version image_digest approved_at encode_job job_id PK recipe_digest FK -> recipe lane deadline_at chunk_seconds_done spend_cents chunk_task task_id PK job_id FK -> encode_job chunk_index start_pts / end_pts attempt_no output_digest rendition rendition_digest PK recipe_digest FK -> recipe rung codec residency_class generated_by quality_score score_id PK rendition_digest FK -> rendition metric aggregate worst_window gate_verdict segment segment_digest PK rendition_digest FK -> rendition sequence_no key_id FK -> content_key manifest manifest_id PK title_id FK -> title territory device_class revision published_at content_key key_id PK title_id FK -> title scheme rotated_at revoked_at 1 : N 1 : N 1 : N 1 : N 1 : N 1 : N 1 : N 1 : N 1 : N N : M 1 : N Data Model — Lineage from Master to Published Byte recipe_digest is the join key the whole model turns on: delete every rendition and the lineage still resolves. The audit log keys off the same digests and is omitted here. v 1.0 · owner Media Platform Architecture

recipe_digest is the join key

  • A digest over source version, encoder build and parameters. Every rendition, score, segment and job hangs off it.
  • Delete every rendition row and the lineage still resolves: you can still say what produced a byte that no longer exists, and regenerate it.
  • It is also the identity decision in Question 4 — content hash versus assigned id — written into the schema, where the consequence is visible.

What is deliberately not a foreign key

  • content_key carries a key_id and never key material. Segments reference the key id; the key itself lives only in the external key service.
  • manifest to segment is N:M because one segment set serves every device-class manifest and every DRM system — that is what common encryption buys.

Omitted here

  • The audit log keys off the same digests and is left off the view to keep the lineage chain readable. It is in view 11 and view 18.
  • Lane accounting and quota tables are operational, not lineage, and are omitted for the same reason.