Database Schema Validation to ensure the deployed database schema matches codebase expectations
## Problem
Sometimes, a deployed GitLab instance schema does not match the schema expected by the codebase. This can lead to errors, bad data, and poor performance. Any of these problems can occur during operation or during upgrades. There many ways to get into this state.
## Proposal
### Overview
Automatically validate schemas in Gitlab instances. Add the necessary migrations to get the schema back in sync.
### To do
- [x] Add a task or a manual trigger that checks the database for schema inconsistencies and track them in a table
- [x] Integrate the Schema validation feature with the service ping tool so we can collect information about schema inconsistencies and release major fixes if needed.
- [x] Build a system that will create a new issue for each detected schema inconsistency in GitLab.com.
- [-] Make system tag the table owners in the issue. Document that table owners are responsible for fixing the inconsistencies.
- [x] Move schema validation framework to a gem (this appears to have [removed](https://gitlab.com/gitlab-org/gitlab/-/merge_requests/125869) the inconsistency tracking and issue creation)
- [ ] Add a view in the GitLab Admin Area, where customers can see schema inconsistencies and take actions (Example: Add a missing index).
epic