Draft: Add org-mover manifest endpoint to the internal API [skip ci]
What does this MR do and why?
Adds GET /api/v4/internal/org_mover/manifest: this cell's Org Mover manifest (orgmover.manifest.v1.Manifest as JSON), generated from the running GitLab version's table dictionary (db/docs/*.yml) and live columns.
Today the manifest is hand-captured per GitLab release with demo/cng/scripts/manifest.rb and drifts silently as the schema changes. This makes Rails the source of truth, the Rails side of transport#126.
lib/gitlab/org_mover/manifest.rb: generator, a direct port of the capture script (the current contract reference).lib/api/internal/org_mover.rb: the route, same ES256 JWT auth as the existing org_mover routes.org_mover_manifest_apifeature flag (wip, default off).- Generator unit specs and request specs.
Open questions
- Flag scoping: the manifest is cell-scoped, so it uses its own instance-wide flag rather than the per-organization
org_mover_maintenance_api. - Handler maps stay curated, mirroring the script; moving them into
db/docs/*.ymlis a follow-up. - Cost: ~900 tables / ~450 KB on GitLab.com, generated per request. Callers are the cell services only; reviewers may want caching.
How to set up and validate locally
With the flag enabled and an ES256 key pair configured per Gitlab::OrgMover::Authenticator:
curl --header "Gitlab-Org-Mover-Api-Request: <jwt>" "http://gdk.test:3000/api/v4/internal/org_mover/manifest"The output should agree with rails runner - < demo/cng/scripts/manifest.rb from the org-mover repository.
Note: specs were authored outside a GDK; remove [skip ci] from the title and start a pipeline for the first run.
Authored by GitLab Duo (Chat, Claude Fable 5) on behalf of @romongbale, who will review before marking ready.