Bug #6565
closedPerformance Regression in DocumentFn with Java 12 or higher
0%
Description
Hello,
I have come across a slow-down that is happening when accessing files using fn:document
or checking for their existence using fn:doc-available
.
I have also attached a screenshot of the hotspot (taken from JProfiler). The bottom line seems to be that with current Java versions File.getCanonicalPath
is much slower, due to a cache that was removed from JDK.
Here are some links related to the change: https://bugs.openjdk.org/browse/JDK-8207005 https://bugs.java.com/bugdatabase/view_bug?bug_id=8309215
The was first disabled with Java 12, and then completely removed with Java 21.
From the looks of it, DocumentFn
is only using it to conveniently normalize the filename. perhaps there is a way to do that without the need to call getCanonicalPath()
.
Thanks in advance and kind regards, Philipp
Files
Please register to edit this issue