JDK-8207005 : Disable the file canonicalization cache by default
  • Type: Enhancement
  • Component: core-libs
  • Sub-Component: java.io
  • Priority: P3
  • Status: Resolved
  • Resolution: Fixed
  • Submitted: 2018-07-10
  • Updated: 2023-11-15
  • Resolved: 2018-07-11
The Version table provides details related to the release that this issue/RFE will be addressed.

Unresolved : Release in which this issue/RFE will be addressed.
Resolved: Release in which this issue/RFE has been resolved.
Fixed : Release in which this issue/RFE has been fixed. The release containing this fix may be available for download as an Early Access Release or a General Availability Release.

To download the current JDK release, click here.
JDK 12
12 b03Fixed
Related Reports
Relates :  
Relates :  
Relates :  
Relates :  
Relates :  
Relates :  
Sub Tasks
JDK-8320173 :  
Description
The file canonicalization cache was added back in JDK 1.4.2 in order to improve startup time.

The cache has long-standing correctness issues (JDK-7066948, for example).  For this reason, it has been desired to disable the cache by default, but the increase to startup time was undesirable.

Recent JDK releases have removed usages of the cache, in particular from FilePermission (JDK-8164705 in JDK 9).  This reduced usage of the canonicalization cache should also reduce the startup effect of disabling the cache by default.  Measurements support this.  Previous measurements showed the startup effect of disabling the cache on Linux to be 3-6%, depending on the specific benchmark.  The same comparison performed last month now show no startup change on Linux.
 
The file canonicalization cache can still be enabled by setting the "sun.io.useCanonCaches" system property.  This is merely a change to the default value.

Comments
URL: http://hg.openjdk.java.net/jdk/jdk/rev/ae39e5a991ed User: bchristi Date: 2018-07-11 21:33:16 +0000
11-07-2018

noreg-hard: it would be difficult to confirm or deny internal use of the file canonicalization cache
11-07-2018