RFR: 8356645: Javac should utilize new ZIP file system read-only access mode [v2]

David Beaumont duke at openjdk.org
Wed Jun 18 20:08:28 UTC 2025


On Wed, 11 Jun 2025 05:43:31 GMT, Jan Lahoda <jlahoda at openjdk.org> wrote:

>> src/jdk.compiler/share/classes/com/sun/tools/javac/file/FSInfo.java line 183:
>> 
>>> 181:      *                       {@code null} to ignore release versioning).
>>> 182:      */
>>> 183:     public static Map<String, ?> readOnlyJarFSEnv(String releaseVersion) {
>> 
>> I named this after the getJarFSProvider() method above, since they are used in close proximity, but would be happy to consider other names.
>
> I am a bit uneasy about having the method static, as this class's API is normally instance methods. I think that an instance of FSInfo (`fsInfo`) is available in both `JavacFileManager` and `Locations`, so it would be better to simply have an instance method. (The static field is OK, that's not an API.)

Interesting idea since it permits per instance changes (e.g. due to flags/environment) later.
However there's no instance (yet) in VerifyCTSymClassFiles. I could mint one though.
Thoughts?

-------------

PR Review Comment: https://git.openjdk.org/jdk/pull/25639#discussion_r2155405134


More information about the compiler-dev mailing list