Skip to content

Create new Geo verification state table for PackageFile

What does this MR do and why?

Geo functionality requires us to track the state of replicated data types - done with separate state tables which include the verification data, eg. ci_job_artifact_states for ci_job_artifacts.

Packages::PackageFile never had the verification attributes split out into separate state table, all the verification data is in the parent model.

This MR is the first iteration to address this issue by creating the new verification table and model.

This MR is not intended to change any existing functionality, and the table should remain unused until the follow-up MR, where we will backfill the new table.

Summary of changes -

  • For PackageFileState we've created the following:
    • migration to create the new table, including indexes, copying the existing state table indexes
    • model
    • db/docs/*.yml entry
    • model spec
    • factory

Relates to #520706 (closed)

Changelog: changed

EE: true

References

#520706 (closed)

How to set up and validate locally

The only way to validate so far (as the functionality is still untouched), is to actually check the newly created table with:

gdk psql and then \d packages_package_file_states

MR acceptance checklist

Evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.

Related to #520706 (closed)

Merge request reports

Loading