helidon-io / helidon-build-tools

Build tools for the Helidon Project
https://helidon.io
Apache License 2.0
35 stars 35 forks source link

Maven Build Cache Extension: add support for state file suffix #1063

Closed romain-grecourt closed 3 months ago

romain-grecourt commented 3 months ago

Introduce a new mechanism that can be used to aggregate partial caches.

E.g.

build -> | javadoc part#1 -|
         | javadoc part#2  |-> release
         | javadoc part#3 -|

The javadoc jobs can use -Dcache.recordSuffix=javadoc to produce augmented state files with a different name. A simple glob like can be used **/target/state-javadoc.xml to archive only the new state.

The release job can download all javadoc artifacts, without conflicts with the state files (unless the javadoc jobs overlap). The javadoc state files can be loaded with -Dcache.loadSuffixes=javadoc, they will be merged with the default state files.