The limit of the global instance variable is 5 000 000 for file type
-
Please check this box if this contribution uses AI-generated content (including content generated by GitLab Duo features) as outlined in the GitLab DCO & CLA. As a benefit of being a GitLab Community Contributor, you receive complimentary access to GitLab Duo.
What does this MR do and why?
The purpose of this MR is to permit to set variable of type file with a content of more than 10k characters. The 10k characters limit should only apply to "environment variable" variables while "file" variables can contain up to 5M characters
(Here k stands for 1 000 and M for 1 000 000).
The implementation encompass:
- modifying instance_variable validators to have different maximum length according the variable type
- enforcing the limit through a database constraint. The 5M limit correspond to a very specific value once the file content is encrypted. The test should fail if the encryption mechanism happens to be modified.
References
Cannot add file bigger than 10000 characters on... (#354731) • Nicolas Deherly • 18.6
Screenshots or screen recordings
Before | After |
---|---|
How to set up and validate locally
MR acceptance checklist
Evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.
Edited by Nicolas Deherly