noCV
AMETA-109 · Make filters trustworthy

Enforce required relational document fields after a clean backfill

Practice briefTaskAdvanced

New readers assume every document has a valid owner and UTC creation instant, but quarantined legacy rows still violate that assumption.

Focused work estimate
3h 30m + prerequisites
Priority in the scenario
Medium
Engineering practice
Constraint validation · Migration safety

Estimated field mix

  • Database engineering100%

Field percentages are editorial estimates of the ticket's engineering focus. They total 100%; they are not measured time, proficiency scores, or ownership evidence.

Your next step

Review it, then add it to your workspace.

The board opens an editable draft; nothing is saved until you confirm it. Sign-in and workspace permissions apply, and Demo boards remain ephemeral.

Project context

A fictional records portal stores every property in one JSON column. Queries disagree about missing values, and malformed records make ordinary filters fail.

Setup prerequisites

  • Create synthetic document metadata with malformed and legacy versions.
  • Use migrations and a local query API.

Preceding work

Complete these dependencies, or supply their agreed outputs before taking this ticket.

Acceptance criteria

  • Check null, orphan and contradictory target fields before validation.
  • Keep quarantined records outside normal reader activation.
  • Add required constraints only after declared readiness passes.

Implementation constraints

  • Do not fabricate missing timestamps to make constraints pass.

Verification to include

  • Validate a fully resolved synthetic cohort.
  • Leave one ambiguous timestamp and verify readiness blocks activation.

Deliverables

  • Readiness query and constraint migration

Rollout and recovery

Activate resolved cohorts after verification; retain legacy quarantine and avoid destructive contraction.

Value of the work

For the engineer: Practice relational/JSON boundaries, versioned validation and query semantics.

For the team: Review a data model that stays inspectable while allowing controlled variation.

Evidence boundaries

Outcome Evidence: Tests, patches, and runbooks are requested deliverables. They become Outcome Evidence only through a qualified Mission and immutable Evidence IDs.

Ownership Evidence: Independent adaptation must be observed under a declared verification policy and cite immutable Evidence IDs. Completing a planning ticket establishes no Ownership Evidence.