Simplify/Re-organize implementation of ObjectStorageUploader
Recently we'd refactored the architecture of object storage which was implemented for LFS, Artifacts and uploads, however, it also created some technical debt in GitLab Enterprise Edition. By those debts, it's obvious that the current architecture is brittle, therefore we're worried that we might lose persisted data again during GCP migration.
In this issue, we discuss what is bugging us, and how we should approach.
- Many "State" dependents code. Some methods changes own meaning by the timing.
- Uploads uses different logic from LFS and Artifacts because of STI (
- We shared a lot of logic (good thing), however, it's not completed as some functions are not idempotent.
persist_object_store!is not used for all kinds of objects.
Feel free to add your concerns