Skip to content

Scope the artifact cache of DefaultThirdPartyHelper to the helper - #793

Merged
slachiewicz merged 1 commit into
masterfrom
agent/per-build-artifact-cache
Nov 8, 2026
Merged

slachiewicz merged 1 commit into
masterfrom
agent/per-build-artifact-cache

Conversation

@slachiewicz

Copy link
Copy Markdown
Member

The artifact cache of DefaultThirdPartyHelper was a static map that was never cleared; it is now an instance field, released with the helper that each mojo execution creates. Within one execution the cache behaves as before; modules of a reactor no longer share loaded dependency projects.

Closes #375

Verified: mvn -B -ntp verify -Prun-its -Dinvoker.test=aggregate-add-third-party-bad-license,add-third-party-excluded-included β†’ 140 unit tests, 2 ITs passed

The cache was a static map that was never cleared, so it kept every loaded dependency project for the life of the JVM, 134 MB in the report on #375. A mojo creates a helper per execution, so the cache is now released with it. Closes #375.
@slachiewicz slachiewicz added the enhancement New feature or request label Nov 8, 2026
@slachiewicz
slachiewicz marked this pull request as ready for review November 8, 2026 16:55
@slachiewicz
slachiewicz merged commit 9770005 into master Nov 8, 2026
15 checks passed
@slachiewicz
slachiewicz deleted the agent/per-build-artifact-cache branch November 8, 2026 16:55
@github-actions github-actions Bot added this to the 2.8.1 milestone Nov 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Artifact cache can have memory issues for large projects

1 participant