Skip to content

️ Faster Pipeline - LAB-483

Vincent Kelleher requested to merge LAB-483_pipeline_improvement into develop

Pipeline Optimization

While I was waiting for some evening MRs to be merged, I noticed that the pipeline was rather slow so I had a closer look 👀

First of all, I noticed that wether we needed OWL and JSON-LD files or not, they were generated alongside Shacl files, so I started by separating those jobs in a single job per file type. This uses more resources, which isn't a big issue as those jobs are only run when merging to develop or main, but there are benefits.

Faster Pipeline

MR pipelines are now faster because we only generate the Shacl files instead of all file types. This are divided by 2 and that's a good thing for the feedback loop.

Before :

Screenshot_2024-02-05_at_08.57.21

After :

Screenshot_2024-02-05_at_08.57.29

Parallel Execution

Another benefit of this pipeline model is that builds are now considered a directed acyclic graph instead of sequential stages/jobs.

This means that jobs can be run in parallel on different Gitlab Runners, a typical MR pipeline will now run the Javascript tests and Python instance validation tests at the same time hence making the overall process quicker.

Screenshot_2024-02-05_at_08.56.37

What's even better is that develop pipelines can run all the file generation jobs at the same time and allow downstream jobs to run before all the file types are generated, for example Shacl tests can be executed before JSON-LD and OWL files are generated with the new dependency model.

Screenshot_2024-02-05_at_08.58.08

Easier Debugging

To date, if a generator has an issue during the process, it is impossible to pinpoint which generator failed (JSON-LD ? Shacl ? OWL ?). With the new pipeline model, if a generator fails, a red cross will appear next to the generator's name.

Edited by Vincent Kelleher

Merge request reports