Loading
Log pipeline variable values of 120 KiB or more, by type
What does this MR do and why?
Prepares the pipeline creation logger for the pipeline variable size limits in !253433:
- Lower threshold. A pipeline is logged when its largest variable value is 120 KiB or more, down from 200 KiB. 120 KiB is the planned GitLab.com limit for env_var values: Linux caps a single environment variable, name included, at 128 KiB (
MAX_ARG_STRLEN), so values near that can't reach a job; 120 KiB leaves some headroom. Every pipeline the limit would affect now gets a log line. - Size per type. Each line also records
pipeline_variables_max_env_var_value_bytesizeandpipeline_variables_max_file_value_bytesize, for the types the pipeline uses. File type variables have a separate, higher limit, and the existing combined maximum can't tell a largeTRIGGER_PAYLOAD(file type) from a large env_var. Anything that isn'tfilecounts as env_var.
pipeline_variables_max_value_bytesize and the other thresholds are unchanged. Only sizes are logged, never keys or values.
The threshold change is also in !253433. Shipping it here starts the logging before the limits merge.
References
- !253383 (merged) added the pipeline variable fields to the logger.
- !253433 adds the pipeline variable limits.
Screenshots or screen recordings
Not applicable. There is no UI change.
How to set up and validate locally
- Run a pipeline passing a variable whose value is between 120 KiB and 200 KiB.
- Check
log/application_json.logfor aGitlab::Ci::Pipeline::Loggerentry withpipeline_variables_max_env_var_value_bytesize. - Repeat with a file type variable, and check for
pipeline_variables_max_file_value_bytesize.
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 Oleg Yakovenko