Mirror API write operations to the database
As part of https://gitlab.com/groups/gitlab-org/-/epics/2313, we need mirror the metadata that's currently written to the filesystem into the database. This should be done for all API calls.
epic