Use WH acceleration on Project Import file upload via UI
What does this MR do?
Relates to #208674 (closed)
Allows using WH accelerated file uploads for Project Import.
This is related to UI endpoints only, API acceleration is handled in !25361 (merged).
Since we are touching an existing endpoint, we should deploy it gradually.
The deployment plan presented in #208674 (closed)
How to test locally
- Make these changes in your local WH (which is in the GDK dir): gitlab-workhorse!470 (merged)
- Run
make gitlab-workhorse-setup && gdk restart gitlab-workhorse
to apply them - setup minio: brew install minio (if you're on mac)
- enable object storage and direct upload in config/gitlab.yml
- uncomment minio start-up command in Procfile (it already has all the keys in the config)
- restart gdk and make sure you can access http://127.0.0.1:9000
- you could use
mc
(minio command-line client) for troubleshooting and for checking storage events - Import any GL project via UI
You will notice in the logs that your request will go through an /authorize
endpoint if it was accelerated. Also, headers/body would differ accordingly.
Does this MR meet the acceptance criteria?
Conformity
-
Changelog entry - [-] Documentation (if required)
-
Code review guidelines -
Merge request performance guidelines -
Style guides - [-] Database guides
- [-] Separation of EE specific content
Availability and Testing
I tested this locally both with direct uploads being enabled and disabled, and each case with the current and the updated Workhorse.
Security
If this MR contains changes to processing or storing of credentials or tokens, authorization and authentication methods and other items described in the security review guidelines:
-
Label as security and @ mention @gitlab-com/gl-security/appsec
-
The MR includes necessary changes to maintain consistency between UI, API, email, or other methods -
Security reports checked/validated by a reviewer from the AppSec team