Skip to content

Commit fb787d7

Browse files
Flossyclaude
andcommitted
fix: clear perArtifactLocks map in close() to prevent memory leak
Resolves #364 - perArtifactLocks map now cleared along with other caches to prevent unbounded growth from accumulated lock objects. Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
1 parent 36f6310 commit fb787d7

1 file changed

Lines changed: 1 addition & 0 deletions

File tree

src/main/java/org/flossware/classloader/MavenRepositoryClassSource.java

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -416,6 +416,7 @@ public void close() throws IOException {
416416
}
417417
}
418418
jarPathCache.clear();
419+
perArtifactLocks.clear();
419420

420421
// Throw aggregated exception if any occurred
421422
if (!exceptions.isEmpty()) {

0 commit comments

Comments
 (0)