Add artifacts_file attribute to build data
What does this MR do and why?
Add artifacts_file attribute to build data
- Included
artifacts_file
attribute in thebuild
method ofGitlab::DataBuilder::Build
module. - The
artifacts_file
attribute containsfilename
andsize
of the build's artifacts. - Updated
build_spec.rb
to test the presence and correctness of theartifacts_file
attribute.
Why
Job artifacts are an essential part of the event that originates from the Build process. Today, in order for your to understand the artifacts that are generated via API, you must wait until the entire pipeline is completed. This is not an ideal scenario when you are integrating external tools into the process which are dependent on running based on artifact presence.
With the addition of this change, you can now listen to the Job Events and create or perform external jobs as soon as the artifact is available via a job, and no longer wait and/or act as a pipeline blocker.
MR acceptance checklist
Please evaluate this MR against the MR acceptance checklist. It helps you analyze changes to reduce risks in quality, performance, reliability, security, and maintainability.