devonfw / IDEasy

Tool to automate the setup and updates of a development environment for any project (Successor of devonfw-ide).
Apache License 2.0
8 stars 23 forks source link

Use Maven dependency cache to optimize workflow running times #492

Open jan-vcapgemini opened 3 months ago

jan-vcapgemini commented 3 months ago

Currently all workflows run several mvn compile processes and download lots of maven dependencies redundantly.

We need to use a cache for m2/repository so that each job can use an external space for its dependency downloads instead of its own local space.

More information can be found here: https://docs.github.com/en/actions/using-workflows/caching-dependencies-to-speed-up-workflows

hohwille commented 2 months ago

Already for building the native images (matrix os) sharing the results between the 4 builds would save lots of bandwidth and resources. However, there is no real risk for us to accidentally reuse SNAPSHOTS from previous builds so we could activate this caching for all our workflows to save resources.