Changes

Summary

  1. Fix OutOfMemoryError in XPath Cache: (details)
Commit 110a8224115321af04dc2ee2a6d030bdb88844df by Lampros Smyrnaios
Fix OutOfMemoryError in XPath Cache:
The `EVALUATED_EXPRESSIONS` cache was causing a memory leak by holding strong references to `Document` keys, preventing them from being garbage collected. This led to heap exhaustion and a `GC overhead limit exceeded` error.
Switched the cache keys to use weak references via `.weakKeys()`. This allows the cache entries to be reclaimed by the GC once the `Document` is no longer in use, fixing the leak.
The file was modifiedsrc/main/java/eu/dnetlib/validator2/engine/builtins/XPathExpressionHelper.java (diff)