Skip to content

availableLanguages: videoChildren worker — additive sync to true replace #9522

Description

@tanflem

Parent

Sub-issue of #9515 (Rebuild Video.availableLanguages as one cycle-safe, recursively-correct source of truth).

What to build

The worker that syncs the children relation from the childIds scalar array is changed from additive-only to a true replace, so a relation edge removed from childIds by any write path can't persist forever as a stale connection. This is independent of the recompute engine — it's a data-integrity hardening of the relation the cascade walks, not a change to the cascade itself.

Acceptance criteria

  • A video whose childIds shrinks (a child id removed) has that child correctly disconnected from the children relation after the worker runs, not just new children connected.
  • A video whose childIds grows continues to get the new child correctly connected (no regression).
  • Running the worker twice in a row against unchanged data is a no-op (idempotent).

Blocked by

None (can start immediately) — independent of the recompute engine work.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions